Huggingface utilities for Ultralytics/YOLOv8
GPL-3.0 License
Bot releases are hidden (Show)
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.9...0.0.10
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.8...0.0.9
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.7...0.0.8
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.6...0.0.7
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.5...0.0.6
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.4...0.0.5
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.3...0.0.4
Published by fcakyon almost 2 years ago
Extra features for ultralytics/ultralytics.
pip install ultralyticsplus
ultralyticsplus --exp_dir runs/detect/train --hf_model_id HF_USERNAME/MODELNAME
from ultralyticsplus import YOLO, render_predictions
# load model
model = YOLO('HF_USERNAME/MODELNAME')
# set model parameters
model.overrides['conf'] = 0.25 # NMS confidence threshold
model.overrides['iou'] = 0.45 # NMS IoU threshold
model.overrides['agnostic_nms'] = False # NMS class-agnostic
model.overrides['max_det'] = 1000 # maximum number of detections per image
# set image
img = 'https://github.com/ultralytics/yolov5/raw/master/data/images/zidane.jpg'
# perform inference
for result in model.predict(img, imgsz=640, return_outputs=True):
print(result) # [x1, y1, x2, y2, conf, class]
render = render_predictions(model, img=img, det=result["det"])
render.show()
Full Changelog: https://github.com/fcakyon/ultralyticsplus/compare/0.0.2...0.0.3
Published by fcakyon almost 2 years ago
Full Changelog: https://github.com/fcakyon/yolov8tohuggingface/compare/0.0.1...0.0.2
Published by fcakyon almost 2 years ago
HuggingFace utilities for Ultralytics/YOLOv8
pip install yolov8tohf
yolov8tohf --exp_dir runs/detect/train --hf_model_id HF_USERNAME/MODELNAME
from yolov8tohf import YOLO
# load model
model = YOLO('HF_USERNAME/MODELNAME')
# set model parameters
model.overrides['conf'] = 0.25 # NMS confidence threshold
model.overrides['iou'] = 0.45 # NMS IoU threshold
model.overrides['agnostic_nms'] = False # NMS class-agnostic
model.overrides['max_det'] = 1000 # maximum number of detections per image
# set image
img = 'https://github.com/ultralytics/yolov5/raw/master/data/images/zidane.jpg'
# perform inference
model.predict(img, imgsz=640)
Full Changelog: https://github.com/fcakyon/yolov8tohuggingface/commits/0.0.1