Trouble with makeCloud's parameter "seed" and yadedaily

Asked by Sacha Duverger

Hello,

I was trying to generate the same cloud of particles each time I run a script by setting the "seed" parameter of makeCloud at a fixed value. It works well when I run my script with yade 2018.02b but when I use yadedaily 20191105-2658~35899c7~bionic1 I can't get the same cloud twice.

Here is a MWE:

##################

sp = SpherePack()
sp.makeCloud((0,0,0), (1,1,1), rMean=1e-1, rRelFuzz=1e-2, seed=42)
sp.toSimulation()

s = 0
for b in O.bodies: s += b.state.pos[0]

print(s)

##################

yade 2018.02b outputs 31.0396276461 every time I run the script .
yadedaily 20191105-2658~35899c7~bionic1 outputs different values for each run (for instance 28.83197591069974 ; 26.124028261554287 ; ...)

Is there something else to set with yadedaily in order to generate the same cloud twice?

Thanks in advance

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Bruno Chareyre
Solved:
Last query:
Last reply:
Revision history for this message
Bruno Chareyre (bruno-chareyre) said :
#1

Hello, thanks for reporting this, it sounds like a serious issue.
It shouldn't be too difficult to fix though.
Bug report here: https://gitlab.com/yade-dev/trunk/issues/145
Bruno

Revision history for this message
Best Bruno Chareyre (bruno-chareyre) said :
#2

"seed" works as usual after [1] (merged).
B

[1] https://gitlab.com/yade-dev/trunk/-/merge_requests/428

Revision history for this message
Sacha Duverger (schmxprr) said :
#3

Thank you