Skip to content

ControlNet Doesn't Seem To Work. #3008

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

Open
NotKnowingWhatNameToTake opened this issue Mar 2, 2025 · 1 comment
Open

ControlNet Doesn't Seem To Work. #3008

NotKnowingWhatNameToTake opened this issue Mar 2, 2025 · 1 comment

Comments

@NotKnowingWhatNameToTake

Currently trying to generate images with ControlNet Openpose on, and getting this error.

Traceback (most recent call last):
File "/usr/local/lib/python3.11/dist-packages/gradio/routes.py", line 488, in run_predict
output = await app.get_blocks().process_api(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/gradio/blocks.py", line 1433, in process_api
inputs = self.preprocess_data(fn_index, inputs, state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/gradio/blocks.py", line 1243, in preprocess_data
processed_input.append(block.preprocess(inputs[i]))
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/extensions/sd-webui-controlnet/scripts/utils.py", line 145, in svg_preprocess
return preprocess(inputs)
^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/gradio/components/image.py", line 274, in preprocess
im = processing_utils.decode_base64_to_image(x)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/gradio/processing_utils.py", line 59, in decode_base64_to_image
img = Image.open(BytesIO(base64.b64decode(image_encoded)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/PIL/Image.py", line 3532, in open
raise UnidentifiedImageError(msg)
PIL.UnidentifiedImageError: cannot identify image file <_io.BytesIO object at 0x7d742061fa60>
2025-03-02 06:12:05,867 - ControlNet - INFO - unit_separate = False, style_align = False
2025-03-02 06:12:05,868 - ControlNet - INFO - Loading model from cache: thibaud_xl_openpose_256lora [14288071]
2025-03-02 06:12:05,903 - ControlNet - INFO - Using preprocessor: none
2025-03-02 06:12:05,903 - ControlNet - INFO - preprocessor resolution = 512
2025-03-02 06:12:05,991 - ControlNet - INFO - ControlNet Hooked - Time = 0.13239145278930664
43% 13/30 [00:41<00:53, 3.16s/it]

Can anyone tell me how to fix this please?

@Azura-13
Copy link

Azura-13 commented Mar 2, 2025

Google Colab [Pro]
(Fresh Install from friday 21st Feb)

From last night (about 10 hours ago) I also can't get stable to load
Tried many times like i have over the last few days but now it just refusing to load the last cell
Cell finishes, process ends, no message
Restart and get this message:

Traceback (most recent call last):
File "/usr/local/lib/python3.11/dist-packages/transformers/utils/import_utils.py", line 1146, in _get_module
return importlib.import_module("." + module_name, self.name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1204, in _gcd_import
File "", line 1176, in _find_and_load
File "", line 1147, in _find_and_load_unlocked
File "", line 690, in _load_unlocked
File "", line 940, in exec_module
File "", line 241, in _call_with_frames_removed
File "/usr/local/lib/python3.11/dist-packages/transformers/modeling_utils.py", line 83, in
from accelerate import version as accelerate_version
File "/usr/local/lib/python3.11/dist-packages/accelerate/init.py", line 16, in
from .accelerator import Accelerator
File "/usr/local/lib/python3.11/dist-packages/accelerate/accelerator.py", line 34, in
from huggingface_hub import split_torch_state_dict_into_shards
ImportError: cannot import name 'split_torch_state_dict_into_shards' from 'huggingface_hub' (/usr/local/lib/python3.11/dist-packages/huggingface_hub/init.py)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/webui.py", line 13, in
initialize.imports()
File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/modules/initialize.py", line 17, in imports
import pytorch_lightning # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/pytorch_lightning/init.py", line 34, in
from pytorch_lightning.callbacks import Callback # noqa: E402
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/pytorch_lightning/callbacks/init.py", line 14, in
from pytorch_lightning.callbacks.callback import Callback
File "/usr/local/lib/python3.11/dist-packages/pytorch_lightning/callbacks/callback.py", line 25, in
from pytorch_lightning.utilities.types import STEP_OUTPUT
File "/usr/local/lib/python3.11/dist-packages/pytorch_lightning/utilities/types.py", line 28, in
from torchmetrics import Metric
File "/usr/local/lib/python3.11/dist-packages/torchmetrics/init.py", line 14, in
from torchmetrics import functional # noqa: E402
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/torchmetrics/functional/init.py", line 77, in
from torchmetrics.functional.text.bleu import bleu_score
File "/usr/local/lib/python3.11/dist-packages/torchmetrics/functional/text/init.py", line 30, in
from torchmetrics.functional.text.bert import bert_score # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/torchmetrics/functional/text/bert.py", line 24, in
from torchmetrics.functional.text.helper_embedding_metric import (
File "/usr/local/lib/python3.11/dist-packages/torchmetrics/functional/text/helper_embedding_metric.py", line 26, in
from transformers import AutoModelForMaskedLM, AutoTokenizer, PreTrainedModel, PreTrainedTokenizerBase
File "", line 1229, in _handle_fromlist
File "/usr/local/lib/python3.11/dist-packages/transformers/utils/import_utils.py", line 1136, in getattr
module = self._get_module(self._class_to_module[name])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/transformers/utils/import_utils.py", line 1148, in _get_module
raise RuntimeError(
RuntimeError: Failed to import transformers.modeling_utils because of the following error (look up to see its traceback):
cannot import name 'split_torch_state_dict_into_shards' from 'huggingface_hub' (/usr/local/lib/python3.11/dist-packages/huggingface_hub/init.py)

Process ends.

Thanks in advance Ben
=)

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

2 participants