You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If this is a 🐛 Bug Report, please provide a minimum reproducible example to help us debug it. If you're looking to modify inference display properties like annotation text size or color, this may require some adjustments in the code outputs, and further detail on your implementation will help us guide you more effectively.
If this is a custom training ❓ Question, please provide as much information as possible, such as:
If this badge is green, all YOLOv5 GitHub Actions Continuous Integration (CI) tests are currently passing. CI tests verify correct operation of YOLOv5 training, validation, inference, export and benchmarks on macOS, Windows, and Ubuntu every 24 hours and on every commit.
This is an automated response 🤖. An Ultralytics engineer will review your query and provide additional support as soon as possible 🙂
@MakMoinee to modify the annotation text size and color, you can use the .plot() method from the results object and customize parameters like font_size and font. For example:
results=model(image)
forresultinresults:
annotated_image=result.plot(font_size=20, font='Arial.ttf') # Adjust font size and type
If you're working with bounding box annotations, the Annotator class also allows direct control over text and box attributes. For additional details, refer to the results.plot documentation or the annotator utilities.
Search before asking
Question
Hi, I'm having trouble with the annotation. please provide me fix or code to make this code below work:. how did you guys work it out?
model = torch.hub.load('ultralytics/yolov5', 'custom', path='./result.pt', verbose=False)
results = model(image)
This is the only implementation it works so if you could find workaround please help me
Additional
No response
The text was updated successfully, but these errors were encountered: