Spaces:
Sleeping
Sleeping
Download validate.py from subbunanepalli/LOG_REG: direct link, hf CLI and curl.
- Browser
- Download file 361 Bytes
-
https://huggingface.co/spaces/subbunanepalli/LOG_REG/resolve/main/validate.py
- Command line
-
hf download hf://spaces/subbunanepalli/LOG_REG/validate.py
-
curl -L -o validate.py https://huggingface.co/spaces/subbunanepalli/LOG_REG/resolve/main/validate.py
361 Bytes
| import os | |
| from config import MODEL_PATH, TFIDF_PATH | |
| def validate_files(): | |
| model_exists = os.path.exists(MODEL_PATH) | |
| vectorizer_exists = os.path.exists(TFIDF_PATH) | |
| return { | |
| "model_found": model_exists, | |
| "vectorizer_found": vectorizer_exists, | |
| "status": "Ready" if model_exists and vectorizer_exists else "Missing files" | |
| } | |