cubiq / ComfyUI_IPAdapter_plus

GNU General Public License v3.0
4.22k stars 319 forks source link

Dependencies missing for Insightface #162

Open pphoto808 opened 11 months ago

pphoto808 commented 11 months ago

Screenshot 2023-12-24 at 19 27 54

I have followed in the installation guide lines. Installed all the appropriate files in ComfyUI environment, updated Comfy and still get the same error.

Running Comfy on Mac Studio M2 Ultra.

Qiuhao-Wu commented 2 months ago

大家有ip-adapter的requirement.txt么

dxdpxl commented 1 month ago

Just a hint for everyone getting install errors... Maybe this will help one of you too! I had nearly all the install errors listed above and you possible could find on google 🤣 and NONE of the solution provided all over the places I searched helped at ALL and I tried a LOT.

After all the struggle I tough, maybe my download is corrupted... and VOILA, that was it! First try and no install errors.

Go to https://github.com/Gourieff/Assets/tree/main/Insightface

DO NOT right click on the file name and save as! It will not download the file correctly! Instead, left click on the filename and on the right, next to "Raw" click on the down-arrow which says on hoover "Download raw file" and click this one to download the file. The file via right click "save as" was only 300+kb while the downloaded file was over 800kb... 🤷‍♂️

Good luck and have a nice one

cives commented 1 month ago

Just a hint for everyone getting install errors... Maybe this will help one of you too! I had nearly all the install errors listed above and you possible could find on google 🤣 and NONE of the solution provided all over the places I searched helped at ALL and I tried a LOT.

After all the struggle I tough, maybe my download is corrupted... and VOILA, that was it! First try and no install errors.

Go to https://github.com/Gourieff/Assets/tree/main/Insightface

DO NOT right click on the file name and save as! It will not download the file correctly! Instead, left click on the filename and on the right, next to "Raw" click on the down-arrow which says on hoover "Download raw file" and click this one to download the file. The file via right click "save as" was only 300+kb while the downloaded file was over 800kb... 🤷‍♂️

Good luck and have a nice one

That was it! Thank you.

io-tyra commented 1 week ago
  • python_embeded\python.exe -m pip install insightface

still dont work plz help ! :(

PS D:\ComfyUI_windows_portable> python_embeded\python.exe -m pip install -U pip Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com Requirement already satisfied: pip in d:\comfyui_windows_portable\python_embeded\lib\site-packages (24.3.1) PS D:\ComfyUI_windows_portable> python_embeded\python.exe -m pip install insightface Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com Collecting insightface Downloading insightface-0.7.3.tar.gz (439 kB) Installing build dependencies ... done Getting requirements to build wheel ... error error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> [18 lines of output] Traceback (most recent call last): File "D:\ComfyUI_windows_portable\python_embeded\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 353, in main() File "D:\ComfyUI_windows_portable\python_embeded\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 335, in main json_out['return_val'] = hook(**hook_input['kwargs']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\python_embeded\Lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 118, in get_requires_for_build_wheel return hook(config_settings) ^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\python_embeded\Lib\site-packages\setuptools\build_meta.py", line 333, in get_requires_for_build_wheel return self._get_build_requires(config_settings, requirements=[]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\python_embeded\Lib\site-packages\setuptools\build_meta.py", line 303, in _get_build_requires self.run_setup() File "D:\ComfyUI_windows_portable\python_embeded\Lib\site-packages\setuptools\build_meta.py", line 319, in run_setup exec(code, locals()) File "", line 11, in ModuleNotFoundError: No module named 'Cython' [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip. PS D:\ComfyUI_windows_portable>

wi-cuckoo commented 1 week ago
pip3.10 install onnxruntime
pip3.10 install onnxruntime-gpu
pip3.10 install insightface

then restart the server, try it

io-tyra commented 1 week ago

Captura de pantalla 2024-11-22 062533

:( still dont work

maybe because i have (python 3.12) ?

rzyns commented 1 week ago
  • python_embeded\python.exe -m pip install insightface

still dont work plz help ! :(

PS D:\ComfyUI_windows_portable> python_embeded\python.exe -m ... ModuleNotFoundError: No module named 'Cython' [end of output] ...

I had to manually install Cython:

python_embeded\python.exe -m pip install Cython

I also had to install Python 3.12.7 (which is the version of my python_embedded\python.exe) using the full installer. You'll also need the MSVC build tools (see: https://github.com/deepinsight/insightface/issues/2340#issuecomment-1693872649)

Then, for Cython to be able to actually find the Python header files and libraries, I had to create a pydistutils.cfg file in my $HOME directory (usually C:\Users\YourUserNameHere) with the following contents (update the paths appropriately):

[build_ext]
include_dirs='C:\Program Files\Python312\include;path/to/ComfyUI_windows_portable\python_embeded\Lib\site-packages\numpy\core\include'
library_dirs='C:\Program Files\Python312\libs'

Then, python_embedded\python.exe -m pip install insightface worked for me. There has to be a better way, though... 😞