Bug in BAM: only support input height = width
HeMuling opened this issue · 0 comments
HeMuling commented
in BAM ChannelGate
:
attention-module/MODELS/bam.py
Line 24 in 459efad
this line assumes the input H=W
to fix this, on can change the code into:
avg_pool = F.avg_pool2d( in_tensor, (in_tensor.size(2), in_tensor.size(3)), stride=in_tensor.size(2) )