code: def preprocess(self, cfg, imgs_path, batch_size, batch_id):
      data_array, original_spacing = self.load_medical_data(
          imgs_path[batch_id : (batch_id + batch_size)][0]
      )
      self.shape = data_array.shape
      self.target_spacing = [1.52, 1.52, 6.35]
      new_shape = np.round(
          (
              (
                  np.array(original_spacing)
                  / np.array(self.target_spacing)
              ).astype(float)
              * np.array(self.shape)
          )
      ).astype(int)
      data_array = resize_image(data_array, new_shape)
      data_array = np.transpose(data_array, [2, 0, 1])
      mean = np.mean(data_array)
      std = np.std(data_array)
      data_array = (data_array - mean) / (std + 1e-10)
      return np.expand_dims(data_array.astype("float32"), [0, 1])
  
file_path: PaddleSeg/contrib/MedicalSeg/medicalseg/inference_helpers/nnformer_inference_helper.py
imports: import numpy
  import nibabel
  import os
  import sys
  from medicalseg.cvlibs import manager
  from medicalseg.inference_helpers import InferenceHelper
  from tools.preprocess_utils.geometry import resize_image, resize_segmentation
label_desc: Use image node_id 2 for calling the NNFormerInferenceHelper obj's underlying member method code with example usage: obj.preprocess(cfg, imgs_path, batch_size, batch_id) and returns: np