NESTCollaboration / nestpy

Raw Python bindings to the NEST library using pybind11.
GNU General Public License v3.0
13 stars 19 forks source link

Python binding to set random seed #94

Closed sebvetter closed 2 years ago

sebvetter commented 2 years ago

I added a python binding to set the random seed from nestpy. The initial seed is still generated as before, this way existing code should not be affected.

Usage (sets the seed to 0):

import nestpy
rng = nestpy.RandomGen.rndm()  
rng.set_seed(0)