MCPcopy Create free account
hub / github.com/numpy/numpy / test_gaussian_reset

Method test_gaussian_reset

numpy/random/tests/test_randomstate.py:202–207  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

200 assert_(np.all(old == new))
201
202 def test_gaussian_reset(self):
203 # Make sure the cached every-other-Gaussian is reset.
204 old = self.random_state.standard_normal(size=3)
205 self.random_state.set_state(self.state)
206 new = self.random_state.standard_normal(size=3)
207 assert_(np.all(old == new))
208
209 def test_gaussian_reset_in_media_res(self):
210 # When the state is saved with a cached Gaussian, make sure the

Callers

nothing calls this directly

Calls 2

assert_Function · 0.90
allMethod · 0.45

Tested by

no test coverage detected