luuuyi / cbam.pytorch Goto Github PK
View Code? Open in Web Editor NEWNon-official implement of Paper:CBAM: Convolutional Block Attention Module
Non-official implement of Paper:CBAM: Convolutional Block Attention Module
博主大大 能给出运行的步骤吗 刚接触python和pytorch ,真的是一脸懵
For the file resnet_cbam.py, I think line31 and line 33 are not consistent with the paper. fc1 and fc2 should be nn.Linear because the paper said:
Both descriptors are then forwarded to a shared network
to produce our channel attention map Mc 2 RC�1�1. The shared network is
composed of multi-layer perceptron (MLP) with one hidden layer. To reduce
parameter overhead, the hidden activation size is set to RC=r�1�1, where r is
the reduction ratio.
May I know why you use conv instead of Linear ?
Hello, may you provide a pre-trained model of cbam, thank you.
After applying Channel Attention Module, maybe it would be better to apply a convolution layer in order to modify the channels to the original value (usually 3 channels), instead of applying Spatial Attention Module instantly. Or Spatial Attention Module can't make sense.
Thank you very much! In the paper, this block meant to be the same as SE block (except for the MaxPool addition). Is there any reason why you used nn.Conv2d rather than nn.Linear in the original SE block? I am working with time series, would you recommend me to use Conv1d or keep using Linear? Finally, is there any reason why bias = False? I obtained better results with bias = True with SE block in my case.
Lastly, have you done any comparison with Gather & Excite? https://github.com/hujie-frank/GENet
我将模块加在resnet网络上,训练时出现max_out的print结果为两个tensor,被认定为是list,无法运行,请问大家有遇到此类问题吗
datasets?
hi I ma getting this error while testing
Traceback (most recent call last):
File "test.py", line 213, in
test_and_generate_result_round2('2','resnet50',416, True)
File "test.py", line 133, in test_and_generate_result_round2
my_model = resnet50.MyResNet50(model_ft)
NameError: name 'resnet50' is not defined
I find your code can't reach the accuary
RT.
I know you said that you do not have time but this is also interesting: https://arxiv.org/abs/1811.12006
Thanks for your contribution! I hope you can share a pretrained model link for resnet50!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.