code: def test_specified_rng():
      from lasagne.random import get_rng, set_rng
      from lasagne.init import (
          Normal,
          Uniform,
          GlorotNormal,
          GlorotUniform,
          Sparse,
          Orthogonal,
      )
  
      from numpy.random import RandomState
      from numpy import allclose
  
      seed = 123456789
      rng = get_rng()
  
      for init_class in [
          Normal,
          Uniform,
          GlorotNormal,
          GlorotUniform,
          Sparse,
          Orthogonal,
      ]:
          set_rng(RandomState(seed))
          sample1 = init_class().sample((100, 100))
          set_rng(RandomState(seed))
          sample2 = init_class().sample((100, 100))
          set_rng(rng)  # reset to original RNG for other tests
          assert allclose(
              sample1, sample2
          ), "random initialization was inconsistent for {}".format(
              init_class.__name__
          )
  
imports: import pytest
label_desc: Use image node_id 3 for calling a global function with example usage: test_specified_rng() without return types