docstr: Read frames from the disk
  
  Args:
      predicate (AbstractExpression, optional): If only subset of frames
      need to be read. The predicate should be only on single column and
      can be converted to ranges. Defaults to None.
      sampling_rate (int, optional): Set if the caller wants one frame
      every `sampling_rate` number of frames. For example, if `sampling_rate = 10`, it returns every 10th frame. If both `predicate` and `sampling_rate` are specified, `sampling_rate` is given precedence.
      sampling_type (str, optional): Set as IFRAMES if caller want to sample on top on iframes only. e.g if the IFRAME frame numbers are [10,20,30,40,50] then 'SAMPLE IFRAMES 2' will return [10,30,50]
      read_audio (bool, optional): Whether to read audio stream from the video. Defaults to False
      read_video (bool, optional): Whether to read video stream from the video. Defaults to True
docstr_tok: ["Read","frames","from","the","disk","Args",":","predicate","(","AbstractExpression",",","optional",")",":","If","only","subset","of","frames","need","to","be","read",".","The","predicate","should","be","only","on","single","column","and","can","be","converted","to","ranges",".","Defaults","to","None",".","sampling_rate","(","int",",","optional",")",":","Set","if","the","caller","wants","one","frame","every","`","sampling_rate","`","number","of","frames",".","For","example",",","if","`","sampling_rate","=","10","`",",","it","returns","every","10th","frame",".","If","both","`","predicate","`","and","`","sampling_rate","`","are","specified",",","`","sampling_rate","`","is","given","precedence",".","sampling_type","(","str",",","optional",")",":","Set","as","IFRAMES","if","caller","want","to","sample","on","top","on","iframes","only",".","e.g","if","the","IFRAME","frame","numbers","are","[","10,20,30,40,50","]","then","'SAMPLE","IFRAMES","2","'","will","return","[","10,30,50","]","read_audio","(","bool",",","optional",")",":","Whether","to","read","audio","stream","from","the","video",".","Defaults","to","False","read_video","(","bool",",","optional",")",":","Whether","to","read","video","stream","from","the","video",".","Defaults","to","True"]
code: def __init__(
      self,
      *args,
      predicate: AbstractExpression = None,
      sampling_rate: int = None,
      sampling_type: str = None,
      read_audio: bool = False,
      read_video: bool = True,
      **kwargs,
  ):
      """Read frames from the disk
  
      Args:
          predicate (AbstractExpression, optional): If only subset of frames
          need to be read. The predicate should be only on single column and
          can be converted to ranges. Defaults to None.
          sampling_rate (int, optional): Set if the caller wants one frame
          every `sampling_rate` number of frames. For example, if `sampling_rate = 10`, it returns every 10th frame. If both `predicate` and `sampling_rate` are specified, `sampling_rate` is given precedence.
          sampling_type (str, optional): Set as IFRAMES if caller want to sample on top on iframes only. e.g if the IFRAME frame numbers are [10,20,30,40,50] then 'SAMPLE IFRAMES 2' will return [10,30,50]
          read_audio (bool, optional): Whether to read audio stream from the video. Defaults to False
          read_video (bool, optional): Whether to read video stream from the video. Defaults to True
      """
      self._predicate = predicate
      self._sampling_rate = sampling_rate or 1
      self._sampling_type = sampling_type
      self._read_audio = read_audio
      self._read_video = read_video
      self._reader = None
      self._get_frame = None
      super().__init__(*args, **kwargs)
      self.initialize_reader()
  
file_path: evadb/evadb/readers/decord_reader.py
imports: from typing import Dict, Iterator
  import numpy
  from evadb.catalog.catalog_type import VideoColumnName
  from evadb.catalog.sql_config import ROW_NUM_COLUMN
  from evadb.constants import AUDIORATE, IFRAMES
  from evadb.expression.abstract_expression import AbstractExpression
  from evadb.expression.expression_utils import extract_range_list_from_predicate
  from evadb.readers.abstract_reader import AbstractReader
  from evadb.utils.generic_utils import try_to_import_decord
  from evadb.utils.logging_manager import logger
label_desc: Use image node_id 1 to create a new DecordReader object from inherited base classes: AbstractReader with example: obj = DecordReader()