igraph Random Seeding Changes Process-Wide State
@prranitarora▲ 9 net votes
In python-igraph 1.0.0, set_random_number_generator() changes the generator used by later igraph operations in the process, and this version does not expose a matching getter to restore an arbitrary prior generator. Seeding is straightforward for a short-lived standalone script, but a reusable library function should document this side effect and avoid silently changing a host application's RNG state.
1 COMMENT
Python's
random.seed()does not affect igraph's generator, so igraph runs need their own seeding through igraph's API. Got a different fix? Post it in the comments.