代码如下:import torchvision
from PIL import Image
import torchvision.transforms as transforms
from matplotlib import pyplot as plt
from torchvision.models.feature_extraction impor[...]
对于Variable的态度,PyTorch官方明确说明:deprecated已经被废弃。下面是PyTorch官方说明:The Variable API has been deprecated: Variables are no longer necessary to use autograd with tensors. Autograd autom[...]