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

Wrong lable in the infer result #7

Closed
punknownq opened this issue Aug 1, 2020 · 2 comments
Closed

Wrong lable in the infer result #7

punknownq opened this issue Aug 1, 2020 · 2 comments

Comments

@punknownq
Copy link

punknownq commented Aug 1, 2020

Hi.Thank you for your work. I have got the output of the RRPN which is right. However, I got wrong lables after ran inference on the validation set images. Can you help me? For example, the person in the image is labeled "car" and the car in the image is labeled "person".

@mrnabati
Copy link
Owner

mrnabati commented Aug 5, 2020

This is because of a mismatch between the category IDs in COCO and nuCOCO.
A quick fix is to modify the "get_coco_dataset()" function in "detectron/datasets/dummy_datasets.py" and change "classes" from

classes = [ '__background__', 'person', 'bicycle', 'car', 'motorcycle', 'airplane', 'bus', 'train', 'truck', 'boat', 'traffic light', 'fire hydrant', 'stop sign', 'parking meter', 'bench', 'bird', 'cat', 'dog', 'horse', 'sheep', 'cow', 'elephant', 'bear', 'zebra', 'giraffe', 'backpack', 'umbrella', 'handbag', 'tie', 'suitcase', 'frisbee', 'skis', 'snowboard', 'sports ball', 'kite', 'baseball bat', 'baseball glove', 'skateboard', 'surfboard', 'tennis racket', 'bottle', 'wine glass', 'cup', 'fork', 'knife', 'spoon', 'bowl', 'banana', 'apple', 'sandwich', 'orange', 'broccoli', 'carrot', 'hot dog', 'pizza', 'donut', 'cake', 'chair', 'couch', 'potted plant', 'bed', 'dining table', 'toilet', 'tv', 'laptop', 'mouse', 'remote', 'keyboard', 'cell phone', 'microwave', 'oven', 'toaster', 'sink', 'refrigerator', 'book', 'clock', 'vase', 'scissors', 'teddy bear', 'hair drier', 'toothbrush' ]

to

classes = [ '__background__', 'car', 'truck', 'person', 'motorcycle', '_', 'bicycle', '_', 'bus' ]

@mrnabati mrnabati closed this as completed Aug 6, 2020
@punknownq
Copy link
Author

Thank you for your reply!

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

No branches or pull requests

2 participants