Open VirtualityDave opened 1 year ago
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
That's all it takes.
cd /var/lib/dpkg
mv info info.bak
mkdir info
apt-get update
apt-get install build-essential libssl-dev libffi-dev python3-lib2to3 python3-distutils python3-dev -y
This method works for me
Go to https://github.com/Gourieff/Assets/tree/main/InsightFace to download the same InsightFace file as the Python version In this repository, you can see multiple versions of the insight face file. Choose the appropriate files to download based on your Python version. For example, if your Python version is 3.10, download the corresponding file
Go to the COMFYUI Root Directory: open the terminal, enter the command line to go to the COMFYUI root directory We enter the following command python.exe -m pip install insightface Uninstall if previous installation fails: python.exe -m pip uninstall insightface Then update the Pip: python.exe -m pip install -U pip Reinstall InsightFace from the WHL file: python.exe -m pip install insightface-0.7.3-cp311-cp311-win_amd64.whl Once the installation is complete, we'll have the insightface file in our Python folder
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:
Visual Studio 2022 installation:
Python:
After multiple failed attempts to install via ComfyUI Manager, I opted to install insightface manually via pip:
Expected result:
Actual result: