da6a2fa
1
2
3
4
5
6
7
8
9
from huggingface_hub import hf_hub_download def load_model(): model_path = hf_hub_download( repo_id="your-username/your-repo", filename="best.pt", revision="main" ) return YOLO(model_path)