Open ChenFan666 opened 2 years ago
Based on the error message, casting the type of elements in id4 to be torch.int64 may solve the problem.
Like this ... id4 = id4.type(torch.int64)
Thank you for your explanation, but after I made the modification, the following problems occurred This is their shape: I see this tensor have the same channel in your code, and i make my tensor's channel to same, but still report error
This my fault, i not use the maxpool,just want use the unmaxpool,thank you very much!
That's fine. The max_unpool is used together with the max_pooling operation. You may see https://pytorch.org/docs/stable/generated/torch.nn.MaxUnpool2d.html. And, the indices should be positive integers.
When i use another backbone , i meet this problem: I cheak the conv5_3.shape and id4.shape , they meet the requirements of the "max_unpool2d" function Could you help me?please!