-
Notifications
You must be signed in to change notification settings - Fork 17
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
Predict wrong class #1
Comments
Hi @nicejava, could you please elaborate on what you mean by it predicts wrong class by sharing the results you are getting? |
Thank for reply ok i try train 5 class CLASS_NAMES = ['A', 'B', 'C', 'D', 'E']
And I have image for testing 5 class too like this 01.jpg = class A So after trained i try testing each image but result display first always is 'A' such as i try testing 03.jpg which should have received the answer C, but instead received the answer A r = model.detect([image], verbose=0) |
You would also need to register these class names and assign Please follow this tutorial as it gives you a proper walkthrough on how to train mask-rcnn using your own dataset. |
It's NOT incorrect class labels that your model is returning. In fact, your model is always returning However, in your case, there are 5 different classes. You'd also need to return particular class indices when returning the masks. You can follow the solution suggested in this issue to fix your problem and retrain the network again. Particularly, you would need to pass the list of your Additionally, you can follow the notebook that illustrates how to train Mask R-CNN on the Shapes dataset which happens to be a multiclass dataset similar to yours. I hope this answers your question. |
Your code very good but predict class wrong
It always result predicts the first class.
Example we class CLASS_NAMES = ['BG', 'A', 'B', 'C', 'D', 'E', 'F']
your code result predict is class A always Whether using images of other classes
The text was updated successfully, but these errors were encountered: