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

some questions about the proposal #10

Open
JCZ404 opened this issue Dec 7, 2021 · 5 comments
Open

some questions about the proposal #10

JCZ404 opened this issue Dec 7, 2021 · 5 comments

Comments

@JCZ404
Copy link

JCZ404 commented Dec 7, 2021

Hi, Thank you for your great work, your code is very excellent! But may I ask you for some questions about the algorithm?
1,How did you generate the fixed num of the pre-computed box? In your paper, you said we first need to generate M =100 pre-computed box as the region proposals,but when I use Faster RCNN to generate the pre-computed box, it seems can't guarantee to get the fixed num of pre-computed box because of the NMS process. In the test mode Faster RCNN, there are two NMS processes, one for proposals generated by RPN, another for the boxes generated by ROI Head. In the first situation, after NMS, there are still much proposal, but in the second situation, after NMS for each class label, only some number of boxes survive. However, in bottom-up-attention, we use the bbox generated by ROI Head. Actually, when I use Faster RCNN weight file you provided and roi_head_nms=0.3 as you said, I can only get much less pre-computed boxes, like 56, 18..., sometimes even less than topN=10, which would cause the error when run your code. For this situation, I guess it because the well-trained Faster RCNN can already accurate the location of the object, which result in most of boxes are generated at the same position and removed by the ROI_Head_NMS. So, currently, I set the nms=0.7, and I just feel a little bit confused about this.
2,Which dataset you pre-train the Faster RCNN for generating the pre-computed box? In your code, it seems that you used the Faster RCNN pre-trained on COCO dataset to generate the pre-computed box, but it only covers 81 categories. In the Flickr30K Entities, there are lots of categories doesn't exist in COCO, so does this situation matter? Because I find that most of works use the Faster RCNN pre-trained on Visual Genome dataset which covers 1600 classes and some attribute labels.

@youngfly11
Copy link
Owner

youngfly11 commented Dec 7, 2021 via email

@JCZ404
Copy link
Author

JCZ404 commented Dec 7, 2021

Thanks for you reply, I got it! Now, I also set the ROI_Head_NMS=0.7 to get at least 10 precomputed box. But when I run your code, it seems the loss is very small, I guess it because the precomputed box is actually accurate, so the number of positive sample for box classification and the offset for regression is small. I'm not sure about this.
image

And what's more, it seems there are some problems with the relation label, because for each relation, there are topN*topN connections, this connection are assigned with -1(ignore),0(negtive),or 1(positive), but you did a normalization with all of this, and finally to calucate the soft label classification loss, which result in the negtive loss. But also, I'm not very sure about this.
image
image

@youngfly11
Copy link
Owner

youngfly11 commented Dec 7, 2021 via email

@JCZ404
Copy link
Author

JCZ404 commented Dec 15, 2021

Hi, I'm very sorry for bothering you again. I have already checked the generated proposal, I find that when calculating the classification loss and regression loss, for each phrase, there are only a few proposals has IoU>0.5 with the gt box, like 1,2, sometimes even no proposal have the IoU>0.5, I want to ask is that normal? Or the generated proposals are wrong, as you said, I set the ROI_Head nms=0.3, score_thresh=0.01 to generate at least 10 proposal for each image, could you provide your nms and score threshold? Thanks a lot!

@youngfly11
Copy link
Owner

I recommend you use https://github.com/MILVLG/bottom-up-attention.pytorch to extract features. nms=0.3 and score_thresh=0.1 is ok

@youngfly11 youngfly11 pinned this issue Jan 5, 2022
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