REST version : v2.2.12_dev
REST commit : dc729211
The new update of seed is not working in my case. There are two independent problems.
- The random number is not retrieved properly.
When I do in my console echo $RANDOM
a random number comes out normally. But when I enter in a ROOT session and I do.
TRestTools::Execute("echo $RANDOM")
it returns an empty string. This is the method used in restG4.cc
and so it results in the same fixed number for each simulation.
This echo RANDOM method was working previously?
- The second problem is that when the seed is assigned/updated to
TRestG4Metadata
in restG4.cc that value is not registered/stored to disk, sinceWrite
call must happen before, probably once the RML is read.
A solution to this second problem would be to integrate the random number generation inside TRestG4Metadata
when using a keyword? For example, <parameter name="seed" value="random" />
?