[Numpy-discussion] Purpose for bit-wise and'ing the initial mersenne twister key?

Michael S. Gilbert michael.s.gilbert at gmail.com
Fri Feb 13 10:07:56 EST 2009


On Fri, 13 Feb 2009 12:54:10 +0100 Sturla Molden wrote:
> If you are that obsessed with speed, consider to use the new SIMD 
> version of the Mersenne Twister instead of Jean-Sebastien Roy's 
> randomkit.c (used by NumPy). But I think randomkit.c is fast enough for 
> most purposes.
> 
> http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/SFMT/index.html

I had already come across this, and was going to suggest using it as
well at some point.  However, as per Robert's last comment, it sounds
like quite a bit of work needs to be done first to make drop-in
replacements for the PRNG possible.

I'm not "obsessed" with speed, but a 2x improvement is quite
significant.



More information about the NumPy-Discussion mailing list