code: def test_with_composed_kernel(self):
      fake_inner_kernel = test_fixtures.TestTransitionKernel()
      cov_reducer = covariance_reducer.CovarianceReducer()
      reducer_kernel = with_reductions.WithReductions(
          inner_kernel=sample_discarding_kernel.SampleDiscardingKernel(
              inner_kernel=fake_inner_kernel,
              num_burnin_steps=10,
              num_steps_between_results=2,
          ),
          reducer=cov_reducer,
      )
      (
          current_state,
          kernel_results,
      ) = 0.0, reducer_kernel.bootstrap_results(0.0)
      seed = test_util.test_seed(sampler_type="stateless")
      for _ in range(2):
          mcmc_seed, seed = samplers.split_seed(seed)
          current_state, kernel_results = reducer_kernel.one_step(
              current_state, kernel_results, seed=mcmc_seed
          )
      cov = cov_reducer.finalize(kernel_results.reduction_results)
      self.assertAllEqual(16, current_state)
      self.assertAllEqual(2, kernel_results.inner_results.call_counter)
      self.assertAllEqual(
          16, kernel_results.inner_results.inner_results.counter_1
      )
      self.assertAllEqual(
          32, kernel_results.inner_results.inner_results.counter_2
      )
      self.assertAllEqual(np.var([13, 16]), cov)
  
imports: import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.experimental.mcmc import covariance_reducer
  from tensorflow_probability.python.experimental.mcmc import sample_discarding_kernel
  from tensorflow_probability.python.experimental.mcmc import with_reductions
  from tensorflow_probability.python.experimental.mcmc.internal import test_fixtures
  from tensorflow_probability.python.internal import samplers
  from tensorflow_probability.python.internal import test_util
label_desc: Use image node_id 7 for calling the SampleDiscardingTest obj's underlying member method code with example usage: obj.test_with_composed_kernel() without return types