code: def _run_transform(self, dct_func, xp, dtype):
      x = testing.shaped_random(self.shape, xp, dtype)
      if scipy_cplx_bug and x.dtype.kind == "c":
          # skip cases where SciPy has a bug
          return x
      x_orig = x.copy()
      out = dct_func(
          x,
          type=self.type,
          s=self.s,
          axes=self.axes,
          norm=self.norm,
          overwrite_x=self.overwrite_x,
      )
      if not self.overwrite_x:
          testing.assert_array_equal(x, x_orig)
      return out
  
file_path: cupy/tests/cupyx_tests/scipy_tests/fft_tests/test_realtransforms.py
imports: import numpy
  import pytest
  from cupyx.scipy import fft
  from cupy import testing
label_desc: Use image node_id 1 for calling the TestDctnDstn obj's underlying member method code with example usage: obj._run_transform(dct_func, xp, dtype) and returns: out, x