code: def test_simulator_moment(self, seeded_test, mu, sigma, size):
      def normal_sim(rng, mu, sigma, size):
          return rng.normal(mu, sigma, size=size)
  
      with pm.Model() as model:
          x = pm.Simulator("x", normal_sim, mu, sigma, size=size)
  
      fn = make_initial_point_fn(
          model=model,
          return_transformed=False,
          default_strategy="moment",
      )
  
      random_draw = model["x"].eval()
      result = fn(0)["x"]
      assert result.shape == random_draw.shape
  
      # We perform a z-test between the moment and expected mean from a sample of 10 draws
      # This test fails if the number of samples averaged in moment(Simulator)
      # is much smaller than 10, but would not catch the case where the number of samples
      # is higher than the expected 10
  
      n = 10  # samples
      expected_sample_mean = mu
      expected_sample_mean_std = np.sqrt(sigma**2 / n)
  
      # Multiple test adjustment for z-test to maintain alpha=0.01
      alpha = 0.01
      alpha /= 2 * 2 * 3  # Correct for number of test permutations
      alpha /= random_draw.size  # Correct for distribution size
      cutoff = st.norm().ppf(1 - (alpha / 2))
  
      assert np.all(
          np.abs(
              (result - expected_sample_mean) / expected_sample_mean_std
          )
          < cutoff
      )
  
imports: import warnings
  import cloudpickle
  import numpy
  import pytensor
  import pytest
  import scipy.stats
  from pytensor.graph import ancestors
  from pytensor.tensor.random.op import RandomVariable
  from pytensor.tensor.random.var import RandomGeneratorSharedVariable, RandomStateSharedVariable
  from pytensor.tensor.sort import SortOp
  import pymc
  from pymc import floatX
  from pymc.initial_point import make_initial_point_fn
  from pymc.pytensorf import compile_pymc
  from pymc.smc.kernels import IMH
label_desc: Use image node_id 18 for calling the TestSimulator obj's underlying member method code with example usage: obj.test_simulator_moment(seeded_test, mu, sigma, size) and returns: rng