docstr: Read image by DICOM module.
  Notice that PIL only supports uint8 for RGB (not uint16).
  So this imread function returns only uint8 array for both RGB and gray-scale.
  (Currently ignore "I" mode for gray-scale (32bit integer).)
  
  Args:
      path (str or 'file object'): File path or object to read.
      grayscale (bool):
      size (tupple of int):
          (width, height).
          If None, output img shape depends on the files to read.
      channel_first (bool):
          This argument specifies the shape of img is whether (height, width, channel) or (channel, height, width).
          Default value is False, which means the img shape is (height, width, channel).
      interpolate (str):
          must be one of ["nearest", "box", "bilinear", "hamming", "bicubic", "lanczos"].
      as_uint16 (bool):
          If you specify this argument, you can use only False for pil backend.
      num_channels (int):
          channel size of output array.
          Default is -1 which preserves raw image shape.
      return_palette_indices (bool):
          Whether to return a raw palette indices without any conversion or not.
          If this flag is True and read Image has the mode "P",
          then this function returns 2-D array containing the indices into palette.
          We recommend that this flag should be False unless you intend to use the raw palette indices.
  
  Returns:
      numpy.ndarray
docstr_tok: ["Read","image","by","DICOM","module",".","Notice","that","PIL","only","supports","uint8","for","RGB","(","not","uint16",")",".","So","this","imread","function","returns","only","uint8","array","for","both","RGB","and","gray-scale",".","(","Currently","ignore","``","I","''","mode","for","gray-scale","(","32bit","integer",")",".",")","Args",":","path","(","str","or","'file","object","'",")",":","File","path","or","object","to","read",".","grayscale","(","bool",")",":","size","(","tupple","of","int",")",":","(","width",",","height",")",".","If","None",",","output","img","shape","depends","on","the","files","to","read",".","channel_first","(","bool",")",":","This","argument","specifies","the","shape","of","img","is","whether","(","height",",","width",",","channel",")","or","(","channel",",","height",",","width",")",".","Default","value","is","False",",","which","means","the","img","shape","is","(","height",",","width",",","channel",")",".","interpolate","(","str",")",":","must","be","one","of","[","``","nearest","''",",","``","box","''",",","``","bilinear","''",",","``","hamming","''",",","``","bicubic","''",",","``","lanczos","''","]",".","as_uint16","(","bool",")",":","If","you","specify","this","argument",",","you","can","use","only","False","for","pil","backend",".","num_channels","(","int",")",":","channel","size","of","output","array",".","Default","is","-1","which","preserves","raw","image","shape",".","return_palette_indices","(","bool",")",":","Whether","to","return","a","raw","palette","indices","without","any","conversion","or","not",".","If","this","flag","is","True","and","read","Image","has","the","mode","``","P","''",",","then","this","function","returns","2-D","array","containing","the","indices","into","palette",".","We","recommend","that","this","flag","should","be","False","unless","you","intend","to","use","the","raw","palette","indices",".","Returns",":","numpy.ndarray"]
code: def imread(
      self,
      path,
      grayscale=False,
      size=None,
      interpolate="bilinear",
      channel_first=False,
      as_uint16=False,
      num_channels=-1,
      return_palette_indices=False,
  ):
      """
      Read image by DICOM module.
      Notice that PIL only supports uint8 for RGB (not uint16).
      So this imread function returns only uint8 array for both RGB and gray-scale.
      (Currently ignore "I" mode for gray-scale (32bit integer).)
  
      Args:
          path (str or 'file object'): File path or object to read.
          grayscale (bool):
          size (tupple of int):
              (width, height).
              If None, output img shape depends on the files to read.
          channel_first (bool):
              This argument specifies the shape of img is whether (height, width, channel) or (channel, height, width).
              Default value is False, which means the img shape is (height, width, channel).
          interpolate (str):
              must be one of ["nearest", "box", "bilinear", "hamming", "bicubic", "lanczos"].
          as_uint16 (bool):
              If you specify this argument, you can use only False for pil backend.
          num_channels (int):
              channel size of output array.
              Default is -1 which preserves raw image shape.
          return_palette_indices (bool):
              Whether to return a raw palette indices without any conversion or not.
              If this flag is True and read Image has the mode "P",
              then this function returns 2-D array containing the indices into palette.
              We recommend that this flag should be False unless you intend to use the raw palette indices.
  
      Returns:
          numpy.ndarray
      """
      _imread_before(grayscale, num_channels)
      dicom_dataset = pydicom.dcmread(path)
      img = _apply_gamma_correction(dicom_dataset)
      return _imread_after(
          img, size, interpolate, channel_first, self.imresize
      )
  
file_path: nnabla/python/src/nnabla/utils/image_utils/backend_events/dicom_backend.py
imports: from __future__ import absolute_import, division
  import numpy
  import pydicom
  from .common import _imread_before, _imread_after
  from .image_utils_backend import ImageUtilsBackend
label_desc: Use image node_id 3 for calling the DicomBackend obj's underlying member method code with example usage: obj.imread(path, grayscale, size, interpolate, channel_first, as_uint16, num_channels, return_palette_indices) and returns: _imread_after