Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] FaceSwap node not loading #58

Closed
Piscabo opened this issue Aug 9, 2023 · 11 comments
Closed

[bug] FaceSwap node not loading #58

Piscabo opened this issue Aug 9, 2023 · 11 comments
Labels
status: ℹ️ needs more info Issue needs more information, discussion or reproducible example type: 🐛 bug Something isn't working

Comments

@Piscabo
Copy link

Piscabo commented Aug 9, 2023

Describe the bug

FaceSwap
LoadFaceSwapModel
LoadFaceAnalysisModel
[comfy_mtb] | STATUS -> Some nodes failed to load:
Failed to import module faceswap because ModuleNotFoundError: No module named 'onnx.onnx_cpp2py_export.checker'; 'onnx.onnx_cpp2py_export' is not a package

Check that you properly installed the dependencies.

Reproduction

Reinstall MTB nodes
Faceswap nodes not loading

Expected behavior

Faceswap model listed as node, currently none

Platform and versions

Windows 11
Active VENV
### ComfyUI Revision: 1268 [a5599ed4]

Console output

[comfy_mtb] | WARNING -> Web extensions folder at A:\AI_Files\ComfyUI\web\extensions\mtb is not a symlink, if updating please delete it before
FaceSwap
LoadFaceSwapModel
LoadFaceAnalysisModel
[comfy_mtb] | STATUS -> Some nodes failed to load:
        Failed to import module faceswap because ModuleNotFoundError: No module named 'onnx.onnx_cpp2py_export.checker'; 'onnx.onnx_cpp2py_export' is not a package

Check that you properly installed the dependencies.

Additional context

I have really tried my best to solve this, but I get an error with ONNX building the wheels. Might that be the problem?
I don't have ROOP installed.

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for onnx
Failed to build onnx
ERROR: Could not build wheels for onnx, which is required to install pyproject.toml-based projects

@Piscabo Piscabo added status: 🧹 needs triage This issue needs to triage, applied to new issues type: 🐛 bug Something isn't working labels Aug 9, 2023
@melMass
Copy link
Owner

melMass commented Aug 9, 2023

That's strange, onnx should not require a source build, what is your python version?

You are using a custom venv right not portable?

If so you can try to run this from you virtualenv:

python -m pip install onnxruntime-gpu==1.15.1

One other possibility is another extension that uses a different version of onnx but that would be the first report about it.

@Piscabo
Copy link
Author

Piscabo commented Aug 9, 2023

Switched to my A1111 venv and all was fine till I tried Roop, Remember the whole debacle on Discord, since then my MTB is broken. (not using portable)
Tried every leed I could find... :-(
pip 23.2.1 from A:\AI_Files\stable-diffusion-webui\venv\lib\site-packages\pip (python 3.10)

@melMass
Copy link
Owner

melMass commented Aug 9, 2023

Tried every leed I could find...

I think I found the main culrprit for the errors on windows! I will try to get it into #50 and release 0.1.4 with the fix by tomorrow!

The python version is fine so it's not that, can you run pip freeze and put the log? This will list all installed dependencies in your venv with their versions.

@melMass
Copy link
Owner

melMass commented Aug 9, 2023

For reference, this is the results of pip freeze from the CI : https://github.com/melMass/comfy_mtb/actions/runs/5801740687/job/15726640368#step:8:95

@melMass
Copy link
Owner

melMass commented Aug 12, 2023

Do you still have this issue? The update was pushed

@melMass melMass added status: ℹ️ needs more info Issue needs more information, discussion or reproducible example and removed status: 🧹 needs triage This issue needs to triage, applied to new issues labels Aug 14, 2023
@melMass
Copy link
Owner

melMass commented Aug 14, 2023

comment to reopen!

@melMass melMass closed this as completed Aug 14, 2023
@Piscabo
Copy link
Author

Piscabo commented Aug 14, 2023

comment to reopen!

I'm still battling. But I don't think that it is anything on your side. I need to find out why it is looking for these files...
I did the pi install list (freeze) and compared it to what you have at that link. There were just minor version differences, otherwise almost identical.
The module loads, but without faceswap
image

_"[comfy_mtb] | WARNING -> Web extensions folder at A:\AI_Files\ComfyUI\web\extensions\mtb is not a symlink, if updating please delete it before
[comfy_mtb] | STATUS -> Some nodes failed to load:
Failed to import module faceswap because ModuleNotFoundError: No module named 'onnx.onnx_cpp2py_export.defs'; 'onnx.onnx_cpp2py_export' is not a package

Check that you properly installed the dependencies.
If you think this is a bug, please report it on the github page (https://github.com/melMass/comfy_mtb/issues)
[comfy_mtb] | STATUS -> Loaded the following nodes:"_

@Piscabo
Copy link
Author

Piscabo commented Aug 14, 2023

comment to reopen!

I literally just ran the manager now an there was an update for MTB again. It now WORKS!

@kerbi
Copy link

kerbi commented Aug 24, 2023

Hi ! I'm having the same exact issue and I don't know how to fix it.

[comfy_mtb] | INFO -> Some nodes failed to load:
        Failed to import module faceswap because ModuleNotFoundError: No module named 'onnx.onnx_cpp2py_export.defs'; 'onnx.onnx_cpp2py_export' is not a package

Check that you properly installed the dependencies.
If you think this is a bug, please report it on the github page (https://github.com/melMass/comfy_mtb/issues)

I'm on windows 10, installed mtb from the node manager if I recall correctly.
I use a conda env for comfyui.

Already tried the steps above, didn't work.

I don't need a fix urgently or anything, just reporting.

@melMass
Copy link
Owner

melMass commented Aug 24, 2023

@kerbi Thanks, there might be another extension relying on a different version of onnx (the error looks like so).
I was taking a break but I'm back and will pick up #62 tomorrow and then have a look again at all this dependency madness 😆

@kerbi
Copy link

kerbi commented Aug 31, 2023

Hi ! Updated everything and still the same error.
Would that help if I gave you a list of my installed custom nodes ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: ℹ️ needs more info Issue needs more information, discussion or reproducible example type: 🐛 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants