tensorflow/models · error · ConfigError

Config file does not exist

Error message

Config file does not exist: {config_path}

What it means

Raised in load_config when the given config_path does not exist as a file.

Solutions

  1. Check the path for typos and confirm the file exists (ls the directory).
  2. Run from the intended working directory or pass an absolute path.
  3. Create the config by copying the provided template if it was never made.
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at official/projects/waste_identification_ml/data_generation/auto_labeler_pipeline/config_loader.py:655 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of tensorflow/models@e006f5f0d5 (2026-08-24). Data as JSON: /api/errors/a80d228a2128deaf. Report an issue: GitHub.

Appendix: source

Thrown at official/projects/waste_identification_ml/data_generation/auto_labeler_pipeline/config_loader.py:655

  """Reads, validates, and returns the pipeline configuration.

  All validation happens here so that every stage fails at the same gate,
  before any dataset walk or GPU work. On success the returned object is
  fully typed and internally consistent.

  Args:
      config_path: Path to the YAML configuration file.

  Returns:
      A validated :class:`PipelineConfig`.

  Raises:
      ConfigError: If the file is missing, is not valid YAML, is missing
          required fields, contains out-of-range values, or names a
          ``prompt_to_detect`` that has no block under ``prompts``.
  """
  if not os.path.isfile(config_path):
    raise ConfigError(f"Config file does not exist: {config_path}")

  try:
    with open(config_path, "r", encoding="utf-8") as config_file:
      raw_config = yaml.safe_load(config_file)
  except OSError as error:
    raise ConfigError(f"Cannot read config file: {error}") from error
  except yaml.YAMLError as error:
    raise ConfigError(f"Config file is not valid YAML: {error}") from error

  if not isinstance(raw_config, dict):
    raise ConfigError(
        "Config file must contain a top-level mapping of settings."
    )

  _require_keys(raw_config, _REQUIRED_TOP_LEVEL_KEYS, "config.yaml")

  root_dir = _require_non_empty_string(raw_config["root_dir"], "root_dir")
  sam3_checkpoint_path = _require_non_empty_string(

View on GitHub (pinned to e006f5f0d5)