{"record":{"id":"406d161a6cbcdcdb","repo":"vllm-project/vllm","slug":"fp8-scale-file-not-found-scale-path","errorCode":null,"errorMessage":"FP8 scale file not found: {scale_path}","messagePattern":"FP8 scale file not found: (.+?)","errorType":"exception","errorClass":"FileNotFoundError","httpStatus":null,"severity":"error","filePath":"vllm/config/multimodal.py","lineNumber":341,"sourceCode":"            raise ValueError(\n                \"'mm_encoder_fp8_scale_path' and \"\n                \"'mm_encoder_fp8_scale_save_path' require \"\n                \"'mm_encoder_attn_dtype' to be 'fp8'.\"\n            )\n        if (\n            self.mm_encoder_fp8_scale_path is not None\n            and self.mm_encoder_fp8_scale_save_path is not None\n        ):\n            raise ValueError(\n                \"'mm_encoder_fp8_scale_save_path' cannot be used with \"\n                \"'mm_encoder_fp8_scale_path' (saving requires dynamic scaling).\"\n            )\n\n        # Validate file paths exist.\n        if self.mm_encoder_fp8_scale_path is not None:\n            scale_path = Path(self.mm_encoder_fp8_scale_path)\n            if not scale_path.is_file():\n                raise FileNotFoundError(f\"FP8 scale file not found: {scale_path}\")\n        if self.mm_encoder_fp8_scale_save_path is not None:\n            save_parent = Path(self.mm_encoder_fp8_scale_save_path).parent\n            if not save_parent.is_dir():\n                raise FileNotFoundError(\n                    f\"Parent directory for FP8 scale save path not found: {save_parent}\"\n                )\n        return self\n\n    @staticmethod\n    def fold_mm_processor_device(\n        mm_processor_kwargs: dict[str, Any] | None,\n        mm_processor_device: MMProcessorDevice | None,\n    ) -> dict[str, Any] | None:\n        \"\"\"Fold the `mm_processor_device` convenience flag into the kwargs.\n\n        The flag keeps no state of its own: `mm_processor_kwargs[\"device\"]` is\n        the only representation of where the processor runs, so an explicit\n        `device` there always wins and `\"auto\"` stays unresolved for","sourceCodeStart":323,"sourceCodeEnd":359,"githubUrl":"https://github.com/vllm-project/vllm/blob/c794754062d49a8fdb63ab3c5215b488b865030c/vllm/config/multimodal.py#L323-L359","documentation":"After the FP8 option-combination checks, MultiModalConfig verifies the file existence of mm_encoder_fp8_scale_path with Path.is_file(). If the path does not point to an existing regular file, a FileNotFoundError is raised at config-validation time so a typo'd scale path never reaches the engine.","triggerScenarios":"Setting --mm-encoder-fp8-scale-path to a missing file: wrong relative path (resolved against the server process cwd), file not yet generated by the calibration run, path only present on a different node of a multi-node deployment, or a directory instead of a file.","commonSituations":"Running the serve command before the calibrate command finishes; running in a container where the scale file was not mounted; typos or ~ that is not shell-expanded inside quotes.","solutions":["Check the file exists at the exact path the vLLM process sees: ls -l <path> from the same container/host and cwd.","Use an absolute path for the scale file, and expand ~ or env vars in the shell before passing it.","If the file was never produced, first run the calibration pass with --mm-encoder-fp8-scale-save-path to create it."],"exampleFix":"# before (file at /data/out.pt, but cwd differs)\nvllm serve model --mm-encoder-attn-dtype fp8 --mm-encoder-fp8-scale-path scales.pt\n\n# after\nvllm serve model --mm-encoder-attn-dtype fp8 --mm-encoder-fp8-scale-path /data/out.pt","handlingStrategy":"validation","validationCode":"from pathlib import Path\n\ndef check_scale_file(p: str | None) -> None:\n    if p is not None and not Path(p).is_file():\n        raise SystemExit(f\"FP8 scale file missing: {p}; run calibration first or fix the path\")","typeGuard":null,"tryCatchPattern":"try:\n    MultiModalConfig(mm_encoder_attn_dtype=\"fp8\", mm_encoder_fp8_scale_path=p)\nexcept FileNotFoundError as e:\n    raise SystemExit(f\"Config rejected: {e}\") from None","preventionTips":["Use absolute paths for scale files; container-mount them into the serving image.","Make the serve step depend on the calibration artifact existing (make serve: calibrate)."],"tags":["vllm","config","multimodal","fp8","file-not-found","paths"],"backgroundTag":null,"analyzedSha":"c794754062d49a8fdb63ab3c5215b488b865030c","analyzedAt":"2026-08-14T21:17:39.825Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}