Skip to content

facechain extensions cant work in sd-web-ui #584

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

Closed
taoxq opened this issue Jul 9, 2024 · 6 comments
Closed

facechain extensions cant work in sd-web-ui #584

taoxq opened this issue Jul 9, 2024 · 6 comments

Comments

@taoxq
Copy link

taoxq commented Jul 9, 2024

I installed faceChain, but when I run SD-web-ui, it has an error;
venv "D:\AI\stable-diffusion-webui\venv\Scripts\Python.exe" fatal: not a git repository (or any of the parent directories): .git fatal: not a git repository (or any of the parent directories): .git Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug 1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)] Version: 1.9.4 Commit hash: <none> current transparent-background 1.3.1 Installing requirements for diffusers Installing sd-webui-controlnet requirement: changing opencv-python version from 4.10.0.84 to 4.8.0 Launching Web UI with arguments: no module 'xformers'. Processing without... no module 'xformers'. Processing without... No module 'xformers'. Proceeding without it. ControlNet preprocessor location: D:\AI\stable-diffusion-webui\extensions\sd-webui-controlnet\annotator\downloads 2024-07-09 16:55:09,723 - ControlNet - INFO - ControlNet v1.1.452 Loading weights [31e35c80fc] from D:\AI\stable-diffusion-webui\models\Stable-diffusion\sd_xl_base_1.0.safetensors 2024-07-09 16:55:09,946 - ControlNet - INFO - ControlNet UI callback registered. Creating model from config: D:\AI\stable-diffusion-webui\repositories\generative-models\configs\inference\sd_xl_base.yaml D:\AI\stable-diffusion-webui\venv\lib\site-packages\huggingface_hub\file_download.py:1132: FutureWarning: resume_downloadis deprecated and will be removed in version 1.0.0. Downloads always resume when possible. If you want to force a new download, useforce_download=True. warnings.warn( D:\AI\stable-diffusion-webui\venv\lib\site-packages\diffusers\models\transformers\transformer_2d.py:34: FutureWarning: Transformer2DModelOutputis deprecated and will be removed in version 1.0.0. ImportingTransformer2DModelOutputfromdiffusers.models.transformer_2dis deprecated and this will be removed in a future version. Please usefrom diffusers.models.modeling_outputs import Transformer2DModelOutput`, instead.
deprecate("Transformer2DModelOutput", "1.0.0", deprecation_message)
*** Error executing callback ui_tabs_callback for D:\AI\stable-diffusion-webui\extensions\facechain\scripts\facechain_sdwebui.py
Traceback (most recent call last):
File "D:\AI\stable-diffusion-webui\modules\script_callbacks.py", line 283, in ui_tabs_callback
res += c.callback() or []
File "D:\AI\stable-diffusion-webui\extensions\facechain\scripts\facechain_sdwebui.py", line 15, in on_ui_tabs
import app
File "D:\AI\stable-diffusion-webui\extensions\facechain\app.py", line 16, in
from facechain.inference_fact import GenPortrait
File "D:\AI\stable-diffusion-webui\extensions\facechain\facechain\inference_fact.py", line 20, in
from modelscope.pipelines import pipeline
File "D:\AI\stable-diffusion-webui\venv\lib\site-packages\modelscope\pipelines_init_.py", line 4, in
from .base import Pipeline
File "D:\AI\stable-diffusion-webui\venv\lib\site-packages\modelscope\pipelines\base.py", line 16, in
from modelscope.msdatasets import MsDataset
File "D:\AI\stable-diffusion-webui\venv\lib\site-packages\modelscope\msdatasets_init_.py", line 2, in
from .ms_dataset import MsDataset
File "D:\AI\stable-diffusion-webui\venv\lib\site-packages\modelscope\msdatasets\ms_dataset.py", line 9, in
from datasets import Dataset, DatasetDict, IterableDataset, IterableDatasetDict
ModuleNotFoundError: No module named 'datasets'


Running on local URL: http://127.0.0.1:7860

To create a public link, set share=True in launch().
Startup time: 13.2s (prepare environment: 5.8s, import torch: 2.7s, import gradio: 0.9s, setup paths: 0.6s, initialize shared: 0.2s, other imports: 0.4s, load scripts: 1.3s, create ui: 1.0s, gradio launch: 0.2s).
Applying attention optimization: Doggettx... done.
Model loaded in 3.7s (load weights from disk: 0.3s, create model: 0.4s, apply weights to model: 2.9s, calculate empty prompt: 0.1s).`

my device:
windows 11 python version 3.10.6 cuda version nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2024 NVIDIA Corporation Built on Wed_Apr_17_19:36:51_Pacific_Daylight_Time_2024 Cuda compilation tools, release 12.5, V12.5.40 Build cuda_12.5.r12.5/compiler.34177558_0
pip list log
`
Package Version


addict 2.4.0
aiohttp 3.9.5
aiosignal 1.3.1
albucore 0.0.12
albumentations 1.4.11
annotated-types 0.7.0
anyio 4.4.0
arrow 1.3.0
async-timeout 4.0.3
attrs 23.2.0
beautifulsoup4 4.12.3
binaryornot 0.4.4
certifi 2024.7.4
chardet 5.2.0
charset-normalizer 3.3.2
click 8.1.7
colorama 0.4.6
cookiecutter 2.6.0
datasets 2.20.0
dill 0.3.8
dnspython 2.6.1
easydict 1.13
email_validator 2.2.0
eval_type_backport 0.2.0
exceptiongroup 1.2.1
fastapi 0.111.0
fastapi-cli 0.0.4
filelock 3.15.4
flet 0.23.2
flet-core 0.23.2
flet-runtime 0.23.2
frozenlist 1.4.1
fsspec 2024.5.0
gdown 5.2.0
h11 0.14.0
httpcore 1.0.5
httptools 0.6.1
httpx 0.27.0
huggingface-hub 0.23.4
idna 3.7
imageio 2.34.2
importlib_metadata 8.0.0
intel-openmp 2021.4.0
Jinja2 3.1.4
joblib 1.4.2
kornia 0.7.3
kornia_rs 0.1.4
lazy_loader 0.4
markdown-it-py 3.0.0
MarkupSafe 2.1.5
mdurl 0.1.2
mkl 2021.4.0
mmcv-full 1.7.2
mpmath 1.3.0
multidict 6.0.5
multiprocess 0.70.16
mypy-extensions 1.0.0
networkx 3.3
numpy 1.26.4
oauthlib 3.2.2
opencv-python 4.10.0.84
opencv-python-headless 4.10.0.84
orjson 3.10.6
packaging 23.2
pandas 2.2.2
pillow 10.4.0
pip 24.1.2
platformdirs 4.2.2
pyarrow 16.1.0
pyarrow-hotfix 0.6
pydantic 2.8.2
pydantic_core 2.20.1
Pygments 2.18.0
pypng 0.20220715.0
pyre-extensions 0.0.23
PySocks 1.7.1
python-dateutil 2.9.0.post0
python-dotenv 1.0.1
python-multipart 0.0.9
python-slugify 8.0.4
pytz 2024.1
PyYAML 6.0.1
qrcode 7.4.2
regex 2024.5.15
repath 0.9.0
requests 2.32.3
rich 13.7.1
safetensors 0.4.3
scikit-image 0.24.0
scikit-learn 1.5.1
scipy 1.14.0
setuptools 63.2.0
shellingham 1.5.4
six 1.16.0
sniffio 1.3.1
soupsieve 2.5
starlette 0.37.2
sympy 1.13.0
tbb 2021.13.0
text-unidecode 1.3
threadpoolctl 3.5.0
tifffile 2024.7.2
timm 1.0.7
tokenizers 0.19.1
tomli 2.0.1
torch 2.3.1
torchvision 0.18.1
tqdm 4.66.4
transformers 4.42.3
transparent-background 1.3.1
typer 0.12.3
types-python-dateutil 2.9.0.20240316
typing_extensions 4.12.2
typing-inspect 0.9.0
tzdata 2024.1
ujson 5.10.0
urllib3 2.2.2
uvicorn 0.30.1
watchdog 4.0.1
watchfiles 0.22.0
websockets 12.0
wget 3.2
xformers 0.0.16
xxhash 3.4.1
yapf 0.40.2
yarl 1.9.4
zipp 3.19.2
`
and I tried pip install datasets again, but it still doesnt work

@taoxq
Copy link
Author

taoxq commented Jul 9, 2024

And I create a py file with `
from datasets import Dataset, DatasetDict, IterableDataset, IterableDatasetDict

print(Dataset)`
and put it in facechain folder , it can print normal

@In-My-Way
Copy link

first, uninstall dataset manually with pip, then reinstall it the same way, run sd, you will get a different error, reply with that and I'll run you through it since I had the same issue and managed to fix it. The error is caused because facechain uses modelscope which doesn't support the most recent releases of dataset. I'm forgetting which exact version of dataset I had to use, but I'll be able to find it from your new error.

@taoxq
Copy link
Author

taoxq commented Jul 15, 2024

first, uninstall dataset manually with pip, then reinstall it the same way, run sd, you will get a different error, reply with that and I'll run you through it since I had the same issue and managed to fix it. The error is caused because facechain uses modelscope which doesn't support the most recent releases of dataset. I'm forgetting which exact version of dataset I had to use, but I'll be able to find it from your new error.

I tried, but it didnt work, I got the same error as before, And i also try to install datasets 2.0.0, 1.9.0,

@ugg
Copy link

ugg commented Jul 18, 2024

try to pip install datasets==2.18.0

@taoxq
Copy link
Author

taoxq commented Jul 19, 2024

try to pip install datasets==2.18.0

thanks , but i got another error, and i give up,here is the new error
*** Error executing callback ui_tabs_callback for D:\AI\sd-webui-aki\extensions\facechain\scripts\facechain_sdwebui.py Traceback (most recent call last): File "D:\AI\sd-webui-aki\modules\script_callbacks.py", line 180, in ui_tabs_callback res += c.callback() or [] File "D:\AI\sd-webui-aki\extensions\facechain\scripts\facechain_sdwebui.py", line 15, in on_ui_tabs import app File "D:\AI\sd-webui-aki\extensions\facechain\app.py", line 16, in <module> from facechain.inference_fact import GenPortrait File "D:\AI\sd-webui-aki\extensions\facechain\facechain\inference_fact.py", line 23, in <module> from face_adapter import FaceAdapter_v1, Face_Extracter_v1 File "D:\AI\sd-webui-aki\extensions\facechain\face_adapter\__init__.py", line 1, in <module> from .face_adapter_v1 import FaceAdapter_v1, Face_Extracter_v1 File "D:\AI\sd-webui-aki\extensions\facechain\face_adapter\face_adapter_v1.py", line 6, in <module> from diffusers.pipelines.controlnet import MultiControlNetModel ModuleNotFoundError: No module named 'diffusers.pipelines.controlnet'

@sunbaigui
Copy link
Collaborator

merged to #577

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants