-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Finalize keypoint detection #174
Conversation
@@ -35,6 +35,7 @@ | |||
"object-detection": "yolov5v2s", | |||
"instance-segmentation": "yolact", | |||
"classification": "vit", | |||
"keypoint-detection": "yolov8n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
most changes are keypoints-detection
-> keypoint-detection
, but this was a necessary addition to make sure model manager accepts type.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
num_classes = get_num_classes_from_model_prediction_shape( | ||
len_prediction=output_shape[2], keypoints_shape=keypoints_shape | ||
) | ||
try: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if num_classes != self.num_classes:
raise ValueError()
assert keypoints_count == 17 | ||
|
||
|
||
def test_superset_keypoints_count_with_two_classes(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion:
Return type: -> None:
given-when-then
# given
keypoints_metadata = ...
# when
keypoints_count = superset_keypoints_count(keypoints_metadata)
# then
assert keypoints_count == 13, "Keypoints of object 1 form a superset of all classes"
Would be also good to cover the behaviour when classes do not overlap
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added, going to merge after build succeeds as changes were straightforward.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, maybe I need another review? merging is blocked
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:+1
Description
Updates keypoint detection to match with what is being sent from dataset/weights routes. Also adds validation for num_classes.
Type of change
Please delete options that are not relevant.
How has this change been tested, please provide a testcase or example of how you tested the change?
Tested running local inference server for one keypoints detection model and one OD model.
Any specific deployment considerations
None.
Docs