source: cpp/tests/genomanipulation-fS.goal @ 1143

Last change on this file since 1143 was 1143, checked in by sz, 20 months ago

update test results, mostly because of r1142 (rgb defaults change)

File size: 24.7 KB
Line 
1    #############################################
2   ##                                           ##
3  ##    Welcome to Genotype Manipulation Demo!    ##
4   ##                                           ##
5    #############################################
6Found converter accepting f1: "Recursive encoding"
7Found 6 converter(s) producing f0
8
9Source genotype: '1.1,0,0.4:C[Gpart]{x=0.806,y=0.806,z=2.295}(C[N;M:p=0.899]{x=0.806,z=0.806}(E{rx=1.3416,ry=-1.3967,rz=1.1368,tx=-0.7694,ty=1.0496,tz=-0.1275,x=1,y=1,z=1},bIE[N,1]{rx=-1.277,ry=-1.087,rz=-0.9208,tx=1.189,ty=1.1182,tz=-0.1494,x=1,y=1,z=1}E{rx=0.4085,ry=1.0807,rz=0.5977,tx=0.4698,ty=0.3333,tz=1.4408,x=1,y=1,z=1}E{rx=-0.9279,ry=-0.2806,rz=-0.7292,tx=1.1498,ty=-0.6195,tz=0.0121,x=1,y=1,z=1}),biR[N]{ry=0.271,x=1.0144,y=0.903,z=0.903}(R{rx=0.3229,ry=-0.3828,rz=1.5117,tx=0.7618,ty=1.3803,tz=1.354,x=0.8736,y=0.8736,z=0.8736},E{rx=1.3416,ry=-1.3967,rz=1.1368,tx=-0.7694,ty=1.0496,tz=-0.1275,x=1,y=1,z=1}),iC{rx=-0.9744,ry=-1.5695,rz=1.1659,tx=-0.9065,ty=-1.2759,tz=-0.0857,x=1.273,y=0.133,z=1.509},R{rx=0.3229,ry=-0.3828,rz=1.5117,tx=0.7618,ty=1.3803,tz=1.354,x=0.8736,y=0.8736,z=0.8736},iE{rx=1.3416,ry=-1.3967,rz=1.1368,tx=-0.7694,ty=1.0496,tz=-0.1275,x=1,y=1,z=1})'
10                  ( format S )
11Converted to f0:
12p:sh=2, sx=0.806, sy=0.806, sz=2.295
13p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
14p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
15p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
16p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
17p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
18p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, ry=0.271
19p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
20p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
21p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
22p:0.1364642552368182, 0.619565647570761, 3.289951226640109, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
23p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
24j:0, 1, sh=1
25j:1, 2, sh=1
26j:1, 3, sh=2
27j:3, 4, sh=1
28j:4, 5, sh=1
29j:0, 6, sh=2
30j:6, 7, sh=1
31j:6, 8, sh=1
32j:0, 9, sh=1
33j:0, 10, sh=1
34j:0, 11, sh=1
35n:p=0, d=Gpart
36n:p=1
37n:j=0, d=M:p=0.899
38n:p=3
39n:p=6
40c:3, 1
41
42Model contains: 12 part(s)
43                11 joint(s)
44                5 neuron(s)
45
46Investigating details...
47    #############################################
48   ##                                           ##
49  ##    P A R T    O B J E C T                   ##
50   ##                                           ##
51    #############################################
52            (part # 6)
53Here is the full listing of properties as they are printed in f0
54 (please compare with f0 genotype).
55Some properties have special meaning (eg. geometry and connections groups)
56and should be handled with care, because they influence other elements of the model.
57
58 [this data is provided by Part::properties() ]
59 #        id                      type  name        group (21 properties)
60 0.        x = 2.044122892122303    f   position.x  Geometry 
61 1.        y = 0.0                  f   position.y  Geometry 
62 2.        z = 0.0                  f   position.z  Geometry 
63 3.       sh = 3                    d 0 3 0 shape       Geometry 
64 4.        s = 1.0                  f 0.1 10.0 1.0 size        Geometry 
65 5.       sx = 1.0144               f 0.05 5.0 1.0 scale.x     Geometry 
66 6.       sy = 0.903                f 0.05 5.0 1.0 scale.y     Geometry 
67 7.       sz = 0.903                f 0.05 5.0 1.0 scale.z     Geometry 
68 8.        h = 0.0                  f 0 1 0 hollow      Other properties
69 9.       dn = 1.0                  f 0.2 5.0 1.0 density     Other properties
7010.       fr = 0.4                  f 0.0 4.0 0.4 friction    Other properties
7111.      ing = 0.22727272727272727  f 0.0 1.0 0.25 ingestion   Other properties
7212.       as = 0.25                 f 0.0 1.0 0.25 assimilation  Other properties
7313.       rx = 0.0                  f   rot.x       Geometry 
7414.       ry = 0.271                f   rot.y       Geometry 
7515.       rz = 0.0                  f   rot.z       Geometry 
7616.        i =                      s   info        Other properties
7717.   Vstyle = part                 s 0 0 part vis_style   Visual   
7818.       vr = 0.5                  f 0.0 1.0 0.5 red component  Visual   
7919.       vg = 0.5                  f 0.0 1.0 0.5 green component  Visual   
8020.       vb = 0.5                  f 0.0 1.0 0.5 blue component  Visual   
81
82However, there is a subset of properties which may be modified more freely.
83Properties on this list are related only to this part and can be changed
84without much consideration. They are guaranteed to be always valid; any inconsistencies
85will be silently repaired.
86
87 [this data is provided by Part::extraProperties() ]
88 #        id                      type  name        group (8 properties)
89 0.        h = 0.0                  f 0 1 0 hollow      Extra properties
90 1.       dn = 1.0                  f 0.2 5.0 1.0 density     Extra properties
91 2.       fr = 0.4                  f 0.0 4.0 0.4 friction    Extra properties
92 3.      ing = 0.22727272727272727  f 0.0 1.0 0.25 ingestion   Extra properties
93 4.       as = 0.25                 f 0.0 1.0 0.25 assimilation  Extra properties
94 5.       vr = 0.5                  f 0.0 1.0 0.5 red component  Extra properties
95 6.       vg = 0.5                  f 0.0 1.0 0.5 green component  Extra properties
96 7.       vb = 0.5                  f 0.0 1.0 0.5 blue component  Extra properties
97
98This set of properties can vary from release to release,
99but can be safely accessed by using extraProperties() call.
100This method accesses the full set of properies (even those
101which appear in future releases).
102Now we will try to change some of properties:
103
104      Change property #4 to random value from range [0..1]
105      Current value of 'as' (assimilation) is '0.25'
106      Setting new value... [ using ParamInterface::set() ]
107      The value is now '0.715189'
108
109Let's see f0... (check out part #6 !)
110
111p:sh=2, sx=0.806, sy=0.806, sz=2.295
112p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
113p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
114p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
115p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
116p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
117p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
118p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
119p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
120p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
121p:0.1364642552368182, 0.619565647570761, 3.289951226640109, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
122p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
123j:0, 1, sh=1
124j:1, 2, sh=1
125j:1, 3, sh=2
126j:3, 4, sh=1
127j:4, 5, sh=1
128j:0, 6, sh=2
129j:6, 7, sh=1
130j:6, 8, sh=1
131j:0, 9, sh=1
132j:0, 10, sh=1
133j:0, 11, sh=1
134n:p=0, d=Gpart
135n:p=1
136n:j=0, d=M:p=0.899
137n:p=3
138n:p=6
139c:3, 1
140
141    #############################################
142   ##                                           ##
143  ##    J O I N T    O B J E C T                 ##
144   ##                                           ##
145    #############################################
146            (joint # 9)
147Similarly as with Part, the full list of properties comes first:
148
149 #        id                      type  name        group (21 properties)
150 0.       p1 = 0                    d -1 999999 -1 part1 ref#  Connections
151 1.       p2 = 10                   d -1 999999 -1 part2 ref#  Connections
152 2.       sh = 1                    d 0 3 0 shape       Geometry 
153 3.       hx = 0.0                  f   hinge position.x  Geometry 
154 4.       hy = 0.0                  f   hinge position.y  Geometry 
155 5.       hz = 0.0                  f   hinge position.z  Geometry 
156 6.      hrx = 0.0                  f   hinge rotation.x  Geometry 
157 7.      hry = 0.0                  f   hinge rotation.y  Geometry 
158 8.      hrz = 0.0                  f   hinge rotation.z  Geometry 
159 9.      hxn = -1.5708              f -6.2832 0 -1.5708 hinge x negative limit  Geometry 
16010.      hxp = 1.5708               f 0 6.2832 1.5708 hinge x positive limit  Geometry 
16111.      hyn = -1.5708              f -6.2832 0 -1.5708 hinge y negative limit  Geometry 
16212.      hyp = 1.5708               f 0 6.2832 1.5708 hinge y positive limit  Geometry 
16313.     stif = 1.0                  f 0.0 1.0 1.0 stiffness   Other properties
16414.  rotstif = 1.0                  f 0.0 1.0 1.0 rotation stiffness  Other properties
16515.     stam = 0.25                 f 0.0 1.0 0.25 stamina     Other properties
16616.        i =                      s   info        Other properties
16717.   Vstyle = joint                s 0 0 joint vis_style   Visual   
16818.       vr = 0.5                  f 0.0 1.0 0.5 red component  Visual   
16919.       vg = 0.5                  f 0.0 1.0 0.5 green component  Visual   
17020.       vb = 0.5                  f 0.0 1.0 0.5 blue component  Visual   
171
172Actually, there are two kinds of Joints: delta and absolute.
173For this object, Joint::isDelta() returns 0, so this is the absolute Joint.
174
175Absolute Joints adapt to its Parts' positions.
176We can move a Part, and it does not influence the second part, nor the Joint.
177Let's move the first Part along y axis by -0.1...
178The Part's position is changed, but everything else stays intact:
179
180p:y=-0.1, sh=2, sx=0.806, sy=0.806, sz=2.295
181p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
182p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
183p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
184p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
185p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
186p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
187p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
188p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
189p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
190p:0.1364642552368182, 0.619565647570761, 3.289951226640109, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
191p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
192j:0, 1, sh=1
193j:1, 2, sh=1
194j:1, 3, sh=2
195j:3, 4, sh=1
196j:4, 5, sh=1
197j:0, 6, sh=2
198j:6, 7, sh=1
199j:6, 8, sh=1
200j:0, 9, sh=1
201j:0, 10, sh=1
202j:0, 11, sh=1
203n:p=0, d=Gpart
204n:p=1
205n:j=0, d=M:p=0.899
206n:p=3
207n:p=6
208c:3, 1
209
210How would this joint look like with delta option enabled?
211[ by calling Joint::useDelta(1) ]
212f0 is now:
213
214p:y=-0.1, sh=2, sx=0.806, sy=0.806, sz=2.295
215p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
216p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
217p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
218p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
219p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
220p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
221p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
222p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
223p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
224p:0.13646425523681815, 0.6195656475707613, 3.289951226640109, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
225p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
226j:0, 1, sh=1
227j:1, 2, sh=1
228j:1, 3, sh=2
229j:3, 4, sh=1
230j:4, 5, sh=1
231j:0, 6, sh=2
232j:6, 7, sh=1
233j:6, 8, sh=1
234j:0, 9, sh=1
235j:0, 10, rx=0.3229, -0.3828, 1.5117, dx=-0.5550636879509978, 0.9656107299102641, 3.181143899353255, sh=1
236j:0, 11, sh=1
237n:p=0, d=Gpart
238n:p=1
239n:j=0, d=M:p=0.899
240n:p=3
241n:p=6
242c:3, 1
243
244...so this is a delta joint.
245
246Delta fields (dx,dy,dz) describe relative location of the second part.
247This joint will change the second Part's positions to preserve delta distance.
248Let's move the first Part (#0) along y axis (+0.1) and change delta.z (dz) by 0.1.
249Position of the second Part referenced by this joint (part #10) is now changed:
250
251p:sh=2, sx=0.806, sy=0.806, sz=2.295
252p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
253p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
254p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
255p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
256p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
257p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
258p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
259p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
260p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
261p:0.1702327285845081, 0.753051220526163, 3.3779194402835317, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
262p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
263j:0, 1, sh=1
264j:1, 2, sh=1
265j:1, 3, sh=2
266j:3, 4, sh=1
267j:4, 5, sh=1
268j:0, 6, sh=2
269j:6, 7, sh=1
270j:6, 8, sh=1
271j:0, 9, sh=1
272j:0, 10, rx=0.3229, -0.3828, 1.5117, dx=-0.5550636879509978, 0.9656107299102641, 3.281143899353255, sh=1
273j:0, 11, sh=1
274n:p=0, d=Gpart
275n:p=1
276n:j=0, d=M:p=0.899
277n:p=3
278n:p=6
279c:3, 1
280
281If no delta fields are defined, they will be computed automatically.
282You can always delete existing delta values by using Joint::resetDelta().
283Now we will change the second Part's z position by -0.2 and call resetDelta()...
284As you can see, Joint's delta fields have altered:
285
286p:sh=2, sx=0.806, sy=0.806, sz=2.295
287p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
288p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
289p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
290p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
291p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
292p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
293p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
294p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
295p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
296p:0.1702327285845081, 0.753051220526163, 3.1779194402835316, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
297p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
298j:0, 1, sh=1
299j:1, 2, sh=1
300j:1, 3, sh=2
301j:3, 4, sh=1
302j:4, 5, sh=1
303j:0, 6, sh=2
304j:6, 7, sh=1
305j:6, 8, sh=1
306j:0, 9, sh=1
307j:0, 10, rx=0.3229, -0.3828, 1.5117, dx=-0.48035983335347077, 0.9067404686418418, 3.10520747206641, sh=1
308j:0, 11, sh=1
309n:p=0, d=Gpart
310n:p=1
311n:j=0, d=M:p=0.899
312n:p=3
313n:p=6
314c:3, 1
315
316Part references and delta fields are the 'core' properties of the Joint.
317The other properties are available from Joint::extraProperties()
318and at the moment are defined as follows:
319
320 #        id                      type  name        group (5 properties)
321 0.     stif = 1.0                  f 0.0 1.0 1.0 stiffness   Extra properties
322 1.  rotstif = 1.0                  f 0.0 1.0 1.0 rotation stiffness  Extra properties
323 2.       vr = 0.5                  f 0.0 1.0 0.5 red component  Extra properties
324 3.       vg = 0.5                  f 0.0 1.0 0.5 green component  Extra properties
325 4.       vb = 0.5                  f 0.0 1.0 0.5 blue component  Extra properties
326
327They can be changed just like Part's extra properties:
328      Change property #3 to random value from range [0..1]
329      Current value of 'vg' (green component) is '0.5'
330      Setting new value... [ using ParamInterface::set() ]
331      The value is now '0.857946'
332And after that we have this genotype:
333
334p:sh=2, sx=0.806, sy=0.806, sz=2.295
335p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
336p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
337p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
338p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
339p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
340p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
341p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
342p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
343p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
344p:0.170232728584508, 0.7530512205261631, 3.1779194402835316, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
345p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
346j:0, 1, sh=1
347j:1, 2, sh=1
348j:1, 3, sh=2
349j:3, 4, sh=1
350j:4, 5, sh=1
351j:0, 6, sh=2
352j:6, 7, sh=1
353j:6, 8, sh=1
354j:0, 9, sh=1
355j:0, 10, rx=0.3229, -0.3828, 1.5117, dx=-0.48035983335347077, 0.9067404686418418, 3.10520747206641, sh=1, vg=0.857946
356j:0, 11, sh=1
357n:p=0, d=Gpart
358n:p=1
359n:j=0, d=M:p=0.899
360n:p=3
361n:p=6
362c:3, 1
363
364    #############################################
365   ##                                           ##
366  ##    N E U R O    O B J E C T                 ##
367   ##                                           ##
368    #############################################
369            (neuro # 2)
370Basic features of Neuro object are similar to those of Part and Joint.
371We can request a property list:
372
373 #        id                      type  name        group (10 properties)
374 0.        p = -1                   d -1 999999 -1 part ref#   Connections
375 1.        j = 0                    d -1 999999 -1 joint ref#  Connections
376 2.        d = M:p=0.899            s   details     Other     
377 3.        i =                      s   info        Other     
378 4.   Vstyle = neuro                s 0 0 neuro vis_style   Visual   
379 5. getInputCount = 0                    d   input count  Connections
380 9. classObject = null                 oNeuroClass neuron class  Connections
381
382...and extra properties (which are designed to be always valid and easy to change):
383
384 #        id                      type  name        group (0 properties)
385
386As usual, we will change something:
387Each neuron can have any number of inputs = weighted connections
388 with other neurons.
389According to Neuro::getInputCount(), this one has 0 inputs.
390Standard API is provided for accessing those inputs (getInput(int)),
391adding inputs (addInput(Neuro*)) and removing them (removeInput(int)).
392
393
394The most unusual thing is 'details' field (d).
395It is something like separate object with its own set of properties.
396Currently the value of 'd' is 'M:p=0.899'.
397'M' is the class name (Neuro::getClassName() == 'M') and means 'Muscle for solids'.
398Neuro::getClass() gives you information about basic characteristic
399of the class, that can be analyzed automatically.
400For the current object we can learn that it supports 1 inputs (getPreferredInputs()) and doesn't provide useful output signal (getPreferredOutput()==0).
401Instances of 'M' can be used in models having shape types: 'solid shapes'.
402Instances of 'M' can be attached to Joints having shapes: 'hinge x' 'hinge xy'.
403The class defines its own properties:
404
405 [ data provided by Neuro::classProperties() ]
406 #        id                      type  name        group (2 properties)
407 0.        p = 0.899                f 0.0 1.0 1.0 power       Muscle for solids
408 1.        a = 0                    d 0 1 0 axis        Muscle for solids
409and they can be changed:
410      Change property #1 to random value from range [0..1]
411      Current value of 'a' (axis) is '0'
412      Setting new value... [ using ParamInterface::set() ]
413      The value is now '0'
414After that, 'details' contains the new object: 'M:p=0.899'.
415The class of this object can be changed using Neuro::setClassName()
416The following classes are available:
417 [ data provided by Neuro::getClassInfo()->getProperties() ]
418
419 #  class  description       properties
420 0.     N  Neuron                 4
421 1.    Nu  Unipolar neuron [EXPERIMENTAL!]   4
422 2.     G  Gyroscope              0
423 3. Gpart  Part Gyroscope         2
424 4.     T  Touch                  3
425 5.Tcontact  Touch contact          0
426 6.Tproximity  Touch proximity        3
427 7.     S  Smell                  0
428 8.     *  Constant               0
429 9.     |  Bend muscle            2
43010.     @  Rotation muscle        1
43111.     M  Muscle for solids      2
43212.     D  Differentiate          0
43313. Fuzzy  Fuzzy system [EXPERIMENTAL!]   4
43414.   Sti  Sticky [EXPERIMENTAL!]   0
43515.   LMu  Linear muscle [EXPERIMENTAL!]   1
43616. Water  Water detector         0
43717.Energy  Energy level           0
43818.    Ch  Channelize             0
43919. ChMux  Channel multiplexer    0
44020. ChSel  Channel selector       1
44121.   Rnd  Random noise           0
44222.   Sin  Sinus generator        2
443
444Let's change the Neuro's class to 'Sti'...
445[WARN] Param.loadSingleLine: Unknown property 'Sti.p' (ignored)
446The final object description will be then: 'Sti'
447And the full f0 genotype:
448
449p:sh=2, sx=0.806, sy=0.806, sz=2.295
450p:1.6610658177212956, sh=2, sx=0.806, sz=0.806
451p:2.669522581015868, -0.12927953115999094, 1.770803754024758, sh=1, rx=1.3416, -1.3967, 1.1368
452p:2.5149067817465802, -0.12852148117052686, 1.7757109168238943, sh=1, ing=0.275, rx=-1.277, -1.087, -0.9208
453p:3.491120795397971, 0.0627093264475479, 3.542562176271334, sh=1, rx=0.4085, 1.0807, 0.5977
454p:4.82498021179015, -1.4556859677056804, 3.7057221690326423, sh=1, rx=-0.9279, -0.2806, -0.7292
455p:2.044122892122303, sh=3, sx=1.0144, sy=0.903, sz=0.903, ing=0.22727272727272727, as=0.715189, ry=0.271
456p:2.1225041839451873, 0.3558613626799459, 1.8896569415253044, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
457p:3.2159989925040344, -0.15022914055334208, 2.057760603467444, sh=1, rx=1.3416, -1.3967, 1.1368
458p:1.0846131653683386, -0.09317957887309433, -3.5838606901740344, sh=2, sx=1.273, sy=0.133, sz=1.509, ing=0.22727272727272727, rx=-0.9744, -1.5695, 1.1659
459p:0.170232728584508, 0.7530512205261631, 3.1779194402835316, sh=3, sx=0.8736, sy=0.8736, sz=0.8736, rx=0.3229, -0.3828, 1.5117
460p:1.6422082610960242, -0.21052356609516198, 2.883642273506047, sh=1, ing=0.22727272727272727, rx=1.3416, -1.3967, 1.1368
461j:0, 1, sh=1
462j:1, 2, sh=1
463j:1, 3, sh=2
464j:3, 4, sh=1
465j:4, 5, sh=1
466j:0, 6, sh=2
467j:6, 7, sh=1
468j:6, 8, sh=1
469j:0, 9, sh=1
470j:0, 10, rx=0.3229, -0.3828, 1.5117, dx=-0.48035983335347077, 0.9067404686418418, 3.10520747206641, sh=1, vg=0.857946
471j:0, 11, sh=1
472n:p=0, d=Gpart
473n:p=1
474n:j=0, d=Sti
475n:p=3
476n:p=6
477c:3, 1
478
479
480######### THE END ###########
481
482Hints:
483  1. You can redirect output: genomanipulation >filename.txt
484  2. Each run can yield different results and new behaviors, but you
485     need to uncomment rndRandomizeSeed() in genomanipulation.cpp.
486  3. This application will use custom genotype passed as
487     a commandline parameter: genomanipulation "/*9*/FULU"
488
489
Note: See TracBrowser for help on using the repository browser.