Tramac / awesome-semantic-segmentation-pytorch

Semantic Segmentation on PyTorch (include FCN, PSPNet, Deeplabv3, Deeplabv3+, DANet, DenseASPP, BiSeNet, EncNet, DUNet, ICNet, ENet, OCNet, CCNet, PSANet, CGNet, ESPNet, LEDNet, DFANet)
Apache License 2.0
2.85k stars 582 forks source link

unmatched matrix size in psanet #71

Open devolfnn opened 5 years ago

devolfnn commented 5 years ago

In _AttentionGeneration, the two tensors attention and reduce_x are multiplied using torch.bmm, this operation failed because of unmatched matrix size. Furthermore, the code indicates an output size of (batch_size, reduced_channels, h, w) which cannot be generated by the operation given the two tensors' size.

Mhaiyang commented 4 years ago

I have the same problem.

Mhaiyang commented 4 years ago

I solved this problem! The input size of image should be 480x480.