class_docstr: Custom InputProcessor for file based ExampleGen driver.
class_docstr_tok: ["Custom","InputProcessor","for","file","based","ExampleGen","driver","."]
docstr: Initialize FileBasedInputProcessor.
  
  Args:
    input_base_uri: The base path from which files will be searched.
    splits: An iterable collection of example_gen_pb2.Input.Split objects.
    range_config: An instance of range_config_pb2.RangeConfig, defines the
      rules for span resolving.
docstr_tok: ["Initialize","FileBasedInputProcessor",".","Args",":","input_base_uri",":","The","base","path","from","which","files","will","be","searched",".","splits",":","An","iterable","collection","of","example_gen_pb2.Input.Split","objects",".","range_config",":","An","instance","of","range_config_pb2.RangeConfig",",","defines","the","rules","for","span","resolving","."]
code: def __init__(
      self,
      input_base_uri: str,
      splits: Iterable[example_gen_pb2.Input.Split],
      range_config: Optional[range_config_pb2.RangeConfig] = None,
  ):
      """Initialize FileBasedInputProcessor.
  
      Args:
        input_base_uri: The base path from which files will be searched.
        splits: An iterable collection of example_gen_pb2.Input.Split objects.
        range_config: An instance of range_config_pb2.RangeConfig, defines the
          rules for span resolving.
      """
      super().__init__(splits=splits, range_config=range_config)
  
      self._is_match_span = None
      self._is_match_date = None
      self._is_match_version = None
      for split in splits:
          (
              is_match_span,
              is_match_date,
              is_match_version,
          ) = utils.verify_split_pattern_specs(split)
          if self._is_match_span is None:
              self._is_match_span = is_match_span
              self._is_match_date = is_match_date
              self._is_match_version = is_match_version
          elif (
              self._is_match_span != is_match_span
              or self._is_match_date != is_match_date
              or self._is_match_version != is_match_version
          ):
              raise ValueError(
                  "Spec setup should the same for all splits: %s."
                  % split.pattern
              )
  
      if (
          self._is_match_span or self._is_match_date
      ) and not range_config:
          range_config = range_config_pb2.RangeConfig(
              rolling_range=range_config_pb2.RollingRange(num_spans=1)
          )
      if (
          not self._is_match_span
          and not self._is_match_date
          and range_config
      ):
          raise ValueError(
              "Span or Date spec should be specified in split pattern if RangeConfig is specified."
          )
  
      self._input_base_uri = input_base_uri
      self._fingerprint = None
  
imports: import abc
  import copy
  from typing import Iterable, Optional, Tuple
  from tfx.components.example_gen import utils
  from tfx.proto import example_gen_pb2
  from tfx.proto import range_config_pb2
label_desc: Use image node_id 1 to create a new FileBasedInputProcessor object from inherited base classes: InputProcessor with example: obj = FileBasedInputProcessor(input_base_uri, splits, range_config)