insightface
insightface copied to clipboard
ERROR: Could not build wheels for insightface, which is required to install pyproject.toml-based projects
Having spent a good deal of time on this, I'm at a loss. I am wondering if the following warning in the console output is related:
############################
# 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.
Visual Studio 2022 installation:
Python development: Enabled
Desktop development with C++: Enabled
Visual Studio extension development: Enabled
MSVC v143 - VS2022 C++ build tools (Latest): Installed
Windows 10 SDK (10.0.20348.0): Installed (I'm on Win10)
Python:
Python 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)] on win32
After multiple failed attempts to install via ComfyUI Manager, I opted to install insightface manually via pip:
D:\Dev\StableDiffusion\ComfyUI_windows_portable>pip install insightface==0.7.3
Expected result:
insightface installs
Actual result:
Collecting insightface==0.7.3
Using cached insightface-0.7.3.tar.gz (439 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: numpy in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from insightface==0.7.3) (1.25.2)
Collecting onnx (from insightface==0.7.3)
Obtaining dependency information for onnx from https://files.pythonhosted.org/packages/00/36/e7a7e7a85564e7d409e4e8addfa11d41015d2190bfff30064771e7c21ca0/onnx-1.14.1-cp310-cp310-win_amd64.whl.metadata
Using cached onnx-1.14.1-cp310-cp310-win_amd64.whl.metadata (15 kB)
Requirement already satisfied: tqdm in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from insightface==0.7.3) (4.66.1)
Requirement already satisfied: requests in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from insightface==0.7.3) (2.31.0)
Collecting matplotlib (from insightface==0.7.3)
Obtaining dependency information for matplotlib from https://files.pythonhosted.org/packages/da/88/513a104dc2b3e9c1395598480466c55d2b1358e05c7198764670c4b1ddd0/matplotlib-3.7.3-cp310-cp310-win_amd64.whl.metadata
Using cached matplotlib-3.7.3-cp310-cp310-win_amd64.whl.metadata (5.8 kB)
Requirement already satisfied: Pillow in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from insightface==0.7.3) (10.0.0)
Requirement already satisfied: scipy in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from insightface==0.7.3) (1.11.2)
Collecting scikit-learn (from insightface==0.7.3)
Obtaining dependency information for scikit-learn from https://files.pythonhosted.org/packages/96/cf/a714a655266229b51eb2bda117f15275f12457887f165f3c1cc58ab502f1/scikit_learn-1.3.0-cp310-cp310-win_amd64.whl.metadata
Using cached scikit_learn-1.3.0-cp310-cp310-win_amd64.whl.metadata (11 kB)
Collecting scikit-image (from insightface==0.7.3)
Obtaining dependency information for scikit-image from https://files.pythonhosted.org/packages/f3/93/65601f7577d6fd49ec23bf8fb58c04d8170b06a1544452ae2ea9f59bf11f/scikit_image-0.21.0-cp310-cp310-win_amd64.whl.metadata
Using cached scikit_image-0.21.0-cp310-cp310-win_amd64.whl.metadata (14 kB)
Collecting easydict (from insightface==0.7.3)
Using cached easydict-1.10-py3-none-any.whl
Requirement already satisfied: cython in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from insightface==0.7.3) (3.0.2)
Collecting albumentations (from insightface==0.7.3)
Obtaining dependency information for albumentations from https://files.pythonhosted.org/packages/9b/f6/c486cedb4f75147232f32ec4c97026714cfef7c7e247a1f0427bc5489f66/albumentations-1.3.1-py3-none-any.whl.metadata
Using cached albumentations-1.3.1-py3-none-any.whl.metadata (34 kB)
Collecting prettytable (from insightface==0.7.3)
Obtaining dependency information for prettytable from https://files.pythonhosted.org/packages/4d/81/316b6a55a0d1f327d04cc7b0ba9d04058cb62de6c3a4d4b0df280cbe3b0b/prettytable-3.9.0-py3-none-any.whl.metadata
Using cached prettytable-3.9.0-py3-none-any.whl.metadata (26 kB)
Requirement already satisfied: PyYAML in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from albumentations->insightface==0.7.3) (6.0.1)
Collecting qudida>=0.0.4 (from albumentations->insightface==0.7.3)
Using cached qudida-0.0.4-py3-none-any.whl (3.5 kB)
Collecting opencv-python-headless>=4.1.1 (from albumentations->insightface==0.7.3)
Obtaining dependency information for opencv-python-headless>=4.1.1 from https://files.pythonhosted.org/packages/70/78/7a13730745684584db53e8aa3c3bd84beef2dcb32bebf627bda0d6df461e/opencv_python_headless-4.8.0.76-cp37-abi3-win_amd64.whl.metadata
Using cached opencv_python_headless-4.8.0.76-cp37-abi3-win_amd64.whl.metadata (20 kB)
Requirement already satisfied: networkx>=2.8 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from scikit-image->insightface==0.7.3) (3.1)
Collecting imageio>=2.27 (from scikit-image->insightface==0.7.3)
Obtaining dependency information for imageio>=2.27 from https://files.pythonhosted.org/packages/eb/21/662994d78d8623055f8ffa91838e28f04b2a34bd5d8d6dbc6c7573285ed6/imageio-2.31.3-py3-none-any.whl.metadata
Using cached imageio-2.31.3-py3-none-any.whl.metadata (4.6 kB)
Collecting tifffile>=2022.8.12 (from scikit-image->insightface==0.7.3)
Obtaining dependency information for tifffile>=2022.8.12 from https://files.pythonhosted.org/packages/12/3e/89513f44a10c625121b7d5bc54390d7ac7f2c92a19755c052888febf9730/tifffile-2023.8.30-py3-none-any.whl.metadata
Using cached tifffile-2023.8.30-py3-none-any.whl.metadata (30 kB)
Collecting PyWavelets>=1.1.1 (from scikit-image->insightface==0.7.3)
Using cached PyWavelets-1.4.1-cp310-cp310-win_amd64.whl (4.2 MB)
Requirement already satisfied: packaging>=21 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from scikit-image->insightface==0.7.3) (23.1)
Collecting lazy_loader>=0.2 (from scikit-image->insightface==0.7.3)
Obtaining dependency information for lazy_loader>=0.2 from https://files.pythonhosted.org/packages/a1/c3/65b3814e155836acacf720e5be3b5757130346670ac454fee29d3eda1381/lazy_loader-0.3-py3-none-any.whl.metadata
Using cached lazy_loader-0.3-py3-none-any.whl.metadata (4.3 kB)
Collecting contourpy>=1.0.1 (from matplotlib->insightface==0.7.3)
Obtaining dependency information for contourpy>=1.0.1 from https://files.pythonhosted.org/packages/94/0a/5eb57dd395fade977786b2d2c98c2bee8234358794be44422fe58a719d42/contourpy-1.1.0-cp310-cp310-win_amd64.whl.metadata
Using cached contourpy-1.1.0-cp310-cp310-win_amd64.whl.metadata (5.7 kB)
Collecting cycler>=0.10 (from matplotlib->insightface==0.7.3)
Using cached cycler-0.11.0-py3-none-any.whl (6.4 kB)
Collecting fonttools>=4.22.0 (from matplotlib->insightface==0.7.3)
Obtaining dependency information for fonttools>=4.22.0 from https://files.pythonhosted.org/packages/1c/c6/408ee90eae2fd7ef85c5baaedfc8d533805f4c54fc6670dbde9539f1277b/fonttools-4.42.1-cp310-cp310-win_amd64.whl.metadata
Using cached fonttools-4.42.1-cp310-cp310-win_amd64.whl.metadata (154 kB)
Collecting kiwisolver>=1.0.1 (from matplotlib->insightface==0.7.3)
Obtaining dependency information for kiwisolver>=1.0.1 from https://files.pythonhosted.org/packages/4a/a1/8a9c9be45c642fa12954855d8b3a02d9fd8551165a558835a19508fec2e6/kiwisolver-1.4.5-cp310-cp310-win_amd64.whl.metadata
Using cached kiwisolver-1.4.5-cp310-cp310-win_amd64.whl.metadata (6.5 kB)
Collecting pyparsing>=2.3.1 (from matplotlib->insightface==0.7.3)
Obtaining dependency information for pyparsing>=2.3.1 from https://files.pythonhosted.org/packages/39/92/8486ede85fcc088f1b3dba4ce92dd29d126fd96b0008ea213167940a2475/pyparsing-3.1.1-py3-none-any.whl.metadata
Using cached pyparsing-3.1.1-py3-none-any.whl.metadata (5.1 kB)
Collecting python-dateutil>=2.7 (from matplotlib->insightface==0.7.3)
Using cached python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Collecting protobuf>=3.20.2 (from onnx->insightface==0.7.3)
Obtaining dependency information for protobuf>=3.20.2 from https://files.pythonhosted.org/packages/5e/46/5b9674a33cbf690ffdd79ab1863767a66461cd06ea7aeb9f90e4e50be7a5/protobuf-4.24.3-cp310-abi3-win_amd64.whl.metadata
Using cached protobuf-4.24.3-cp310-abi3-win_amd64.whl.metadata (540 bytes)
Requirement already satisfied: typing-extensions>=3.6.2.1 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from onnx->insightface==0.7.3) (4.7.1)
Collecting wcwidth (from prettytable->insightface==0.7.3)
Using cached wcwidth-0.2.6-py2.py3-none-any.whl (29 kB)
Requirement already satisfied: charset-normalizer<4,>=2 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from requests->insightface==0.7.3) (3.2.0)
Requirement already satisfied: idna<4,>=2.5 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from requests->insightface==0.7.3) (3.4)
Requirement already satisfied: urllib3<3,>=1.21.1 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from requests->insightface==0.7.3) (2.0.4)
Requirement already satisfied: certifi>=2017.4.17 in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from requests->insightface==0.7.3) (2023.7.22)
Collecting joblib>=1.1.1 (from scikit-learn->insightface==0.7.3)
Obtaining dependency information for joblib>=1.1.1 from https://files.pythonhosted.org/packages/10/40/d551139c85db202f1f384ba8bcf96aca2f329440a844f924c8a0040b6d02/joblib-1.3.2-py3-none-any.whl.metadata
Using cached joblib-1.3.2-py3-none-any.whl.metadata (5.4 kB)
Collecting threadpoolctl>=2.0.0 (from scikit-learn->insightface==0.7.3)
Obtaining dependency information for threadpoolctl>=2.0.0 from https://files.pythonhosted.org/packages/81/12/fd4dea011af9d69e1cad05c75f3f7202cdcbeac9b712eea58ca779a72865/threadpoolctl-3.2.0-py3-none-any.whl.metadata
Using cached threadpoolctl-3.2.0-py3-none-any.whl.metadata (10.0 kB)
Requirement already satisfied: colorama in c:\users\dave\appdata\local\packages\pythonsoftwarefoundation.python.3.10_qbz5n2kfra8p0\localcache\local-packages\python310\site-packages (from tqdm->insightface==0.7.3) (0.4.6)
Collecting six>=1.5 (from python-dateutil>=2.7->matplotlib->insightface==0.7.3)
Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Using cached albumentations-1.3.1-py3-none-any.whl (125 kB)
Using cached scikit_image-0.21.0-cp310-cp310-win_amd64.whl (22.8 MB)
Using cached matplotlib-3.7.3-cp310-cp310-win_amd64.whl (7.5 MB)
Using cached onnx-1.14.1-cp310-cp310-win_amd64.whl (13.3 MB)
Using cached prettytable-3.9.0-py3-none-any.whl (27 kB)
Using cached scikit_learn-1.3.0-cp310-cp310-win_amd64.whl (9.2 MB)
Using cached contourpy-1.1.0-cp310-cp310-win_amd64.whl (470 kB)
Using cached fonttools-4.42.1-cp310-cp310-win_amd64.whl (2.1 MB)
Using cached imageio-2.31.3-py3-none-any.whl (313 kB)
Using cached joblib-1.3.2-py3-none-any.whl (302 kB)
Using cached kiwisolver-1.4.5-cp310-cp310-win_amd64.whl (56 kB)
Using cached lazy_loader-0.3-py3-none-any.whl (9.1 kB)
Using cached opencv_python_headless-4.8.0.76-cp37-abi3-win_amd64.whl (38.0 MB)
Using cached protobuf-4.24.3-cp310-abi3-win_amd64.whl (430 kB)
Using cached pyparsing-3.1.1-py3-none-any.whl (103 kB)
Using cached threadpoolctl-3.2.0-py3-none-any.whl (15 kB)
Using cached tifffile-2023.8.30-py3-none-any.whl (221 kB)
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
?-> [214 lines of output]
WARNING: pandoc not enabled
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-cpython-310
creating build\lib.win-amd64-cpython-310\insightface
copying insightface\__init__.py -> build\lib.win-amd64-cpython-310\insightface
creating build\lib.win-amd64-cpython-310\insightface\app
copying insightface\app\common.py -> build\lib.win-amd64-cpython-310\insightface\app
copying insightface\app\face_analysis.py -> build\lib.win-amd64-cpython-310\insightface\app
copying insightface\app\mask_renderer.py -> build\lib.win-amd64-cpython-310\insightface\app
copying insightface\app\__init__.py -> build\lib.win-amd64-cpython-310\insightface\app
creating build\lib.win-amd64-cpython-310\insightface\commands
copying insightface\commands\insightface_cli.py -> build\lib.win-amd64-cpython-310\insightface\commands
copying insightface\commands\model_download.py -> build\lib.win-amd64-cpython-310\insightface\commands
copying insightface\commands\rec_add_mask_param.py -> build\lib.win-amd64-cpython-310\insightface\commands
copying insightface\commands\__init__.py -> build\lib.win-amd64-cpython-310\insightface\commands
creating build\lib.win-amd64-cpython-310\insightface\data
copying insightface\data\image.py -> build\lib.win-amd64-cpython-310\insightface\data
copying insightface\data\pickle_object.py -> build\lib.win-amd64-cpython-310\insightface\data
copying insightface\data\rec_builder.py -> build\lib.win-amd64-cpython-310\insightface\data
copying insightface\data\__init__.py -> build\lib.win-amd64-cpython-310\insightface\data
creating build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\arcface_onnx.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\attribute.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\inswapper.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\landmark.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\model_store.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\model_zoo.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\retinaface.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\scrfd.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
copying insightface\model_zoo\__init__.py -> build\lib.win-amd64-cpython-310\insightface\model_zoo
creating build\lib.win-amd64-cpython-310\insightface\thirdparty
copying insightface\thirdparty\__init__.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty
creating build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\constant.py -> build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\download.py -> build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\face_align.py -> build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\filesystem.py -> build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\storage.py -> build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\transform.py -> build\lib.win-amd64-cpython-310\insightface\utils
copying insightface\utils\__init__.py -> build\lib.win-amd64-cpython-310\insightface\utils
creating build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d
copying insightface\thirdparty\face3d\__init__.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d
creating build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
copying insightface\thirdparty\face3d\mesh\io.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
copying insightface\thirdparty\face3d\mesh\light.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
copying insightface\thirdparty\face3d\mesh\render.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
copying insightface\thirdparty\face3d\mesh\transform.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
copying insightface\thirdparty\face3d\mesh\vis.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
copying insightface\thirdparty\face3d\mesh\__init__.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh
creating build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
copying insightface\thirdparty\face3d\mesh_numpy\io.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
copying insightface\thirdparty\face3d\mesh_numpy\light.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
copying insightface\thirdparty\face3d\mesh_numpy\render.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
copying insightface\thirdparty\face3d\mesh_numpy\transform.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
copying insightface\thirdparty\face3d\mesh_numpy\vis.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
copying insightface\thirdparty\face3d\mesh_numpy\__init__.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh_numpy
creating build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\morphable_model
copying insightface\thirdparty\face3d\morphable_model\fit.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\morphable_model
copying insightface\thirdparty\face3d\morphable_model\load.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\morphable_model
copying insightface\thirdparty\face3d\morphable_model\morphabel_model.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\morphable_model
copying insightface\thirdparty\face3d\morphable_model\__init__.py -> build\lib.win-amd64-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'
C:\Users\Dave\AppData\Local\Temp\pip-build-env-uwb3lp7o\overlay\Lib\site-packages\setuptools\command\build_py.py:204: _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)
C:\Users\Dave\AppData\Local\Temp\pip-build-env-uwb3lp7o\overlay\Lib\site-packages\setuptools\command\build_py.py:204: _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)
C:\Users\Dave\AppData\Local\Temp\pip-build-env-uwb3lp7o\overlay\Lib\site-packages\setuptools\command\build_py.py:204: _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)
creating build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
copying insightface\thirdparty\face3d\mesh\cython\mesh_core.cpp -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
copying insightface\thirdparty\face3d\mesh\cython\mesh_core.h -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
copying insightface\thirdparty\face3d\mesh\cython\mesh_core_cython.cpp -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
creating build\lib.win-amd64-cpython-310\insightface\data\images
copying insightface\data\images\Tom_Hanks_54745.png -> build\lib.win-amd64-cpython-310\insightface\data\images
copying insightface\data\images\mask_black.jpg -> build\lib.win-amd64-cpython-310\insightface\data\images
copying insightface\data\images\mask_blue.jpg -> build\lib.win-amd64-cpython-310\insightface\data\images
copying insightface\data\images\mask_green.jpg -> build\lib.win-amd64-cpython-310\insightface\data\images
copying insightface\data\images\mask_white.jpg -> build\lib.win-amd64-cpython-310\insightface\data\images
copying insightface\data\images\t1.jpg -> build\lib.win-amd64-cpython-310\insightface\data\images
creating build\lib.win-amd64-cpython-310\insightface\data\objects
copying insightface\data\objects\meanshape_68.pkl -> build\lib.win-amd64-cpython-310\insightface\data\objects
copying insightface\thirdparty\face3d\mesh\cython\mesh_core_cython.c -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
copying insightface\thirdparty\face3d\mesh\cython\mesh_core_cython.pyx -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
copying insightface\thirdparty\face3d\mesh\cython\setup.py -> build\lib.win-amd64-cpython-310\insightface\thirdparty\face3d\mesh\cython
running build_ext
building 'insightface.thirdparty.face3d.mesh.cython.mesh_core_cython' extension
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
[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
I have same error
I think this might help https://github.com/Gourieff/sd-webui-reactor#insightfacebuild
I think this might help https://github.com/Gourieff/sd-webui-reactor#insightfacebuild
It helped a little - there were more missing installs. I managed to fix a couple, but am now stuck on this one: module 'cv2.gapi.wip.draw' has no attribute 'Text'
For me, installing xorg-libxext and pillow-simd seems to fix the issue.
After I installed the pre-built insightfacebuild hngn97 recommended and things were still not working I gave up and decided to look at controlnets instead. Something during the setup process for controlnets fixed the insightface issues and I'm now up and running. Since controlnet seems to accidently set things up correctly for insightface, I'm guessing this indicates some sort of issue with the insightface setup so I'll leave the issue open.
On linux/ubuntu you need to have python dev installed, for example sudo apt install python3.10-dev, replace <<3.10 >> with your python version
Windows
winget install -e --id Microsoft.VCRedist.2015+.x64
winget install -e --id Microsoft.VisualStudio.2022.BuildTools --override "--wait --add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended"
Building wheel for insightface (pyproject.toml) ... done
I think this might help https://github.com/Gourieff/sd-webui-reactor#insightfacebuild
solved, thanks
On linux/ubuntu you need to have python dev installed, for example sudo apt install python3.10-dev, replace <<3.10 >> with your python version
It's useful in my case.
Windows
winget install -e --id Microsoft.VCRedist.2015+.x64 winget install -e --id Microsoft.VisualStudio.2022.BuildTools --override "--wait --add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended"
Building wheel for insightface (pyproject.toml) ... done
This helps, thanks! I did installed Microsoft.VCRedist.2015 but still encountered this error. I guess I was missing the VS BuildTools, which is installed by the second 'winget' cmd. After both of them were installed, building wheels of InsightFace was successful.
I was getting a similar problem in Ubuntu 20.04:
gcc: fatal error: cannot execute ‘cc1plus’: execvp: No such file or directory
compilation terminated.
error: command '/usr/bin/gcc' 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
The solution was to install g++ with sudo apt-get install g++
For people using Amazon SageMaker, I ran this line (credit to ChatGPT):
apt-get install build-essential libssl-dev libffi-dev python3-dev -y
On linux/ubuntu you need to have python dev installed, for example sudo apt install python3.10-dev, replace <<3.10 >> with your python version
TY!!!!
On linux/ubuntu you need to have python dev installed, for example sudo apt install python3.10-dev, replace <<3.10 >> with your python version
mark
I encountered the same problem with ComfyUI_windows_portable, the solution is: Find or install a version of python that is the same as ComfyUI_windows_portable, copy the include and libs folders in the xxx\Python3xx\ directory to the xx\ComfyUI_windows_portable\python_embeded directory; Then install insightface ComfyUI_windows_portable>.\python_embeded\python.exe -m pip install -U insightface
我在ComfyUI_windows_portable 遇到同样的问题,解决方法是: 找一个 或者安装一个与ComfyUI_windows_portable相同的版本的python, 复制xxx\Python3xx\目录里的include和libs文件夹到xx\ComfyUI_windows_portable\python_embeded目录中; 然后安装insightface: ComfyUI_windows_portable>.\python_embeded\python.exe -m pip install -U insightface
The posted error says Microsoft Visual C++ 14.0 required. Whereas in my wsl2/Ubuntu needed install Clang.
sudo apt install clang
I finally found the fix.. on windows well you need Microsoft Visual C++ 14.0 no issue but on linux it was painful to fix,
the commands to fix in Linux:
conda install gxx_linux-64 conda install gcc_linux-64
even if u have gc++ or gcc on linux conda needs this command for some reason
why you guys still use conda .... its take way more hdd space and do the same thing as venv python packed ...
Using anconda fixed the problem
I think this might help https://github.com/Gourieff/sd-webui-reactor#insightfacebuild
This solved it! Thanks!
For anyone that is still struggling on Mac M1/M2, what worked for me is changing compiler to clang
as follows:
brew install llvm libomp
Then find your bin directory with
find /opt/homebrew/ -name clang
And then use the path found before installing:
export CC=/opt/homebrew//Cellar/llvm/<YOUR_LLVM_VERSION>/bin/clang