Skip to content

Conversation

@RyanDoesMath
Copy link
Member

This pull request makes a few changes.

  1. Onnx models are now the default for running the program. Ultralytics will become a dev dependency that will not be packaged into the final product.
  2. ObjectDetectionModel is now a protocol instead of an abstractbaseclass.

This will (hopefully) make our deployments much smaller.

RyanDoesMath and others added 30 commits February 28, 2025 17:43
Didn't do much because I am switching computers after this commit.
This function is impenetrable... Need to refactor soon.
The code is still slow compared to what it should be (runs in 2 seconds, but the actual model runs in about 0.4 seconds). This is due to postprocessing being slow in python. One last thing to try is ultralytics yolov11, but loaded from an onnx model.
RyanDoesMath and others added 11 commits March 6, 2025 13:12
Also, filtered out all detections whose keypoint is not in the bounding box. This I learned is actually a feature of these pose models, not a bug.
This parameter lets the user determine if they want resizing or letterboxing.
ObjectDetectionModel was acting a bit too much like a parent class, so its two constructor methods were removed and the class was changed to a protocol which enforces that an implementer's object can be called to produce a list of Detection objects.
This is in preparation for the switch to numpy arrays.
These existed to satisfy the interface, but weren't implemented.
…-detection-model-to-protocol

Switch ObjectDetectionModel to protocol from an abstractbaseclass
Errors persist with digitization.
@RyanDoesMath RyanDoesMath self-assigned this Mar 7, 2025
@RyanDoesMath RyanDoesMath merged commit c925b07 into main Mar 7, 2025
@RyanDoesMath RyanDoesMath deleted the optimize-extraction branch March 7, 2025 11:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refactor ObjectDetectionModel into a Protocol Add an ObjectDetection subclass for ONNX models.

2 participants