ModuleNotFoundError: No module named 'pycocotools'解决办法

概要:

  • 由于缺少pycocotools包引发的错误,而pycocotools包需要cython和C编译器,所以在安装cython之前需要先安装Cython。

解决办法:

  • 安装cython
    pip install -U cython
  • Linux安装pycocotools
    pip install "git+https://github.com/philferriere/cocoapi.git#egg=pycocotools&subdirectory=PythonAPI"
  • Windows安装pycocotools
    pip install "git+https://github.com/philferriere/cocoapi.git#egg=pycocotools^&subdirectory=PythonAPI"

     

文章来自:https://www.cnblogs.com/dyc99/p/12751535.html
© 2021 jiaocheng.bubufx.com  联系我们
ICP备案:鲁ICP备09046678号-3