class_docstr: Normalize a ``numpy.array`` image with mean and standard deviation.
  
  This transform does not support PIL Image.
  Given mean: ``(mean[1],...,mean[n])`` and std: ``(std[1],..,std[n])`` for ``n``
  channels, this transform will normalize each channel of the input
  ``numpy.array`` i.e.,
  ``output[channel] = (input[channel] - mean[channel]) / std[channel]``
  
  .. note::
      This transform acts out of place, i.e., it does not mutate the input array.
  
  Args:
      mean (Sequence): Sequence of means for each channel.
      std (Sequence): Sequence of standard deviations for each channel.
      inplace(bool, optional): Bool to make this operation in-place.
docstr: Args:
      img (Numpy ndarray): Array image to be normalized.
  
  Returns:
      d_res (Numpy ndarray): Normalized Tensor image.
docstr_tok: ["Args",":","img","(","Numpy","ndarray",")",":","Array","image","to","be","normalized",".","Returns",":","d_res","(","Numpy","ndarray",")",":","Normalized","Tensor","image","."]
code: def forward(self, img: np.ndarray):
      """
      Args:
          img (Numpy ndarray): Array image to be normalized.
  
      Returns:
          d_res (Numpy ndarray): Normalized Tensor image.
      """
      if not isinstance(img, np.ndarray):
          raise TypeError(
              "Input img should be a numpy array. Got {}.".format(
                  type(img)
              )
          )
  
      if not img.dtype == np.float:
          raise TypeError(
              "Input array should be a float array. Got {}.".format(
                  img.dtype
              )
          )
  
      if img.ndim < 3:
          raise ValueError(
              "Expected array to be an array image of size (..., C, H, W). Got img.shape = "
              "{}.".format(img.shape)
          )
  
      if not self.inplace:
          img = img.copy()
  
      dtype = img.dtype
      mean = np.array(self.mean, dtype=dtype)
      std = np.array(self.std, dtype=dtype)
      if (std == 0).any():
          raise ValueError(
              "std evaluated to zero after conversion to {}, leading to division by zero.".format(
                  dtype
              )
          )
      s_res = np.subtract(img, mean[:, None, None])
      d_res = np.divide(s_res, std[:, None, None])
  
      return d_res
  
file_path: singa/examples/demos/Classification/BloodMnist/transforms.py
imports: import numpy
  from PIL import Image
label_desc: Use image node_id 2 for calling the Normalize obj's underlying member method code with example usage: obj.forward(img) and returns: d_res