code: def test_return_inferencedata(self, simple_model, cores):
      with simple_model:
          idata = pm.sample(
              trace=mcb.NumPyBackend(),
              tune=5,
              draws=7,
              cores=cores,
              chains=3,
              discard_tuned_samples=False,
          )
      assert isinstance(idata, arviz.InferenceData)
      assert idata.warmup_posterior.sizes["draw"] == 5
      assert idata.posterior.sizes["draw"] == 7
      pass
  
imports: import logging
  import arviz
  import numpy
  import pytest
  import pymc
  from pymc.backends import init_traces
  from pymc.step_methods.arraystep import ArrayStepShared
  from pymc.backends.mcbackend import ChainRecordAdapter, find_data, get_variables_and_point_fn, make_runmeta_and_point_fn
label_desc: Use image node_id 2 for calling the TestMcBackendSampling obj's underlying member method code with example usage: obj.test_return_inferencedata(simple_model, cores) without return types