Download code/scripts/check_environment.py from CollinMa/nextgpt-chapter6-report: direct link, hf CLI and curl.
- Browser
- Download file 434 Bytes
-
https://huggingface.co/spaces/CollinMa/nextgpt-chapter6-report/resolve/main/code/scripts/check_environment.py
- Command line
-
hf download hf://spaces/CollinMa/nextgpt-chapter6-report/code/scripts/check_environment.py
-
curl -L -o check_environment.py https://huggingface.co/spaces/CollinMa/nextgpt-chapter6-report/resolve/main/code/scripts/check_environment.py
434 Bytes
| """Preflight without downloading weights or importing the large model.""" | |
| import json | |
| import platform | |
| import sys | |
| from pathlib import Path | |
| sys.path.insert(0, str(Path(__file__).resolve().parents[1])) | |
| from engine import runtime_status | |
| if __name__ == "__main__": | |
| result = runtime_status() | |
| result.update(python=platform.python_version(), platform=platform.platform()) | |
| print(json.dumps(result, ensure_ascii=False, indent=2)) | |