Skip to content

YOLO backend Max number of detection 300. Can we config via docker arg? #837

@robert-stevenson-1

Description

@robert-stevenson-1

I wanted to use my own YOLO models for auto-labelling my images, but they only label up to 300 instances.
After some digging, I found this is due to a limit in Ultralytic's .predict() function.

I solved my case by just changing results = self.model.predict(path) to results = self.model.predict(path, max_det=3000) in control_models/rectangle_labels.py under the predict_regions function.

Can it be configured in the Docker Compose file to make it easier to change?
I might end up doing it at some point myself, but it may be a while before I get around to these changes, so I thought someone else might be able to get to them before me.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions