window10 pytorch编译DCNv2 遇到的错误
错误1:
UserWarning: Attempted to use ninja as the BuildExtension backend but we could not find ninja.. Falling back to using the slow distutils backend.
解决方案:
pip install ninja
错误2:
error: identifier "THCState_getCurrentStream" is undefined
解决方案
1.下载最新的DCNv2 地址:https://github.com/jinfagang/DCNv2_latest
2.替换原来的DCNv2文件
3.环境使用目前支持的pytorch ≤ 1.8 (开始使用的pytorch 版本=1.10)
编译成功
copying build\lib.win-amd64-3.7\_ext.cp37-win_amd64.pyd ->
Creating j:\worksoft\envs\yolact\lib\site-packages\DCNv2.egg-link (link to .)
Adding DCNv2 0.1 to easy-install.pth file