class_docstr: A plugin to  make old (v2.9) plugins compatible with v3.0
  
  .. depreciated:: 2.9
      `legacy_get_reader` will be removed in a future version of imageio.
      `legacy_get_writer` will be removed in a future version of imageio.
  
  This plugin is a wrapper around the old FormatManager class and exposes
  all the old plugins via the new API. On top of this it has
  ``legacy_get_reader`` and ``legacy_get_writer`` methods to allow using
  it with the v2.9 API.
  
  Methods
  -------
  read(index=None, **kwargs)
      Read the image at position ``index``.
  write(image, **kwargs)
      Write image to the URI.
  iter(**kwargs)
      Iteratively yield images from the given URI.
  get_meta(index=None)
      Return the metadata for the image at position ``index``.
  legacy_get_reader(**kwargs)
      Returns the v2.9 image reader. (depreciated)
  legacy_get_writer(**kwargs)
      Returns the v2.9 image writer. (depreciated)
  
  Examples
  --------
  
  >>> import imageio.v3 as iio
  >>> with iio.imopen("/path/to/image.tiff", "r", legacy_mode=True) as file:
  >>>     reader = file.legacy_get_reader()  # depreciated
  >>>     for im in file.iter():
  >>>         print(im.shape)
class_docstr_tok: ["A","plugin","to","make","old","(","v2.9",")","plugins","compatible","with","v3.0","..","depreciated",":",":","2.9","`","legacy_get_reader","`","will","be","removed","in","a","future","version","of","imageio",".","`","legacy_get_writer","`","will","be","removed","in","a","future","version","of","imageio",".","This","plugin","is","a","wrapper","around","the","old","FormatManager","class","and","exposes","all","the","old","plugins","via","the","new","API",".","On","top","of","this","it","has","``","legacy_get_reader","``","and","``","legacy_get_writer","``","methods","to","allow","using","it","with","the","v2.9","API",".","Methods","--","--","--","-","read","(","index=None",",","*","*","kwargs",")","Read","the","image","at","position","``","index","``",".","write","(","image",",","*","*","kwargs",")","Write","image","to","the","URI",".","iter","(","*","*","kwargs",")","Iteratively","yield","images","from","the","given","URI",".","get_meta","(","index=None",")","Return","the","metadata","for","the","image","at","position","``","index","``",".","legacy_get_reader","(","*","*","kwargs",")","Returns","the","v2.9","image","reader",".","(","depreciated",")","legacy_get_writer","(","*","*","kwargs",")","Returns","the","v2.9","image","writer",".","(","depreciated",")","Examples","--","--","--","--",">",">",">","import","imageio.v3","as","iio",">",">",">","with","iio.imopen","(","``","\/path\/to\/image.tiff","''",",","``","r","''",",","legacy_mode=True",")","as","file",":",">",">",">","reader","=","file.legacy_get_reader","(",")","#","depreciated",">",">",">","for","im","in","file.iter","(",")",":",">",">",">","print","(","im.shape",")"]
docstr: Parses the given URI and creates a ndarray from it.
  
  Parameters
  ----------
  index : {integer, None}
      If the URI contains a list of ndimages return the index-th
      image. If None, stack all images into an ndimage along the
      0-th dimension (equivalent to np.stack(imgs, axis=0)).
  kwargs : ...
      Further keyword arguments are passed to the reader. See
      :func:`.help` to see what arguments are available for a particular
      format.
  
  Returns
  -------
  ndimage : np.ndarray
      A numpy array containing the decoded image data.
docstr_tok: ["Parses","the","given","URI","and","creates","a","ndarray","from","it",".","Parameters","--","--","--","--","--","index",":","{","integer",",","None","}","If","the","URI","contains","a","list","of","ndimages","return","the","index-th","image",".","If","None",",","stack","all","images","into","an","ndimage","along","the","0-th","dimension","(","equivalent","to","np.stack","(","imgs",",","axis=0",")",")",".","kwargs",":","...","Further","keyword","arguments","are","passed","to","the","reader",".","See",":","func",":","`",".help","`","to","see","what","arguments","are","available","for","a","particular","format",".","Returns","--","--","--","-","ndimage",":","np.ndarray","A","numpy","array","containing","the","decoded","image","data","."]
code: def read(self, *, index=None, **kwargs):
      """
      Parses the given URI and creates a ndarray from it.
  
      Parameters
      ----------
      index : {integer, None}
          If the URI contains a list of ndimages return the index-th
          image. If None, stack all images into an ndimage along the
          0-th dimension (equivalent to np.stack(imgs, axis=0)).
      kwargs : ...
          Further keyword arguments are passed to the reader. See
          :func:`.help` to see what arguments are available for a particular
          format.
  
      Returns
      -------
      ndimage : np.ndarray
          A numpy array containing the decoded image data.
  
      """
  
      if index is None:
          index = _legacy_default_index(self._format)
  
      if index is Ellipsis:
          img = np.stack([im for im in self.iter(**kwargs)])
          return img
  
      reader = self.legacy_get_reader(**kwargs)
      return reader.get_data(index)
  
file_path: imageio/imageio/core/legacy_plugin_wrapper.py
imports: from pathlib import Path
  import numpy
  from ..config import known_extensions
  from .request import InitializationError, IOMode
  from .v3_plugin_api import ImageProperties, PluginV3
label_desc: Use image node_id 3 for calling the LegacyPlugin obj's underlying member method code with example usage: obj.read() and returns: reader, img