Skip to content
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

How do I deal with situations where there is no object in the detected results? #3710

Open
lartpang opened this issue Sep 8, 2020 · 2 comments
Assignees
Labels
Doc question Further information is requested

Comments

@lartpang
Copy link

lartpang commented Sep 8, 2020

num_classes = len(det_results[0]) # positive class num

If there is no target in the detected result, an error will be reported here.


Can you give me some advice? Note that there is no object in the ground truth.

@lartpang lartpang changed the title How do I deal with situations where there is no target in the detected results? How do I deal with situations where there is no object in the detected results? Sep 8, 2020
@ZwwWayne
Copy link
Collaborator

ZwwWayne commented Sep 8, 2020

  1. det_results means the detection results produced by models. If the results is produced by mmdetection models, det_results[0] will be a list of list, e.g., something like [[box for class 0],[box for class 1],[box for class 2],...,]. No matter whether there are boxes in the results, it can tell the number of classes.
  2. Therefore, usually, you do not need do anything. Since you got an error here, something must go wrong. But we cannot do any help because the information is limited. Please use either Error Template or Reimplementation issues to report your error.

@ZwwWayne ZwwWayne added the question Further information is requested label Sep 8, 2020
@lartpang
Copy link
Author

lartpang commented Sep 8, 2020

@ZwwWayne Thanks for your reply.

In fact, I am using comments in pascal voc format.
Maybe there is something wrong with the way I generated the annotation file.
Can you give me some suggestions on how to construct a reasonable xml file for the data without a object?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Doc question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants