warmshao / FasterLivePortrait

Bring portraits to life in Real Time!onnx/tensorrt support!实时肖像驱动!
518 stars 48 forks source link

M2 Macos build error #18

Closed yyakupoglu closed 4 months ago

yyakupoglu commented 4 months ago

Hi, newly pyenv virtualenv with py 3.10.10 doesn't build, error on insightface.

Building wheels for collected packages: insightface Building wheel for insightface (pyproject.toml) ... error error: subprocess-exited-with-error

× Building wheel for insightface (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [486 lines of output] WARNING: pandoc not enabled running bdist_wheel running build running build_py creating build creating build/lib.macosx-13.2-arm64-cpython-310 creating build/lib.macosx-13.2-arm64-cpython-310/insightface copying insightface/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface creating build/lib.macosx-13.2-arm64-cpython-310/insightface/app copying insightface/app/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/app copying insightface/app/mask_renderer.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/app copying insightface/app/common.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/app copying insightface/app/face_analysis.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/app creating build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/download.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/filesystem.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/transform.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/storage.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/face_align.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils copying insightface/utils/constant.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/utils creating build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/landmark.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/inswapper.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/arcface_onnx.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/retinaface.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/attribute.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/model_zoo.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/scrfd.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo copying insightface/model_zoo/model_store.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/model_zoo creating build/lib.macosx-13.2-arm64-cpython-310/insightface/commands copying insightface/commands/insightface_cli.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/commands copying insightface/commands/rec_add_mask_param.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/commands copying insightface/commands/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/commands copying insightface/commands/model_download.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/commands creating build/lib.macosx-13.2-arm64-cpython-310/insightface/data copying insightface/data/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data copying insightface/data/rec_builder.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data copying insightface/data/pickle_object.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data copying insightface/data/image.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data creating build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty copying insightface/thirdparty/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty creating build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d copying insightface/thirdparty/face3d/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d creating build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh copying insightface/thirdparty/face3d/mesh/light.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh copying insightface/thirdparty/face3d/mesh/render.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh copying insightface/thirdparty/face3d/mesh/io.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh copying insightface/thirdparty/face3d/mesh/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh copying insightface/thirdparty/face3d/mesh/vis.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh copying insightface/thirdparty/face3d/mesh/transform.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh creating build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy copying insightface/thirdparty/face3d/mesh_numpy/light.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy copying insightface/thirdparty/face3d/mesh_numpy/render.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy copying insightface/thirdparty/face3d/mesh_numpy/io.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy copying insightface/thirdparty/face3d/mesh_numpy/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy copying insightface/thirdparty/face3d/mesh_numpy/vis.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy copying insightface/thirdparty/face3d/mesh_numpy/transform.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh_numpy creating build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/morphable_model copying insightface/thirdparty/face3d/morphable_model/morphabel_model.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/morphable_model copying insightface/thirdparty/face3d/morphable_model/fit.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/morphable_model copying insightface/thirdparty/face3d/morphable_model/init.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/morphable_model copying insightface/thirdparty/face3d/morphable_model/load.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/morphable_model running egg_info writing insightface.egg-info/PKG-INFO writing dependency_links to insightface.egg-info/dependency_links.txt writing entry points to insightface.egg-info/entry_points.txt writing requirements to insightface.egg-info/requires.txt writing top-level names to insightface.egg-info/top_level.txt reading manifest file 'insightface.egg-info/SOURCES.txt' writing manifest file 'insightface.egg-info/SOURCES.txt' /private/var/folders/r5/qzv76wc55l50bdkxc6khcn_m0000gn/T/pip-build-env-pn4jk678/overlay/lib/python3.10/site-packages/setuptools/command/build_py.py:215: _Warning: Package 'insightface.data.images' is absent from the packages configuration. !!

          ********************************************************************************
          ############################
          # Package would be ignored #
          ############################
          Python recognizes 'insightface.data.images' as an importable package[^1],
          but it is absent from setuptools' `packages` configuration.

          This leads to an ambiguous overall configuration. If you want to distribute this
          package, please make sure that 'insightface.data.images' is explicitly added
          to the `packages` configuration field.

          Alternatively, you can also rely on setuptools' discovery methods
          (for example by using `find_namespace_packages(...)`/`find_namespace:`
          instead of `find_packages(...)`/`find:`).

          You can read more about "package discovery" on setuptools documentation page:

          - https://setuptools.pypa.io/en/latest/userguide/package_discovery.html

          If you don't want 'insightface.data.images' to be distributed and are
          already explicitly excluding 'insightface.data.images' via
          `find_namespace_packages(...)/find_namespace` or `find_packages(...)/find`,
          you can try to use `exclude_package_data`, or `include-package-data=False` in
          combination with a more fine grained `package-data` configuration.

          You can read more about "package data files" on setuptools documentation page:

          - https://setuptools.pypa.io/en/latest/userguide/datafiles.html

          [^1]: For Python, any directory (with suitable naming) can be imported,
                even if it does not contain any `.py` files.
                On the other hand, currently there is no concept of package data
                directory, all directories are treated like packages.
          ********************************************************************************

  !!
    check.warn(importable)
  /private/var/folders/r5/qzv76wc55l50bdkxc6khcn_m0000gn/T/pip-build-env-pn4jk678/overlay/lib/python3.10/site-packages/setuptools/command/build_py.py:215: _Warning: Package 'insightface.data.objects' is absent from the `packages` configuration.
  !!

          ********************************************************************************
          ############################
          # Package would be ignored #
          ############################
          Python recognizes 'insightface.data.objects' as an importable package[^1],
          but it is absent from setuptools' `packages` configuration.

          This leads to an ambiguous overall configuration. If you want to distribute this
          package, please make sure that 'insightface.data.objects' is explicitly added
          to the `packages` configuration field.

          Alternatively, you can also rely on setuptools' discovery methods
          (for example by using `find_namespace_packages(...)`/`find_namespace:`
          instead of `find_packages(...)`/`find:`).

          You can read more about "package discovery" on setuptools documentation page:

          - https://setuptools.pypa.io/en/latest/userguide/package_discovery.html

          If you don't want 'insightface.data.objects' to be distributed and are
          already explicitly excluding 'insightface.data.objects' via
          `find_namespace_packages(...)/find_namespace` or `find_packages(...)/find`,
          you can try to use `exclude_package_data`, or `include-package-data=False` in
          combination with a more fine grained `package-data` configuration.

          You can read more about "package data files" on setuptools documentation page:

          - https://setuptools.pypa.io/en/latest/userguide/datafiles.html

          [^1]: For Python, any directory (with suitable naming) can be imported,
                even if it does not contain any `.py` files.
                On the other hand, currently there is no concept of package data
                directory, all directories are treated like packages.
          ********************************************************************************

  !!
    check.warn(importable)
  /private/var/folders/r5/qzv76wc55l50bdkxc6khcn_m0000gn/T/pip-build-env-pn4jk678/overlay/lib/python3.10/site-packages/setuptools/command/build_py.py:215: _Warning: Package 'insightface.thirdparty.face3d.mesh.cython' is absent from the `packages` configuration.
  !!

          ********************************************************************************
          ############################
          # Package would be ignored #
          ############################
          Python recognizes 'insightface.thirdparty.face3d.mesh.cython' as an importable package[^1],
          but it is absent from setuptools' `packages` configuration.

          This leads to an ambiguous overall configuration. If you want to distribute this
          package, please make sure that 'insightface.thirdparty.face3d.mesh.cython' is explicitly added
          to the `packages` configuration field.

          Alternatively, you can also rely on setuptools' discovery methods
          (for example by using `find_namespace_packages(...)`/`find_namespace:`
          instead of `find_packages(...)`/`find:`).

          You can read more about "package discovery" on setuptools documentation page:

          - https://setuptools.pypa.io/en/latest/userguide/package_discovery.html

          If you don't want 'insightface.thirdparty.face3d.mesh.cython' to be distributed and are
          already explicitly excluding 'insightface.thirdparty.face3d.mesh.cython' via
          `find_namespace_packages(...)/find_namespace` or `find_packages(...)/find`,
          you can try to use `exclude_package_data`, or `include-package-data=False` in
          combination with a more fine grained `package-data` configuration.

          You can read more about "package data files" on setuptools documentation page:

          - https://setuptools.pypa.io/en/latest/userguide/datafiles.html

          [^1]: For Python, any directory (with suitable naming) can be imported,
                even if it does not contain any `.py` files.
                On the other hand, currently there is no concept of package data
                directory, all directories are treated like packages.
          ********************************************************************************

  !!
    check.warn(importable)
  creating build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  copying insightface/data/images/Tom_Hanks_54745.png -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  copying insightface/data/images/mask_black.jpg -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  copying insightface/data/images/mask_blue.jpg -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  copying insightface/data/images/mask_green.jpg -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  copying insightface/data/images/mask_white.jpg -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  copying insightface/data/images/t1.jpg -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/images
  creating build/lib.macosx-13.2-arm64-cpython-310/insightface/data/objects
  copying insightface/data/objects/meanshape_68.pkl -> build/lib.macosx-13.2-arm64-cpython-310/insightface/data/objects
  creating build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  copying insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  copying insightface/thirdparty/face3d/mesh/cython/mesh_core.h -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  copying insightface/thirdparty/face3d/mesh/cython/mesh_core_cython.c -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  copying insightface/thirdparty/face3d/mesh/cython/mesh_core_cython.cpp -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  copying insightface/thirdparty/face3d/mesh/cython/mesh_core_cython.pyx -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  copying insightface/thirdparty/face3d/mesh/cython/setup.py -> build/lib.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  running build_ext
  building 'insightface.thirdparty.face3d.mesh.cython.mesh_core_cython' extension
  creating build/temp.macosx-13.2-arm64-cpython-310
  creating build/temp.macosx-13.2-arm64-cpython-310/insightface
  creating build/temp.macosx-13.2-arm64-cpython-310/insightface/thirdparty
  creating build/temp.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d
  creating build/temp.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh
  creating build/temp.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython
  clang -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -Iinsightface/thirdparty/face3d/mesh/cython -I/private/var/folders/r5/qzv76wc55l50bdkxc6khcn_m0000gn/T/pip-build-env-pn4jk678/overlay/lib/python3.10/site-packages/numpy/_core/include -I/Users/yigit/.pyenv/versions/3.10.10/envs/flp/include -I/Users/yigit/.pyenv/versions/3.10.10/include/python3.10 -c insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp -o build/temp.macosx-13.2-arm64-cpython-310/insightface/thirdparty/face3d/mesh/cython/mesh_core.o
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:4:
  In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:64:
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:93:16: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          unsigned char   *_base;
                          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:93:16: note: insert '_Nullable' if the pointer may be null
          unsigned char   *_base;
                          ^
                            _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:93:16: note: insert '_Nonnull' if the pointer should never be null
          unsigned char   *_base;
                          ^
                            _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:138:32: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          int     (* _Nullable _read) (void *, char *, int);
                                            ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:138:32: note: insert '_Nullable' if the pointer may be null
          int     (* _Nullable _read) (void *, char *, int);
                                            ^
                                             _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:138:32: note: insert '_Nonnull' if the pointer should never be null
          int     (* _Nullable _read) (void *, char *, int);
                                            ^
                                             _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:138:40: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          int     (* _Nullable _read) (void *, char *, int);
                                                    ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:138:40: note: insert '_Nullable' if the pointer may be null
          int     (* _Nullable _read) (void *, char *, int);
                                                    ^
                                                     _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:138:40: note: insert '_Nonnull' if the pointer should never be null
          int     (* _Nullable _read) (void *, char *, int);
                                                    ^
                                                     _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:139:35: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          fpos_t  (* _Nullable _seek) (void *, fpos_t, int);
                                            ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:139:35: note: insert '_Nullable' if the pointer may be null
          fpos_t  (* _Nullable _seek) (void *, fpos_t, int);
                                            ^
                                             _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:139:35: note: insert '_Nonnull' if the pointer should never be null
          fpos_t  (* _Nullable _seek) (void *, fpos_t, int);
                                            ^
                                             _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:140:32: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          int     (* _Nullable _write)(void *, const char *, int);
                                            ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:140:32: note: insert '_Nullable' if the pointer may be null
          int     (* _Nullable _write)(void *, const char *, int);
                                            ^
                                             _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:140:32: note: insert '_Nonnull' if the pointer should never be null
          int     (* _Nullable _write)(void *, const char *, int);
                                            ^
                                             _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:140:46: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          int     (* _Nullable _write)(void *, const char *, int);
                                                          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:140:46: note: insert '_Nullable' if the pointer may be null
          int     (* _Nullable _write)(void *, const char *, int);
                                                          ^
                                                           _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:140:46: note: insert '_Nonnull' if the pointer should never be null
          int     (* _Nullable _write)(void *, const char *, int);
                                                          ^
                                                           _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:144:18: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
          struct __sFILEX *_extra; /* additions to FILE to not break ABI */
                          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:144:18: note: insert '_Nullable' if the pointer may be null
          struct __sFILEX *_extra; /* additions to FILE to not break ABI */
                          ^
                            _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h:144:18: note: insert '_Nonnull' if the pointer should never be null
          struct __sFILEX *_extra; /* additions to FILE to not break ABI */
                          ^
                            _Nonnull
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:4:
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:69:13: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
  extern FILE *__stdinp;
              ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:69:13: note: insert '_Nullable' if the pointer may be null
  extern FILE *__stdinp;
              ^
                _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:69:13: note: insert '_Nonnull' if the pointer should never be null
  extern FILE *__stdinp;
              ^
                _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:388:41: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
                   int (* _Nullable)(void *, const char *, int),
                                          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:388:41: note: insert '_Nullable' if the pointer may be null
                   int (* _Nullable)(void *, const char *, int),
                                          ^
                                           _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:388:41: note: insert '_Nonnull' if the pointer should never be null
                   int (* _Nullable)(void *, const char *, int),
                                          ^
                                           _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:388:55: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
                   int (* _Nullable)(void *, const char *, int),
                                                        ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:388:55: note: insert '_Nullable' if the pointer may be null
                   int (* _Nullable)(void *, const char *, int),
                                                        ^
                                                         _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:388:55: note: insert '_Nonnull' if the pointer should never be null
                   int (* _Nullable)(void *, const char *, int),
                                                        ^
                                                         _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:389:44: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
                   fpos_t (* _Nullable)(void *, fpos_t, int),
                                             ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:389:44: note: insert '_Nullable' if the pointer may be null
                   fpos_t (* _Nullable)(void *, fpos_t, int),
                                             ^
                                              _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:389:44: note: insert '_Nonnull' if the pointer should never be null
                   fpos_t (* _Nullable)(void *, fpos_t, int),
                                             ^
                                              _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:390:41: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
                   int (* _Nullable)(void *));
                                          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:390:41: note: insert '_Nullable' if the pointer may be null
                   int (* _Nullable)(void *));
                                          ^
                                           _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:390:41: note: insert '_Nonnull' if the pointer should never be null
                   int (* _Nullable)(void *));
                                          ^
                                           _Nonnull
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:386:6: warning: pointer is missing a nullability type specifier (_Nonnull, _Nullable, or _Null_unspecified) [-Wnullability-completeness]
  FILE    *funopen(const void *,
          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:386:6: note: insert '_Nullable' if the pointer may be null
  FILE    *funopen(const void *,
          ^
            _Nullable
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:386:6: note: insert '_Nonnull' if the pointer should never be null
  FILE    *funopen(const void *,
          ^
            _Nonnull
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:5:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:321:5: error: <cmath> tried including <math.h> but didn't find libc++'s <math.h> header.           This usually means that your header search paths are not configured properly.           The header search paths should contain the C++ Standard Library headers before           any C Standard Library, and you are probably using compiler flags that make that           not be the case.
  #   error <cmath> tried including <math.h> but didn't find libc++'s <math.h> header. \
      ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:588:17: error: expected unqualified-id
      return std::isnan(__lcpp_x);
                  ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/math.h:166:5: note: expanded from macro 'isnan'
      ( sizeof(x) == sizeof(float)  ? __inline_isnanf((float)(x))          \
      ^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:5:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:608:17: error: expected unqualified-id
      return std::isinf(__lcpp_x);
                  ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/math.h:161:5: note: expanded from macro 'isinf'
      ( sizeof(x) == sizeof(float)  ? __inline_isinff((float)(x))          \
      ^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:5:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:724:15: error: no template named 'numeric_limits'
        return -numeric_limits<_Tp>::infinity();
                ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:728:14: error: no template named 'numeric_limits'
        return numeric_limits<_Tp>::infinity();
               ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:731:14: error: no template named 'numeric_limits'
        return numeric_limits<_Tp>::quiet_NaN();
               ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:735:19: error: no template named 'numeric_limits'
      while (__x >= numeric_limits<_Tp>::radix) {
                    ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:736:14: error: no template named 'numeric_limits'
        __x /= numeric_limits<_Tp>::radix;
               ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:759:14: error: no template named 'numeric_limits'
        return numeric_limits<_Tp>::quiet_NaN();
               ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:763:16: error: no template named 'numeric_limits'
        __mult = numeric_limits<_Tp>::radix;
                 ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:768:17: error: no template named 'numeric_limits'
        __mult /= numeric_limits<_Tp>::radix;
                  ^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:5:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:834:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/type_traits:425:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/add_pointer.h:17:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/remove_reference.h:13:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstddef:46:5: error: <cstddef> tried including <stddef.h> but didn't find libc++'s <stddef.h> header.           This usually means that your header search paths are not configured properly.           The header search paths should contain the C++ Standard Library headers before           any C Standard Library, and you are probably using compiler flags that make that           not be the case.
  #   error <cstddef> tried including <stddef.h> but didn't find libc++'s <stddef.h> header. \
      ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstddef:59:9: error: no member named 'nullptr_t' in the global namespace
  using ::nullptr_t;
        ~~^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:5:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:834:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/type_traits:456:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_compound.h:14:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_fundamental.h:14:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_null_pointer.h:26:28: error: use of undeclared identifier 'nullptr_t'
  struct __is_nullptr_t_impl<nullptr_t> : public true_type {};
                             ^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:5:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:834:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/type_traits:508:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/is_trivially_copyable.h:14:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstdint:149:5: error: <cstdint> tried including <stdint.h> but didn't find libc++'s <stdint.h> header.           This usually means that your header search paths are not configured properly.           The header search paths should contain the C++ Standard Library headers before           any C Standard Library, and you are probably using compiler flags that make that           not be the case.
  #   error <cstdint> tried including <stdint.h> but didn't find libc++'s <stdint.h> header. \
      ^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:6:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/algorithm:1751:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/copy.h:12:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/copy_move_common.h:18:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__string/constexpr_c_functions.h:14:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__memory/construct_at.h:23:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/new:99:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstdlib:90:5: error: <cstdlib> tried including <stdlib.h> but didn't find libc++'s <stdlib.h> header.           This usually means that your header search paths are not configured properly.           The header search paths should contain the C++ Standard Library headers before           any C Standard Library, and you are probably using compiler flags that make that           not be the case.
  #   error <cstdlib> tried including <stdlib.h> but didn't find libc++'s <stdlib.h> header. \
      ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cstdlib:132:9: error: target of using declaration conflicts with declaration already in scope
  using ::abs _LIBCPP_USING_IF_EXISTS;
          ^
  /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h:132:6: note: target of using declaration
  int      abs(int) __pure2;
           ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/cmath:354:1: note: conflicting declaration
  using ::abs _LIBCPP_USING_IF_EXISTS;
  ^
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.cpp:11:
  In file included from insightface/thirdparty/face3d/mesh/cython/mesh_core.h:6:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/algorithm:1751:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/copy.h:12:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__algorithm/copy_move_common.h:18:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__string/constexpr_c_functions.h:14:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__memory/construct_at.h:23:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/new:399:
  In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/exception:82:
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__exception/exception_ptr.h:31:39: error: field has incomplete type 'exception_ptr'
    _LIBCPP_HIDE_FROM_ABI exception_ptr(nullptr_t) _NOEXCEPT : __ptr_() {}
                                        ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__exception/exception_ptr.h:26:33: note: definition of 'std::exception_ptr' is not complete until the closing '}'
  class _LIBCPP_EXPORTED_FROM_ABI exception_ptr {
                                  ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__exception/exception_ptr.h:31:3: error: '__abi_tag__' attribute only applies to structs, variables, functions, and namespaces
    _LIBCPP_HIDE_FROM_ABI exception_ptr(nullptr_t) _NOEXCEPT : __ptr_() {}
    ^
  /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__config:870:26: note: expanded from macro '_LIBCPP_HIDE_FROM_ABI'
            __attribute__((__abi_tag__(_LIBCPP_TOSTRING(_LIBCPP_ODR_SIGNATURE))))
                           ^
  fatal error: too many errors emitted, stopping now [-ferror-limit=]
  13 warnings and 20 errors 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 insightface Failed to build insightface ERROR: Could not build wheels for insightface, which is required to install pyproject.toml-based projects

warmshao commented 4 months ago

The installation error for InsightFace is not within the scope of discussion for this project. You need to search for a solution on your own; I believe there should be solutions available online.

yyakupoglu commented 4 months ago

Build error is caused by pyenv, installing system python (which included header files) and activating virtualenv there fixed the build issue.