ModuleNotFoundError: No module named 'pycocotools' solution

Overview:

  • Due to the lack of errors caused by the pycocotools package, and the pycocotools package requires cython and C compiler, you need to install Cython before installing cython.

Solution:

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

     

Guess you like

Origin www.cnblogs.com/dyc99/p/12751535.html