Ignore:
Timestamp:
11/28/20 17:38:03 (3 years ago)
Author:
Maciej Komosinski
Message:

Updated test results after changes to evol_test and fS

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/tests/genomanipulation-default.goal

    r1009 r1033  
    4242 3.       sh = 0                    d 0 3 0 shape       Geometry 
    4343 4.        s = 1.0                  f 0.1 10.0 1.0 size        Geometry 
    44  5.       sx = 1.0                  f 0.001 1000.0 1.0 scale.x     Geometry 
    45  6.       sy = 1.0                  f 0.001 1000.0 1.0 scale.y     Geometry 
    46  7.       sz = 1.0                  f 0.001 1000.0 1.0 scale.z     Geometry 
     44 5.       sx = 1.0                  f 0.05 5.0 1.0 scale.x     Geometry 
     45 6.       sy = 1.0                  f 0.05 5.0 1.0 scale.y     Geometry 
     46 7.       sz = 1.0                  f 0.05 5.0 1.0 scale.z     Geometry 
    4747 8.        h = 0.0                  f 0 1 0 hollow      Other properties
    4848 9.       dn = 1.0                  f 0.2 5.0 1.0 density     Other properties
     
    8383Now we will try to change some of properties:
    8484
    85       Change property #0 to random value from range [0..1]
    86       Current value of 'h' (hollow) is '0.0'
     85      Change property #5 to random value from range [0.05..0.7]
     86      Current value of 'vs' (visual thickness) is '0.2'
    8787      Setting new value... [ using ParamInterface::set() ]
    88       The value is now '0.548814'
     88      The value is now '0.514873'
    8989
    9090Let's see f0... (check out part #1 !)
    9191
    9292p:vr=0.5, 0.5, 0.5
    93 p:1.0, h=0.548814, vr=0.5, 0.5, 0.5
     93p:1.0, vs=0.514873, vr=0.5, 0.5, 0.5
    9494j:0, 1, dx=1.0, 0.0, 0.0, vr=0.5, 0.5, 0.5
    9595n:p=1
     
    145145
    146146p:y=0.1, vr=0.5, 0.5, 0.5
    147 p:1.0, 0.1, 0.1, h=0.548814, vr=0.5, 0.5, 0.5
     147p:1.0, 0.1, 0.1, vs=0.514873, vr=0.5, 0.5, 0.5
    148148j:0, 1, dx=1.0, 0.0, 0.1, vr=0.5, 0.5, 0.5
    149149n:p=1
     
    159159
    160160p:y=0.1, vr=0.5, 0.5, 0.5
    161 p:1.0, 0.1, -0.1, h=0.548814, vr=0.5, 0.5, 0.5
     161p:1.0, 0.1, -0.1, vs=0.514873, vr=0.5, 0.5, 0.5
    162162j:0, 1, dx=1.0, 0.0, -0.1, vr=0.5, 0.5, 0.5
    163163n:p=1
     
    172172
    173173p:y=0.1, vr=0.5, 0.5, 0.5
    174 p:1.0, 0.1, -0.1, h=0.548814, vr=0.5, 0.5, 0.5
     174p:1.0, 0.1, -0.1, vs=0.514873, vr=0.5, 0.5, 0.5
    175175j:0, 1, vr=0.5, 0.5, 0.5
    176176n:p=1
     
    188188
    189189p:vr=0.5, 0.5, 0.5
    190 p:1.0, 0.1, -0.1, h=0.548814, vr=0.5, 0.5, 0.5
     190p:1.0, 0.1, -0.1, vs=0.514873, vr=0.5, 0.5, 0.5
    191191j:0, 1, vr=0.5, 0.5, 0.5
    192192n:p=1
     
    208208
    209209They can be changed just like Part's extra properties:
    210       Change property #4 to random value from range [0..1]
    211       Current value of 'vb' (blue component) is '0.5'
     210      Change property #3 to random value from range [0..1]
     211      Current value of 'vg' (green component) is '0.5'
    212212      Setting new value... [ using ParamInterface::set() ]
    213       The value is now '0.592845'
     213      The value is now '0.857946'
    214214And after that we have this genotype:
    215215
    216216p:vr=0.5, 0.5, 0.5
    217 p:1.0, 0.1, -0.1, h=0.548814, vr=0.5, 0.5, 0.5
    218 j:0, 1, vr=0.5, 0.5, 0.592845
     217p:1.0, 0.1, -0.1, vs=0.514873, vr=0.5, 0.5, 0.5
     218j:0, 1, vr=0.5, 0.857946, 0.5
    219219n:p=1
    220220n:j=0, d="|:p=0.25,r=1"
     
    228228   ##                                           ##
    229229    #############################################
    230             (neuro # 0)
     230            (neuro # 1)
    231231Basic features of Neuro object are similar to those of Part and Joint.
    232232We can request a property list:
    233233
    234234 #        id                      type  name        group (10 properties)
    235  0.        p = 1                    d -1 999999 -1 part ref#   Connections
    236  1.        j = -1                   d -1 999999 -1 joint ref#  Connections
    237  2.        d = N                    s   details     Other     
     235 0.        p = -1                   d -1 999999 -1 part ref#   Connections
     236 1.        j = 0                    d -1 999999 -1 joint ref#  Connections
     237 2.        d = |:p=0.25,r=1         s   details     Other     
    238238 3.        i =                      s   info        Other     
    239239 4.   Vstyle = neuro                s 0 0 neuro vis_style   Visual   
     
    255255The most unusual thing is 'details' field (d).
    256256It is something like separate object with its own set of properties.
    257 Currently the value of 'd' is 'N'.
    258 'N' is the class name (Neuro::getClassName() == 'N') and means 'Neuron'.
     257Currently the value of 'd' is '|:p=0.25,r=1'.
     258'|' is the class name (Neuro::getClassName() == '|') and means 'Bend muscle'.
    259259Neuro::getClass() gives you information about basic characteristic
    260260of the class, that can be analyzed automatically.
    261 For the current object we can learn that it supports any number of inputs (getPreferredInputs()) and provides meaningful output signal (getPreferredOutput()==1).
    262 Instances of 'N' can be used in models having any shape types.
     261For the current object we can learn that it supports 1 inputs (getPreferredInputs()) and doesn't provide useful output signal (getPreferredOutput()==0).
     262Instances of '|' can be used in models having shape types: 'ball-and-stick'.
     263Instances of '|' can be attached to Joints having any shapes.
    263264The class defines its own properties:
    264265
    265266 [ data provided by Neuro::classProperties() ]
    266  #        id                      type  name        group (4 properties)
    267  0.       in = 0.8                  f 0.0 1.0 0.8 Inertia     (null)   
    268  1.       fo = 0.04                 f 0.0 999.0 0.04 Force       (null)   
    269  2.       si = 2.0                  f -99999.0 99999.0 2.0 Sigmoid     (null)   
    270  3.        s = 0.0                  f -1.0 1.0 0.0 State       (null)   
     267 #        id                      type  name        group (2 properties)
     268 0.        p = 0.25                 f 0.01 1.0 0.25 power       Bend muscle
     269 1.        r = 1.0                  f 0.0 1.0 1.0 bending range  Bend muscle
    271270and they can be changed:
    272       Change property #0 to random value from range [0..1]
    273       Current value of 'in' (Inertia) is '0.8'
     271      Change property #1 to random value from range [0..1]
     272      Current value of 'r' (bending range) is '1.0'
    274273      Setting new value... [ using ParamInterface::set() ]
    275       The value is now '0.715189'
    276 After that, 'details' contains the new object: 'N:in=0.715189'.
     274      The value is now '0.423655'
     275After that, 'details' contains the new object: '|:r=0.423655'.
    277276The class of this object can be changed using Neuro::setClassName()
    278277The following classes are available:
     
    30430322.   Sin  Sinus generator        2
    305304
    306 Let's change the Neuro's class to 'Water'...
    307 [WARN] Param.loadSingleLine: Unknown property 'Water.in' (ignored)
     305Let's change the Neuro's class to 'Sti'...
     306[WARN] Param.loadSingleLine: Unknown property 'Sti.r' (ignored)
    308307Info for input #0 = ""
    309308Info for input #0, field "abc" = ""
    310 The final object description will be then: 'Water'
     309The final object description will be then: 'Sti'
    311310And the full f0 genotype:
    312311
    313312p:vr=0.5, 0.5, 0.5
    314 p:1.0, 0.1, -0.1, h=0.548814, vr=0.5, 0.5, 0.5
    315 j:0, 1, vr=0.5, 0.5, 0.592845
    316 n:p=1, d=Water
    317 n:j=0, d="|:p=0.25,r=1"
    318 n:j=0, d=G
    319 c:0, 2, 1.23, i="test=44,abc=yeah"
    320 c:1, 0
     313p:1.0, 0.1, -0.1, vs=0.514873, vr=0.5, 0.5, 0.5
     314j:0, 1, vr=0.5, 0.857946, 0.5
     315n:p=1
     316n:j=0, d=Sti
     317n:j=0, d=G
     318c:0, 2, 1.23
     319c:1, 0, i="test=44,abc=yeah"
    321320
    322321
     
    326325  1. You can redirect output: genomanipulation >filename.txt
    327326  2. Each run can yield different results and new behaviors, but you
    328      need to uncomment srand(time(0)) in genomanipulation.cpp.
     327     need to uncomment rndRandomizeSeed() in genomanipulation.cpp.
    329328  3. This application will use custom genotype passed as
    330329     a commandline parameter: genomanipulation "/*9*/FULU"
Note: See TracChangeset for help on using the changeset viewer.