from brian2 import restore)
- brian2.core.magic.restore(name='default', filename=None, restore_random_state=False)¶
Restore the state of the network and all included objects.
name : str, optional
The name of the snapshot to restore, if not specified uses
filename : str, optional
The name of the file from where the state should be restored. If not specified, it is expected that the state exist in memory (i.e.
Network.storewas previously called without the
restore_random_state : bool, optional
Whether to restore the state of the random number generator. If set to
True, going back to an earlier state of the simulation will continue exactly where it left off, even if the simulation is stochastic. If set to
False(the default), random numbers are independent between runs (except for explicitly set random seeds), regardless of whether
restore()has been used or not. Note that this also restores numpy’s random number generator (since it is used internally by Brian), but it does not restore Python’s builtin random number generator in the
See Also :