Skip to main content

Python function

try_to_load_from_cache

try_to_load_from_cache()

max.pipelines.lib.try_to_load_from_cache(repo_id, filename, revision)

source

Wrapper around huggingface_hub.try_to_load_from_cache; validates repo exists.

validate_hf_repo_access is called first to ensure the repo exists.

Parameters:

  • repo_id (str)
  • filename (str)
  • revision (str)

Return type:

str | Any | None