torchvision 썸네일형 리스트형 ImportError: cannot import name '_NewEmptyTensorOp' from 'torchvision.ops.misc' 해당 에러는 torchvision의 version 확인을 제대로 못해서 발생하는 문제이다. import torch import torch.nn as nn import torch.distributed as dist from torch import Tensor # needed due to empty tensor bug in pytorch and torchvision 0.5 import torchvision if float(torchvision.__version__[:3]) < 0.5: import math from torchvision.ops.misc import _NewEmptyTensorOp def _check_size_scale_factor(dim, size, scale_factor): # type: .. 더보기 이전 1 다음