pip install torch==1.7.0+cu110 torchvision==0.8.1+cu110-f https://download.pytorch.org/whl/torch_stable.html 再重新编译。 参考:DCNv2+pytorch1.7及以上版本编译报错解决方法