| 1 |
<?xml version="1.0" encoding="UTF-8"?> |
|---|
| 2 |
<?xml-stylesheet type="text/xsl" href="../transformations/FacetsMLtoPyNN.xsl"?> |
|---|
| 3 |
<rng:grammar ns="http://neuralensemble.org/FacetsML" |
|---|
| 4 |
xmlns="http://neuralensemble.org/FacetsML" |
|---|
| 5 |
xmlns:rng="http://relaxng.org/ns/structure/1.0" |
|---|
| 6 |
xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" |
|---|
| 7 |
xmlns:class="http://neuralensemble.org/FacetsML/cellclass" |
|---|
| 8 |
xmlns:rand="http://neuralensemble.org/FacetsML/randomNumberGenerator" |
|---|
| 9 |
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"> |
|---|
| 10 |
|
|---|
| 11 |
<rng:include ns="http://neuralensemble.org/FacetsML/cellclass" href="cellclass.rng"/> |
|---|
| 12 |
<rng:include ns="http://neuralensemble.org/FacetsML/randomNumberGenerator" href="random.rng"/> |
|---|
| 13 |
|
|---|
| 14 |
<rng:start> |
|---|
| 15 |
<rng:ref name="network"/> |
|---|
| 16 |
</rng:start> |
|---|
| 17 |
|
|---|
| 18 |
<rng:define name="network"> |
|---|
| 19 |
<rng:element name="network"> |
|---|
| 20 |
<rng:attribute name="timestep"> |
|---|
| 21 |
<rng:data type="float"/> |
|---|
| 22 |
</rng:attribute> |
|---|
| 23 |
<rng:attribute name="min_delay"> |
|---|
| 24 |
<rng:data type="float"/> |
|---|
| 25 |
</rng:attribute> |
|---|
| 26 |
<rng:attribute name="max_delay"> |
|---|
| 27 |
<rng:data type="float"/> |
|---|
| 28 |
</rng:attribute> |
|---|
| 29 |
<a:documentation>(ms) simulaton duration</a:documentation> |
|---|
| 30 |
<rng:attribute name="sim_duration"> |
|---|
| 31 |
<rng:data type="float"/> |
|---|
| 32 |
</rng:attribute> |
|---|
| 33 |
|
|---|
| 34 |
<rng:interleave> |
|---|
| 35 |
<rng:ref name="extras"/> |
|---|
| 36 |
<rng:ref name="rng"/> |
|---|
| 37 |
<rng:ref name="cells"/> |
|---|
| 38 |
<rng:ref name="populations"/> |
|---|
| 39 |
<rng:ref name="projections"/> |
|---|
| 40 |
</rng:interleave> |
|---|
| 41 |
</rng:element> |
|---|
| 42 |
</rng:define> |
|---|
| 43 |
|
|---|
| 44 |
<rng:define name="extras"> |
|---|
| 45 |
<rng:oneOrMore> |
|---|
| 46 |
<rng:ref name="extra"/> |
|---|
| 47 |
</rng:oneOrMore> |
|---|
| 48 |
</rng:define> |
|---|
| 49 |
|
|---|
| 50 |
<rng:define name="extra"> |
|---|
| 51 |
<rng:element name="extra"> |
|---|
| 52 |
<rng:attribute name="name"> |
|---|
| 53 |
<rng:data type="string"/> |
|---|
| 54 |
</rng:attribute> |
|---|
| 55 |
<rng:attribute name="value"> |
|---|
| 56 |
<rng:data type="string"/> |
|---|
| 57 |
</rng:attribute> |
|---|
| 58 |
</rng:element> |
|---|
| 59 |
</rng:define> |
|---|
| 60 |
|
|---|
| 61 |
<rng:define name="rng"> |
|---|
| 62 |
<rng:element name="rng"> |
|---|
| 63 |
<rng:attribute name="name"> |
|---|
| 64 |
<rng:data type="string"/> |
|---|
| 65 |
</rng:attribute> |
|---|
| 66 |
<rng:attribute name="seed"> |
|---|
| 67 |
<rng:data type="integer"/> |
|---|
| 68 |
</rng:attribute> |
|---|
| 69 |
<rng:attribute name="generator"> |
|---|
| 70 |
<rng:choice> |
|---|
| 71 |
<rng:value>NumpyRNG</rng:value> |
|---|
| 72 |
<rng:value>GSLRNG</rng:value> |
|---|
| 73 |
</rng:choice> |
|---|
| 74 |
</rng:attribute> |
|---|
| 75 |
</rng:element> |
|---|
| 76 |
</rng:define> |
|---|
| 77 |
|
|---|
| 78 |
<rng:define name="cells"> |
|---|
| 79 |
<rng:element name="cells"> |
|---|
| 80 |
<rng:oneOrMore> |
|---|
| 81 |
<rng:ref name="cell"/> |
|---|
| 82 |
</rng:oneOrMore> |
|---|
| 83 |
</rng:element> |
|---|
| 84 |
</rng:define> |
|---|
| 85 |
|
|---|
| 86 |
<rng:define name="cell"> |
|---|
| 87 |
<rng:element name="cell"> |
|---|
| 88 |
<rng:attribute name="name"> |
|---|
| 89 |
<rng:data type="string"/> |
|---|
| 90 |
</rng:attribute> |
|---|
| 91 |
<rng:ref name="cellclass"/> |
|---|
| 92 |
</rng:element> |
|---|
| 93 |
</rng:define> |
|---|
| 94 |
|
|---|
| 95 |
<rng:define name="populations"> |
|---|
| 96 |
<rng:element name="populations"> |
|---|
| 97 |
<rng:oneOrMore> |
|---|
| 98 |
<rng:ref name="population"/> |
|---|
| 99 |
</rng:oneOrMore> |
|---|
| 100 |
</rng:element> |
|---|
| 101 |
</rng:define> |
|---|
| 102 |
|
|---|
| 103 |
|
|---|
| 104 |
<rng:define name="population"> |
|---|
| 105 |
<rng:element name="population"> |
|---|
| 106 |
<rng:attribute name="name"> |
|---|
| 107 |
<rng:data type="string"/> |
|---|
| 108 |
</rng:attribute> |
|---|
| 109 |
<rng:optional> |
|---|
| 110 |
<rng:attribute name="label"> |
|---|
| 111 |
<rng:data type="string"/> |
|---|
| 112 |
</rng:attribute> |
|---|
| 113 |
</rng:optional> |
|---|
| 114 |
<rng:oneOrMore> |
|---|
| 115 |
<rng:element name="dim"> |
|---|
| 116 |
<rng:attribute name="size"> |
|---|
| 117 |
<rng:data type="integer"/> |
|---|
| 118 |
</rng:attribute> |
|---|
| 119 |
</rng:element> |
|---|
| 120 |
</rng:oneOrMore> |
|---|
| 121 |
<rng:element name="cell_type"> |
|---|
| 122 |
<rng:attribute name="name"> |
|---|
| 123 |
<rng:data type="string"/> |
|---|
| 124 |
</rng:attribute> |
|---|
| 125 |
</rng:element> |
|---|
| 126 |
<rng:optional> |
|---|
| 127 |
<rng:element name="randomInit"> |
|---|
| 128 |
<rng:attribute name="rng"> |
|---|
| 129 |
<rng:data type="string"/> |
|---|
| 130 |
</rng:attribute> |
|---|
| 131 |
<rng:ref name="random"/> |
|---|
| 132 |
</rng:element> |
|---|
| 133 |
</rng:optional> |
|---|
| 134 |
</rng:element> |
|---|
| 135 |
</rng:define> |
|---|
| 136 |
|
|---|
| 137 |
|
|---|
| 138 |
|
|---|
| 139 |
<rng:define name="projections"> |
|---|
| 140 |
<rng:element name="projections"> |
|---|
| 141 |
<rng:zeroOrMore> |
|---|
| 142 |
<rng:ref name="projection"/> |
|---|
| 143 |
</rng:zeroOrMore> |
|---|
| 144 |
</rng:element> |
|---|
| 145 |
</rng:define> |
|---|
| 146 |
|
|---|
| 147 |
<rng:define name="projection"> |
|---|
| 148 |
<rng:element name="projection"> |
|---|
| 149 |
<a:documentation> |
|---|
| 150 |
presynaptic_population and postsynaptic_population - Population objects. |
|---|
| 151 |
<br/> |
|---|
| 152 |
source - string specifying which attribute of the presynaptic cell signals action potentials |
|---|
| 153 |
<br/> |
|---|
| 154 |
target - string specifying which synapse on the postsynaptic cell to connect to |
|---|
| 155 |
If source and/or target are not given, default values are used. |
|---|
| 156 |
<br/> |
|---|
| 157 |
method - string indicating which algorithm to use in determining connections. |
|---|
| 158 |
Allowed methods are 'allToAll', 'oneToOne', 'fixedProbability', |
|---|
| 159 |
'distanceDependentProbability', 'fixedNumberPre', 'fixedNumberPost', |
|---|
| 160 |
'fromFile', 'fromList' |
|---|
| 161 |
<br/> |
|---|
| 162 |
methodParameters - dict containing parameters needed by the connection method, |
|---|
| 163 |
although we should allow this to be a number or string if there is only |
|---|
| 164 |
one parameter. |
|---|
| 165 |
<br/> |
|---|
| 166 |
WARNING : in the test, the value given is not a dict, but the directy value of the parameter |
|---|
| 167 |
<br/> |
|---|
| 168 |
rng - since most of the connection methods need uniform random numbers, |
|---|
| 169 |
it is probably more convenient to specify a RNG object here rather |
|---|
| 170 |
than within methodParameters, particularly since some methods also use |
|---|
| 171 |
random numbers to give variability in the number of connections per cell. |
|---|
| 172 |
</a:documentation> |
|---|
| 173 |
<rng:attribute name="name"> |
|---|
| 174 |
<rng:data type="string"/> |
|---|
| 175 |
</rng:attribute> |
|---|
| 176 |
<rng:attribute name="presynaptic_population_name"> |
|---|
| 177 |
<rng:data type="string"/> |
|---|
| 178 |
</rng:attribute> |
|---|
| 179 |
<rng:attribute name="postsynaptic_population_name"> |
|---|
| 180 |
<rng:data type="string"/> |
|---|
| 181 |
</rng:attribute> |
|---|
| 182 |
<rng:attribute name="method"> |
|---|
| 183 |
<rng:choice> |
|---|
| 184 |
<rng:value>allToAll</rng:value> |
|---|
| 185 |
<rng:value>oneToOne</rng:value> |
|---|
| 186 |
<rng:value>fixedProbability</rng:value> |
|---|
| 187 |
<rng:value>distanceDependentProbability</rng:value> |
|---|
| 188 |
<rng:value>fixedNumberPre</rng:value> |
|---|
| 189 |
<rng:value>fixedNumberPost</rng:value> |
|---|
| 190 |
<rng:value>fromFile</rng:value> |
|---|
| 191 |
</rng:choice> |
|---|
| 192 |
</rng:attribute> |
|---|
| 193 |
<rng:zeroOrMore> |
|---|
| 194 |
<rng:element name="methodParameter"> |
|---|
| 195 |
<rng:attribute name="name"> |
|---|
| 196 |
<rng:data type="string"/> |
|---|
| 197 |
</rng:attribute> |
|---|
| 198 |
<rng:attribute name="value"> |
|---|
| 199 |
<rng:data type="string"/> |
|---|
| 200 |
</rng:attribute> |
|---|
| 201 |
</rng:element> |
|---|
| 202 |
</rng:zeroOrMore> |
|---|
| 203 |
<rng:optional> |
|---|
| 204 |
<rng:attribute name="weight"> |
|---|
| 205 |
<rng:data type="float"/> |
|---|
| 206 |
</rng:attribute> |
|---|
| 207 |
</rng:optional> |
|---|
| 208 |
<rng:optional> |
|---|
| 209 |
<rng:attribute name="source"> |
|---|
| 210 |
<rng:data type="string"/> |
|---|
| 211 |
</rng:attribute> |
|---|
| 212 |
</rng:optional> |
|---|
| 213 |
<rng:optional> |
|---|
| 214 |
<rng:attribute name="target"> |
|---|
| 215 |
<rng:data type="string"/> |
|---|
| 216 |
</rng:attribute> |
|---|
| 217 |
</rng:optional> |
|---|
| 218 |
<rng:optional> |
|---|
| 219 |
<rng:attribute name="label"> |
|---|
| 220 |
<rng:data type="string"/> |
|---|
| 221 |
</rng:attribute> |
|---|
| 222 |
</rng:optional> |
|---|
| 223 |
<rng:optional> |
|---|
| 224 |
<rng:attribute name="rng"> |
|---|
| 225 |
<rng:data type="string"/> |
|---|
| 226 |
</rng:attribute> |
|---|
| 227 |
</rng:optional> |
|---|
| 228 |
</rng:element> |
|---|
| 229 |
</rng:define> |
|---|
| 230 |
|
|---|
| 231 |
</rng:grammar> |
|---|