parameters: (str_img, clip_rect=(0, 0, 0, 0), out=None, index=0, channels=3, mean=None)
docstring: Decode an image from string. Requires OpenCV to work.
  
      Parameters
      ----------
      str_img : str
          binary image data
      clip_rect : iterable of 4 int
          clip decoded image to rectangle (x0, y0, x1, y1)
      out : NDArray
          output buffer. can be 3 dimensional (c, h, w) or 4 dimensional (n, c, h, w)
      index : int
          output decoded image to i-th slice of 4 dimensional buffer
      channels : int
          number of channels to output. Decode to grey scale when channels = 1.
      mean : NDArray
          substract mean from decode image before outputing.
docstring_summary: Decode an image from string. Requires OpenCV to work.
docstring_tokens: Decode an image from string . Requires OpenCV to work .
function: def imdecode(str_img, clip_rect=(0, 0, 0, 0), out=None, index=0, channels=3, mean=None):
      """Decode an image from string. Requires OpenCV to work.
  
      Parameters
      ----------
      str_img : str
          binary image data
      clip_rect : iterable of 4 int
          clip decoded image to rectangle (x0, y0, x1, y1)
      out : NDArray
          output buffer. can be 3 dimensional (c, h, w) or 4 dimensional (n, c, h, w)
      index : int
          output decoded image to i-th slice of 4 dimensional buffer
      channels : int
          number of channels to output. Decode to grey scale when channels = 1.
      mean : NDArray
          substract mean from decode image before outputing.
      """
      # pylint: disable= no-member, protected-access, too-many-arguments
      if mean is None:
          mean = NDArray(_new_empty_handle())
      if out is None:
          return NDArray._imdecode(mean, index,
                                   clip_rect[0],
                                   clip_rect[1],
                                   clip_rect[2],
                                   clip_rect[3],
                                   channels,
                                   len(str_img),
                                   str_img=str_img)
      else:
          return NDArray._imdecode(mean, index,
                                   clip_rect[0],
                                   clip_rect[1],
                                   clip_rect[2],
                                   clip_rect[3],
                                   channels,
                                   len(str_img),
                                   str_img=str_img,
                                   out=out)
function_tokens: def imdecode ( str_img , clip_rect = ( 0 , 0 , 0 , 0 ) , out = None , index = 0 , channels = 3 , mean = None ) : # pylint: disable= no-member, protected-access, too-many-arguments if mean is None : mean = NDArray ( _new_empty_handle ( ) ) if out is None : return NDArray . _imdecode ( mean , index , clip_rect [ 0 ] , clip_rect [ 1 ] , clip_rect [ 2 ] , clip_rect [ 3 ] , channels , len ( str_img ) , str_img = str_img ) else : return NDArray . _imdecode ( mean , index , clip_rect [ 0 ] , clip_rect [ 1 ] , clip_rect [ 2 ] , clip_rect [ 3 ] , channels , len ( str_img ) , str_img = str_img , out = out )