pytorch version ‘1.1.0’
Here is simple code that make error
import torch
import torch.nn.functional as F
img = torch.rand(1,128,128)
img2 = F.interpolate(img, scale_factor=(1,0.5,0.5), mode="bicubic")
and error
Traceback (most recent call last):
File "/home/tt/project/crowd_counting_framework/bug/interpolate_bug.py", line 8, in <module>
img2 = F.interpolate(img, scale_factor=(1,0.5,0.5), mode="bicubic")
File "/home/tt/anaconda3/envs/pytorch_gpu/lib/python3.7/site-packages/torch/nn/functional.py", line 2577, in interpolate
" (got {})".format(input.dim(), mode))
NotImplementedError: Input Error: Only 3D, 4D and 5D input Tensors supported (got 3D) for the modes: nearest | linear | bilinear | bicubic | trilinear (got bicubic)
The error is conflict by it self.
It said “Only 3D, 4D and 5D input Tensors supported”, but confirm got 3D.
also, " nearest | linear | bilinear | bicubic | trilinear" => but got bicubic
It should OK.