yijingru / ASSD-Pytorch

[CVIU 2019] ASSD learns to highlight useful regions on the feature maps while suppressing the irrelevant information, thereby providing reliable guidance for object detection.
39 stars 20 forks source link

How to use imgattmap #6

Open linchunmian opened 4 years ago

linchunmian commented 4 years ago

Hi, jingyi. Thanks for your code. But I want to know what is the parameter beta? And how can I use this function to see my attentive feature? I confuse a bit, and expect you can help me. Thanks!

yijingru commented 4 years ago

beta is defined in the attention class of assd_resnet101.py beta = F.softmax(s, dim=-1)

linchunmian commented 4 years ago

Thanks. If I want to use it on my detection code, where should I place it?

linchunmian commented 4 years ago

And I also have confused that for detection task, the output is not only classification score, as well as box regression and object confidence. In this case, I just place it after the softmax output? or say, it is used for classification score? Thanks for your immediate reply!

yijingru commented 4 years ago

beta = F.softmax(s, dim=-1) is for attention map normalization. If you are using the attention module in the detection, you can input beta to the imshowAtt to visualize the results. Another softmax for detection is for classification.