Comments (13)
@SorenTruelsen,
I was able to make it work on Google Colab, by manually reinstalling mediapipe
,
!pip uninstall mediapipe -y
!pip install mediapipe --user
from batch-face-swap.
I was having the same issue on windows. Your steps lead me to getting it to work. I needed to update the requirement_versions.txt
file in the base folder of stable-diffusion-webui
(same folder where webui-user.bat is) with a new line that just says mediapipe
. After doing this I needed to quit the application and relaunch it and it seemed to work.
from batch-face-swap.
I'm having trouble getting it to work in Colab. A few months ago It was working perfectly. But now it throws an error even after pip install mediapipe
or after putting it in reqs txt. Did someone find a solution for Colab?
ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'
from batch-face-swap.
I have had this problem a month or so now. No idea how to fix it. Tried to fiddle with the requirements, but couldn't get it to work. It really is a shame, this is by far my favorite extension.
Here is the full error code (COLAB+) as well as the build:
Error loading script: batch_face_swap.py
Traceback (most recent call last):
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/scripts.py", line 248, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/script_loading.py", line 11, in load_module
module_spec.loader.exec_module(module)
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/extensions/batch-face-swap/scripts/batch_face_swap.py", line 8, in
from bfs_utils import *
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/extensions/batch-face-swap/scripts/bfs_utils.py", line 11, in
import mediapipe as mp
File "/usr/local/lib/python3.9/dist-packages/mediapipe/init.py", line 15, in
from mediapipe.python import *
File "/usr/local/lib/python3.9/dist-packages/mediapipe/python/init.py", line 17, in
from mediapipe.python._framework_bindings import resource_util
ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'
Error loading script: bfs_utils.py
Traceback (most recent call last):
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/scripts.py", line 248, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/script_loading.py", line 11, in load_module
module_spec.loader.exec_module(module)
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/extensions/batch-face-swap/scripts/bfs_utils.py", line 11, in
import mediapipe as mp
File "/usr/local/lib/python3.9/dist-packages/mediapipe/init.py", line 15, in
from mediapipe.python import *
File "/usr/local/lib/python3.9/dist-packages/mediapipe/python/init.py", line 17, in
from mediapipe.python._framework_bindings import resource_util
ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'
Error loading script: face_detect.py
Traceback (most recent call last):
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/scripts.py", line 248, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/script_loading.py", line 11, in load_module
module_spec.loader.exec_module(module)
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/extensions/batch-face-swap/scripts/face_detect.py", line 8, in
import mediapipe as mp
File "/usr/local/lib/python3.9/dist-packages/mediapipe/init.py", line 15, in
from mediapipe.python import *
File "/usr/local/lib/python3.9/dist-packages/mediapipe/python/init.py", line 17, in
from mediapipe.python._framework_bindings import resource_util
ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'
from batch-face-swap.
@Riken-Shah YOU'RE THE MAN!!!!
It starts now without problems
from batch-face-swap.
also attempted manual method, when attempting step:
"Open requirements_versions.txt and add mediapipe."
could not find any txt file of that name.
from batch-face-swap.
I updated the manual install instructions to indicate where the requirement_versions.txt
file is. I don't know why the automatic install doesn't work though.
from batch-face-swap.
editing the requirements_version.txt solved the issue for me.
from batch-face-swap.
Adding to the requirements worked here too.
from batch-face-swap.
Tried with a fresh gmail + COLAB account and only installed this Addon. Still got the "ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'" error. Guess it will take some digging into the code the see what's wrong .. shit .. havent programmed in 5 years and never even seen Python before, so I might stop before I even start :)
from batch-face-swap.
Tried with a fresh gmail + COLAB account and only installed this Addon. Still got the "ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'" error. Guess it will take some digging into the code the see what's wrong .. shit .. havent programmed in 5 years and never even seen Python before, so I might stop before I even start :)
If putting mediapipe
in requirements_versions.txt
(not requirements.txt
) doesn't work then really have no idea what could be the issue.
from batch-face-swap.
from batch-face-swap.
Tried with a fresh gmail + COLAB account and only installed this Addon. Still got the "ModuleNotFoundError: No module named 'mediapipe.python._framework_bindings'" error. Guess it will take some digging into the code the see what's wrong .. shit .. havent programmed in 5 years and never even seen Python before, so I might stop before I even start :)
If putting
mediapipe
inrequirements_versions.txt
(notrequirements.txt
) doesn't work then really have no idea what could be the issue.
Thanks for responding. I'll see if I will have the energy to look into the issue.
One thing I have found is that "requirements_versions.txt
" gets overwritten by Automatic1111 all the time, so it makes a bit harder to debug. And running it on COLAB also makes it complicated, since I cant really use an IDE to test shit.
Still ... if it works for the rest of you, it must be a "local" issue.
from batch-face-swap.
Related Issues (20)
- [Feature Request] Roop Funtionality
- [BUG] "Existing masks" feature not working
- Inverted mask is not working HOT 1
- ValueError: height and width must be > 0
- Could not find upscaler?
- Seed in batches not incremented
- AttributeError: 'NoneType' object has no attribute 'mode' HOT 1
- [REQUEST] Script version
- Error running postprocess HOT 1
- [Bug] Stuck web-ui `run.bat` at `Installing requirements` step
- It doesnt work for a1111 1.5.1 HOT 8
- ModuleNotFoundError: No module named 'bfs_utils'
- Different prompts, same faces. HOT 2
- Face Mask Only
- Installation errors
- TypeError: cannot unpack non-iterable int object HOT 1
- Error when attempting to image split
- Doesnt seem to work with Roop anymore
- Compatibility with Dynamic Prompts?
- AttributeError: 'NoneType' object has no attribute 'strip'
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from batch-face-swap.