-
Notifications
You must be signed in to change notification settings - Fork 33
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
Base training accuracy(phase 1) #25
Comments
Hi @amajee11us This is due to the number of training classes is only 15 for the base class training stage, while the To work around this issue, you can simply set the num_cls to 15 for testing the accuracy of phase 1. |
Thanks, this suggestion works, although I had to update "num_cls" in multiple places within the test script. Line 347 in 9c8951d
Line 350 in 9c8951d
But, when I inspect the base trained model I see that the final classification weights have dimensions [21, 4096] which should have been the case only during phase 2. We can prove this by setting the num_cls value to 15 here . RuntimeError: Error(s) in loading state_dict for resnet: I suspect this to be an issue during model formation in phase 1. |
Hi, I am also wondering why the "RCNN_cls_score.weight" of base trained model has the dimensions [21, 4096]? There are actually 16 classes in base class training stage (15 base classes + 1 background class), so why not [16, 4096]? Please correct me if I have some misunderstanding. |
@pengyinxw the model weights of the "RCNN_cls_score" (box classifier) has the dimensions [16, 2048] after the base training. I have confirmed that through my experiments. |
@amajee11us thanks for your reply! But I am still confused about the "box classifier" dimensions after the base training. Since the output dimensions of "RCNN_cls _score" are imdb.num_classes, while the imdb.num_classes are set to be 21 here even in base training phase. In addition, instead of using the "test.py" to load model, I just load the base trained model with the simple script attached However, I can only load the base trained model successfully, when I set the num_cls=21. If possible, could you please tell me how did you confirm the dimensions=16? Thank you in advance |
@pengyinxw Hi! Have you reproduced this code? If you reproduce this code, can you tell me how you configured the environment? Looking forward to your reply! |
I was trying to generate the base class accuracy numbers post phase 1 training on VOC dataset.
Unfortunately, I get this error. Is there a way to get the accuracy numbers from phase 1 training.
lib/model/faster_rcnn/faster_rcnn.py:210: UserWarning: Implicit dimension choice for softmax has been deprecated. Change the call to include dim=X as an argument.
cls_prob = F.softmax(cls_score)
Traceback (most recent call last):
File "test.py", line 344, in
inds = torch.nonzero(scores[:, j] > thresh).view(-1)
IndexError: index 16 is out of bounds for dimension 1 with size 16
The text was updated successfully, but these errors were encountered: