Sorry Phil, you're right, it's a stupid mistake of mine. Calling the Python function seed() before randint() solves my problem.
Thank you. 2009/7/25 Philip Levis <[email protected]> > > On Jul 23, 2009, at 6:52 PM, Yee Wei Law wrote: > > >> >> The times are different. Now, I did use randint() to randomize the times >> as such: >> >> t.getNode(0).bootAtTime(1*t.ticksPerSecond()) >> for i in range(1, nNodes): >> t.getNode(i).bootAtTime(randint(0, 1*t.ticksPerSecond())) >> >> But I thought randint() should produce the the same random values, given >> the same seed through t.randomSeed()? >> > > No -- randint() is a python library. Its seed is independent of > t.randomSeed. If you look at the log you'll see it returns different values > across executions. > > Phil >
_______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
