zero.randomΒΆ Random sampling utilities. seed Set seeds in random, numpy and torch. get_state Aggregate global random states from random, numpy and torch. set_state Set global random states in random, numpy and torch. preserve_state Decorator and a context manager for preserving global random state.