Updated Schemas documentation authored by Elbez Hammouda's avatar Elbez Hammouda
......@@ -24,8 +24,8 @@ A document schema is a JSON object that contains information about the shape, fi
```json
{
"properties" : {
"_id" : { "bsonType" : "objectId" },
"name" : { "bsonType" : "string" }
"_id" : { "bsonType": "objectId" },
"name" : { "bsonType": "string" }
}
}
```
......@@ -35,21 +35,23 @@ A document schema is a JSON object that contains information about the shape, fi
## VS2N documents schemas
## 1- General information schemas:
**Collection name** : info<br><br>
**Collection content** :<br>
In this collection, there are two schemas, the first one contains information about:
- Used dataset
- Date of simulation
- Name of the simulation
- Number of layers
- Number of neurons per layer
- Used dataset.
- Date of simulation.
- Name of the simulation.
- Number of layers.
- Number of neurons per layer.
```json
{
"properties" : {
"_id" : { "bsonType": "objectId" }, // id
"n" : { "bsonType": "string" }, // simulation name
"L:N" : { "<JSON>" }, // layer name : neurons number
"T" : { "bsonType": "string" }, // simulation date
"D" : { "bsonType": "string" } // dataset name
"n" : { "bsonType": "string" }, // simulation name
"L:N" : { "<JSON>" }, // layer name : neuron id
"T" : { "bsonType": "string" }, // simulation date
"D" : { "bsonType": "string" } // dataset name
}
}
```
......@@ -60,7 +62,7 @@ In this collection, there are two schemas, the first one contains information ab
{
"_id" : ObjectId("603834c376e245cd78319032"),
"n" : "My network",
"L:N" : { "Input" : 784, "layer1" : 100 },
"L:N" : { "Input": 784, "layer1": 100 },
"T" : "26-02-2021-00:37:39",
"D" : "Mnist"
}
......@@ -75,8 +77,8 @@ The second one contains optional information, which is collected if there was a
{
"properties" : {
"_id" : { "bsonType": "objectId" }, // id
"MaxS" : { "bsonType": "string" }, // network accuracy (Max Spike)
"NLabel" : { "<Array of JSON>" }, // neurons labels
"MaxS" : { "bsonType": "string" }, // network accuracy (Max Spike)
"NLabel" : { "<Array of JSON>" }, // neurons labels
}
}
```
......@@ -88,23 +90,120 @@ The second one contains optional information, which is collected if there was a
"_id" : ObjectId("60163a04dec986560a8d907a"),
"MaxS" : 83.51,
"NLabel" : [
{ "L" : "Layer1", "N" : "13", "Label" : "2" },
{ "L" : "Layer1", "N" : "99", "Label" : "1" },
{ "L" : "Layer1", "N" : "97", "Label" : "0" },
{ "L": "Layer1", "N": "13", "Label": "2" },
{ "L": "Layer1", "N": "99", "Label": "1" },
{ "L": "Layer1", "N": "97", "Label": "0" },
...
]
}
```
<div align="center">Example</div>
<br>
## 2- Spikes activity schemas:
In this collection, there are two schemas, the first one contains information about:
- Used dataset
**Collection name** : spikes<br><br>
**Collection content** :<br>
In this collection, we collect every spike activity in the network during training. The collection contains information about:
- Time of spike (μs).
- Label of current input data (if exists).
- Layer name and neuron id.
```json
{
"properties" : {
"_id" : { "bsonType": "objectId" }, // id
"T" : { "bsonType": "NumberLong" }, // time of spike
"i" : { "<JSON>" }, // layer name : neuron id
"Input" : { "bsonType": "string" } // label of current input data (if exists)
}
}
```
<div align="center">Spikes activity schema</div>
<br>
```json
{
"_id" : ObjectId("6015ffc4dec986560a0709e5"),
"T" : NumberLong(30383000),
"i" : { "L": "Layer1", "N": 92 },
"Input" : { "bsonType": "0" }
}
```
<div align="center">Example</div>
<br>
## 3- Neurons membrane potential schemas:
In this collection, there are two schemas, the first one contains information about:
- Used dataset
**Collection name** : potential<br><br>
**Collection content** :<br>
In this collection, we collect every neuron membrane potential activity in the network during training. The collection contains information about:
- Time of update (μs).
- Layer name.
- Neuron id.
- The new potential value.
```json
{
"properties" : {
"_id" : { "bsonType": "objectId" }, // id
"T" : { "bsonType": "NumberLong" }, // time of update
"L" : { "bsonType": "string" }, // layer name
"N" : { "bsonType": "int" }, // neuron id
"V" : { "bsonType": "double" } // the new potential value
}
}
```
<div align="center">Neurons membrane potential schemas</div>
<br>
```json
{
"_id" : ObjectId("6015ffb7dec986560a06e29d"),
"T" : NumberLong(18027000),
"L" : "Layer1",
"N" : 19,
"V" : 5.675836
}
```
<div align="center">Example</div>
<br>
## 4- Synapses weight activity schemas:
In this collection, there are two schemas, the first one contains information about:
- Used dataset
\ No newline at end of file
**Collection name** : synapseWeight<br><br>
**Collection content** :<br>
In this collection, we collect every synapse weight activity in the network during training. The collection contains information about:
- Time of synapse update (μs).
- Source neuron id.
- Destination neuron id.
- Synapse weight value.
- Synapse index coordinates (for heatmap construction).
```json
{
"properties" : {
"_id" : { "bsonType": "objectId" }, // id
"T" : { "bsonType": "NumberLong" }, // time of synapse update
"C" : { "bsonType": "int" }, // destination neuron id
"To" : { "bsonType": "int" }, // source neuron id
"V" : { "bsonType": "double" }, // weight value
"index" : { // index coordinates
"x": { "bsonType": "int" },
"y": { "bsonType": "int" }}
}
}
```
<div align="center">Synapses weight activity schema</div>
<br>
```json
{
"_id" : ObjectId("6015ffefdec986560a078796"),
"T" : NumberLong(66847000),
"C" : 333,
"To" : 0,
"V" : 0.649092,
"index" : { "x": 0, "y": 0 }
}
```
<div align="center">Example</div>
<br>
\ No newline at end of file