mersenne twister python implementation