tengshaofeng / ResidualAttentionNetwork-pytorch

a pytorch code about Residual Attention Network. This code is based on two projects from
667 stars 165 forks source link

model = ResidualAttentionModel() error with python3 #27

Open carol007 opened 4 years ago

carol007 commented 4 years ago

TypeError: new() received an invalid combination of arguments - got (float, int, int, int), but expected one of:

victorruelle commented 4 years ago

You need to convert the input and output filters parameters of the Conv2d layers to int. If you look at the current arguments, they are float ( eg : 2.0 instead of 2) which is not accepted by torch.