class_docstr: EncodedVideo is an abstraction for accessing clips from an encoded video.
  It supports selective decoding when header information is available.
class_docstr_tok: ["EncodedVideo","is","an","abstraction","for","accessing","clips","from","an","encoded","video",".","It","supports","selective","decoding","when","header","information","is","available","."]
docstr: Fetches the given video path using PathManager (allowing remote uris to be
  fetched) and constructs the EncodedVideo object.
  
  Args:
      file_path (str): a PathManager file-path.
docstr_tok: ["Fetches","the","given","video","path","using","PathManager","(","allowing","remote","uris","to","be","fetched",")","and","constructs","the","EncodedVideo","object",".","Args",":","file_path","(","str",")",":","a","PathManager","file-path","."]
code: def from_path(
      cls,
      file_path: str,
      decode_video: bool = True,
      decode_audio: bool = True,
      decoder: str = "pyav",
      **other_args: Dict[str, Any],
  ):
      """
      Fetches the given video path using PathManager (allowing remote uris to be
      fetched) and constructs the EncodedVideo object.
  
      Args:
          file_path (str): a PathManager file-path.
      """
      # We read the file with PathManager so that we can read from remote uris.
      with g_pathmgr.open(file_path, "rb") as fh:
          video_file = io.BytesIO(fh.read())
  
      video_cls = select_video_class(decoder)
      return video_cls(
          file=video_file,
          video_name=pathlib.Path(file_path).name,
          decode_video=decode_video,
          decode_audio=decode_audio,
          **other_args,
      )
  
file_path: pytorchvideo/pytorchvideo/data/encoded_video.py
imports: import io
  import logging
  import pathlib
  from typing import Any, Dict
  from iopath.common.file_io import g_pathmgr
  from pytorchvideo.data.decoder import DecoderType
  from .video import Video
label_desc: Use image node_id 1 for calling the EncodedVideo obj's underlying member method code with example usage: obj.from_path(cls, file_path, decode_video, decode_audio, decoder) and returns: video_cls