microsoft / aerial_wildlife_detection

Tools for detecting wildlife in aerial images using active learning
MIT License
224 stars 58 forks source link

MacOS: ERROR: Could not build wheels for imagecodecs #64

Open simbamangu opened 7 months ago

simbamangu commented 7 months ago

Install of v3 on Macos 14.3 fails:

  Stored in directory: /Users/simbamangu/Library/Caches/pip/wheels/5b/eb/43/7295e71293b218ddfd627f935229bf54af9018add7fbb5aac6
  Building wheel for imagecodecs (setup.py): started
  Building wheel for imagecodecs (setup.py): finished with status 'error'
  error: subprocess-exited-with-error

  × python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> [91 lines of output]
      /opt/homebrew/lib/python3.8/site-packages/setuptools/__init__.py:80: _DeprecatedInstaller: setuptools.installer and fetch_build_eggs are deprecated.
      !!

              ********************************************************************************
              Requirements should be satisfied by a PEP 517 installer.
              If you are using pip, you can try `pip install --use-pep517`.
              ********************************************************************************

      !!
        dist.fetch_build_eggs(dist.setup_requires)
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.macosx-14-arm64-cpython-38
      creating build/lib.macosx-14-arm64-cpython-38/imagecodecs
      copying imagecodecs/numcodecs.py -> build/lib.macosx-14-arm64-cpython-38/imagecodecs
      copying imagecodecs/__init__.py -> build/lib.macosx-14-arm64-cpython-38/imagecodecs
      copying imagecodecs/_imagecodecs.py -> build/lib.macosx-14-arm64-cpython-38/imagecodecs
      copying imagecodecs/imagecodecs.py -> build/lib.macosx-14-arm64-cpython-38/imagecodecs
      copying imagecodecs/__main__.py -> build/lib.macosx-14-arm64-cpython-38/imagecodecs
      copying imagecodecs/__init__.pyi -> build/lib.macosx-14-arm64-cpython-38/imagecodecs
      creating build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-zfp -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-fastlz -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-postgresql -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libjpeg -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-lzfse -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-liblzma -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libmng -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-lzham -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-jpg_0xc3 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-bzip2 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-blosc2 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libtiff -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-svt-av1 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-zlib -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-qoi -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-openjpeg -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libjpeg-turbo -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libaivf -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-aom -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-snappy -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-lerc -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-lz4 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-brunsli -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-dav1d -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-giflib -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-highway -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-rav1e -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libdeflate -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-zopfli -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-cfitsio -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-zstd -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libjxl -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-bitshuffle -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-liblj92 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-charls -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-brotli -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-jetraw -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libwebp -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libaec -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/PATENTS-rav1e -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-zlib-ng -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libpng -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-libspng -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-jpeg -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-lcms2 -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-blosc -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-lzf -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-jxrlib -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      copying imagecodecs/licenses/LICENSE-mozjpeg -> build/lib.macosx-14-arm64-cpython-38/imagecodecs/licenses
      running build_ext
      Compiling imagecodecs/_aec.pyx because it changed.
      [1/1] Cythonizing imagecodecs/_aec.pyx
      building 'imagecodecs._aec' extension
      creating build/temp.macosx-14-arm64-cpython-38
      creating build/temp.macosx-14-arm64-cpython-38/imagecodecs
      clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk -I/opt/homebrew/opt/openssl/include -Iimagecodecs -I/opt/homebrew/opt/python@3.8/Frameworks/Python.framework/Versions/3.8/include/python3.8 -I/opt/homebrew/lib/python3.8/site-packages/numpy/core/include -c imagecodecs/_aec.c -o build/temp.macosx-14-arm64-cpython-38/imagecodecs/_aec.o
      In file included from imagecodecs/_aec.c:1215:
      In file included from /opt/homebrew/lib/python3.8/site-packages/numpy/core/include/numpy/arrayobject.h:5:
      In file included from /opt/homebrew/lib/python3.8/site-packages/numpy/core/include/numpy/ndarrayobject.h:12:
      In file included from /opt/homebrew/lib/python3.8/site-packages/numpy/core/include/numpy/ndarraytypes.h:1940:
      /opt/homebrew/lib/python3.8/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: "Using deprecated NumPy API, disable it with "          "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
      #warning "Using deprecated NumPy API, disable it with " \
       ^
      imagecodecs/_aec.c:1222:10: fatal error: 'libaec.h' file not found
      #include "libaec.h"
               ^~~~~~~~~~
      1 warning and 1 error generated.
      error: command '/usr/bin/clang' failed with exit code 1
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for imagecodecs
  Running setup.py clean for imagecodecs
  Building wheel for cffi (pyproject.toml): started
  Building wheel for cffi (pyproject.toml): finished with status 'done'
  Created wheel for cffi: filename=cffi-1.16.0-cp38-cp38-macosx_14_0_arm64.whl size=176978 sha256=fdfac8c99413cfeabaf4a189e0b1b23288ddc20150607ba194143b848d6cf0b6
  Stored in directory: /Users/simbamangu/Library/Caches/pip/wheels/f4/df/d7/20c740c0373c550cdca4fcf0eb9af36c769ad8553ea81c6a2f
Successfully built netifaces imantics detectron2 deepforest backports.zoneinfo fvcore antlr4-python3-runtime PyYAML fire cffi
Failed to build imagecodecs
ERROR: Could not build wheels for imagecodecs, which is required to install pyproject.toml-based projects
ian-coccimiglio commented 1 month ago

Seems like this can be avoided if you're using python 3.9 or higher