code: def test_dim(self):
      q = np.random.randint(0, 100, size=50)
      results = []
      for p in TEST_NDARRAYS:
          arr = p(np.arange(6).reshape(1, 2, 3).astype(np.float32))
          results.append(percentile(arr, q, dim=1))
          assert_allclose(
              results[0], results[-1], type_test=False, atol=1e-4
          )
  
file_path: MONAI/tests/test_utils_pytorch_numpy_unification.py
imports: from __future__ import annotations
  import unittest
  import numpy
  import torch
  from parameterized import parameterized
  from monai.transforms.utils_pytorch_numpy_unification import mode, percentile
  from monai.utils import set_determinism
  from tests.utils import TEST_NDARRAYS, assert_allclose, skip_if_quick
label_desc: Use image node_id 5 for calling the TestPytorchNumpyUnification obj's underlying member method code with example usage: obj.test_dim() without return types