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
{{ message }}
This repository has been archived by the owner on Nov 21, 2023. It is now read-only.
The bug is located in the method "predict" of the class SAMCLIP in sam_clip.py
When building the list "nms_data", detection tuples are only appended to it if their corresponding bbox is found with a probability above the confidence threshold. If no such case is found, the list will be empty and therefore the method will send an empty array to the function sv.non_max_suppression (line 162), which then tries to unpack the array into rows and columns, raising a ValueError: not enough values to unpack (expected 2, got 1) exception.
It will save users a headache if you add an assertion to verify that nms_data is not empty before running non_max_suppression.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The bug is located in the method "predict" of the class SAMCLIP in sam_clip.py
When building the list "nms_data", detection tuples are only appended to it if their corresponding bbox is found with a probability above the confidence threshold. If no such case is found, the list will be empty and therefore the method will send an empty array to the function sv.non_max_suppression (line 162), which then tries to unpack the array into rows and columns, raising a ValueError: not enough values to unpack (expected 2, got 1) exception.
It will save users a headache if you add an assertion to verify that nms_data is not empty before running non_max_suppression.
The text was updated successfully, but these errors were encountered: