Views
No views yet
pip install ultralytics huggingface_hub1from ultralytics import YOLO
2from huggingface_hub import hf_hub_download
3
4# Download weights from Hugging Face
5model_path = hf_hub_download(repo_id="Tuzelkhan/drone-yolov8", filename="best.pt")
6
7# Load model
8model = YOLO(model_path)
9
10# Predict on an image
11results = model.predict(source="path/to/drone_image.jpg", conf=0.25, save=True)
12
13# Show results
14for result in results:
15 result.show()best.pt)