Download scripts/load_artifacts.py from zarifbinakhtar/custom-GNN-LLM-VLM: direct link, hf CLI and curl.
- Browser
- Download file 1.05 kB
-
https://huggingface.co/zarifbinakhtar/custom-GNN-LLM-VLM/resolve/main/scripts/load_artifacts.py
- Command line
-
hf download hf://zarifbinakhtar/custom-GNN-LLM-VLM/scripts/load_artifacts.py
-
curl -L -o load_artifacts.py https://huggingface.co/zarifbinakhtar/custom-GNN-LLM-VLM/resolve/main/scripts/load_artifacts.py
1.05 kB
| import argparse | |
| import os | |
| from huggingface_hub import hf_hub_download, snapshot_download | |
| def main(): | |
| parser = argparse.ArgumentParser(description="Download custom-GNN-LLM-VLM artifacts from Hugging Face Hub") | |
| parser.add_argument("--repo-id", type=str, default="zarifbinakhtar/custom-GNN-LLM-VLM", help="Hugging Face repo ID") | |
| parser.add_argument("--local-dir", type=str, default="hf_artifacts", help="Local destination folder") | |
| parser.add_argument("--file", type=str, default=None, help="Optional single file path inside repo (e.g., configs/pipeline.yaml)") | |
| args = parser.parse_args() | |
| os.makedirs(args.local_dir, exist_ok=True) | |
| if args.file: | |
| downloaded = hf_hub_download(repo_id=args.repo_id, filename=args.file, local_dir=args.local_dir) | |
| print(f"Downloaded '{args.file}' to: {downloaded}") | |
| else: | |
| snapshot_path = snapshot_download(repo_id=args.repo_id, local_dir=args.local_dir) | |
| print(f"Downloaded repository snapshot to: {snapshot_path}") | |
| if __name__ == "__main__": | |
| main() | |