Solved by ptrblck in post #2 
              
              
                By default the system PRNG is used, if I’m not mistaken, so your code will not be deterministic if you don’t properly seed it manually. 
Since you are using 3rd party libraries, such as numpy, I would recommend to also seed them. 
Have a look at the Reproducibility docs for more information.