lshqqytiger / stable-diffusion-webui-amdgpu

Stable Diffusion web UI
GNU Affero General Public License v3.0
1.8k stars 186 forks source link

[Bug]: Can't install, getting errors after trying to launch web ui #313

Closed Minnona closed 11 months ago

Minnona commented 11 months ago

Is there an existing issue for this?

What happened?

Gives me a lot of errors. My system is: Win 11 AMD 7600 AMD RX6800XT

Steps to reproduce the problem

  1. Go to .... SD folder
  2. Press .... webui.bat
  3. ... Profit!

What should have happened?

Should have launched

Sysinfo

None, can't launch

What browsers do you use to access the UI ?

Mozilla Firefox

Console logs

venv "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\Scripts\Python.exe"
fatal: No names found, cannot describe anything.
Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug  1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]
Version: 1.6.0
Commit hash: 64e6b0687e182d5f17216755561c9c143d69c220
Launching Web UI with arguments:
Traceback (most recent call last):
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\launch.py", line 48, in <module>
    main()
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\launch.py", line 44, in main
    start()
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\modules\launch_utils.py", line 676, in start
    import webui
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\webui.py", line 13, in <module>
    initialize.imports()
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\modules\initialize.py", line 21, in imports
    import gradio  # noqa: F401
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\__init__.py", line 3, in <module>
    import gradio.components as components
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\__init__.py", line 1, in <module>
    from gradio.components.annotated_image import AnnotatedImage
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\annotated_image.py", line 12, in <module>
    from gradio import utils
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 353, in <module>
    class AsyncRequest:
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 372, in AsyncRequest
    client = httpx.AsyncClient()
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1397, in __init__
    self._transport = self._init_transport(
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1445, in _init_transport
    return AsyncHTTPTransport(
  File "C:\Users\minn\Downloads\Stable Diffusion\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_transports\default.py", line 275, in __init__
    self._pool = httpcore.AsyncConnectionPool(
TypeError: AsyncConnectionPool.__init__() got an unexpected keyword argument 'socket_options'
Press any key to continue . . .

Additional information

No response

ferrreo commented 11 months ago

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

Dogit0mg commented 11 months ago

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

Created this account just to thank you ferrreo, really helped me, thank you

MarcoFreitas95 commented 11 months ago

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

omg tysm, had the same error and this fixed my problem

Minnona commented 11 months ago

Thank you, it worked!

shott92 commented 11 months ago

Hi all, I receive the same error: Also Windows 11 AMD 7700X AMD RX 7900 XT Using Anaconda "conda 23.9.0" and Python 3.10.13

I tried the fix mentioned here:

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

However the error persists:

Run > webui.bat --onnx --backend directml

Python 3.10.13 | packaged by Anaconda, Inc. | (main, Sep 11 2023, 13:24:38) [MSC v.1916 64 bit (AMD64)]
Version: 1.6.0
Commit hash: 64e6b0687e182d5f17216755561c9c143d69c220
Installing onnxruntime
Installing onnxruntime-directml
Installing Olive
Launching Web UI with arguments: --onnx --backend directml
Traceback (most recent call last):
  File "C:\Users\<user>\stable-diffusion-webui-directml\launch.py", line 48, in <module>
    main()
  File "C:\Users\<user>\stable-diffusion-webui-directml\launch.py", line 44, in main
    start()
  File "C:\Users\<user>\stable-diffusion-webui-directml\modules\launch_utils.py", line 676, in start
    import webui
  File "C:\Users\<user>\stable-diffusion-webui-directml\webui.py", line 13, in <module>
    initialize.imports()
  File "C:\Users\<user>\stable-diffusion-webui-directml\modules\initialize.py", line 21, in imports
    import gradio  # noqa: F401
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\__init__.py", line 3, in <module>
    import gradio.components as components
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\__init__.py", line 1, in <module>
    from gradio.components.annotated_image import AnnotatedImage
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\annotated_image.py", line 12, in <module>
    from gradio import utils
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 353, in <module>
    class AsyncRequest:
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 372, in AsyncRequest
    client = httpx.AsyncClient()
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1397, in __init__
    self._transport = self._init_transport(
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1445, in _init_transport
    return AsyncHTTPTransport(
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_transports\default.py", line 275, in __init__
    self._pool = httpcore.AsyncConnectionPool(
TypeError: AsyncConnectionPool.__init__() got an unexpected keyword argument 'socket_options'
ferrreo commented 11 months ago

Hi all, I receive the same error: Also Windows 11 AMD 7700X AMD RX 7900 XT Using Anaconda "conda 23.9.0" and Python 3.10.13

I tried the fix mentioned here:

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

However the error persists:

Run > webui.bat --onnx --backend directml

Python 3.10.13 | packaged by Anaconda, Inc. | (main, Sep 11 2023, 13:24:38) [MSC v.1916 64 bit (AMD64)]
Version: 1.6.0
Commit hash: 64e6b0687e182d5f17216755561c9c143d69c220
Installing onnxruntime
Installing onnxruntime-directml
Installing Olive
Launching Web UI with arguments: --onnx --backend directml
Traceback (most recent call last):
  File "C:\Users\<user>\stable-diffusion-webui-directml\launch.py", line 48, in <module>
    main()
  File "C:\Users\<user>\stable-diffusion-webui-directml\launch.py", line 44, in main
    start()
  File "C:\Users\<user>\stable-diffusion-webui-directml\modules\launch_utils.py", line 676, in start
    import webui
  File "C:\Users\<user>\stable-diffusion-webui-directml\webui.py", line 13, in <module>
    initialize.imports()
  File "C:\Users\<user>\stable-diffusion-webui-directml\modules\initialize.py", line 21, in imports
    import gradio  # noqa: F401
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\__init__.py", line 3, in <module>
    import gradio.components as components
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\__init__.py", line 1, in <module>
    from gradio.components.annotated_image import AnnotatedImage
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\annotated_image.py", line 12, in <module>
    from gradio import utils
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 353, in <module>
    class AsyncRequest:
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 372, in AsyncRequest
    client = httpx.AsyncClient()
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1397, in __init__
    self._transport = self._init_transport(
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1445, in _init_transport
    return AsyncHTTPTransport(
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_transports\default.py", line 275, in __init__
    self._pool = httpcore.AsyncConnectionPool(
TypeError: AsyncConnectionPool.__init__() got an unexpected keyword argument 'socket_options'

If using onnx you need to put it in the requirements-onnx file instead

gabriel-messier commented 11 months ago

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

This fixed it, for me. Thank you!

Snakeing commented 11 months ago

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

Huge thanks to ferrreo, this saved me too

xXxZypherxXx commented 10 months ago

Hi all, I receive the same error: Also Windows 11 AMD 7700X AMD RX 7900 XT Using Anaconda "conda 23.9.0" and Python 3.10.13 I tried the fix mentioned here:

You can fix this by adding to requirements_versions.txt httpx==0.24.1 just above the httpcore==0.15

However the error persists: Run > webui.bat --onnx --backend directml

Python 3.10.13 | packaged by Anaconda, Inc. | (main, Sep 11 2023, 13:24:38) [MSC v.1916 64 bit (AMD64)]
Version: 1.6.0
Commit hash: 64e6b0687e182d5f17216755561c9c143d69c220
Installing onnxruntime
Installing onnxruntime-directml
Installing Olive
Launching Web UI with arguments: --onnx --backend directml
Traceback (most recent call last):
  File "C:\Users\<user>\stable-diffusion-webui-directml\launch.py", line 48, in <module>
    main()
  File "C:\Users\<user>\stable-diffusion-webui-directml\launch.py", line 44, in main
    start()
  File "C:\Users\<user>\stable-diffusion-webui-directml\modules\launch_utils.py", line 676, in start
    import webui
  File "C:\Users\<user>\stable-diffusion-webui-directml\webui.py", line 13, in <module>
    initialize.imports()
  File "C:\Users\<user>\stable-diffusion-webui-directml\modules\initialize.py", line 21, in imports
    import gradio  # noqa: F401
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\__init__.py", line 3, in <module>
    import gradio.components as components
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\__init__.py", line 1, in <module>
    from gradio.components.annotated_image import AnnotatedImage
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\components\annotated_image.py", line 12, in <module>
    from gradio import utils
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 353, in <module>
    class AsyncRequest:
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\gradio\utils.py", line 372, in AsyncRequest
    client = httpx.AsyncClient()
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1397, in __init__
    self._transport = self._init_transport(
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_client.py", line 1445, in _init_transport
    return AsyncHTTPTransport(
  File "C:\Users\<user>\stable-diffusion-webui-directml\venv\lib\site-packages\httpx\_transports\default.py", line 275, in __init__
    self._pool = httpcore.AsyncConnectionPool(
TypeError: AsyncConnectionPool.__init__() got an unexpected keyword argument 'socket_options'

If using onnx you need to put it in the requirements-onnx file instead

So, I've been at this for a few weeks now. I had the same error the first time, fixed it with this issue, and then loaded the UI. I've used the CUDA version of Auto1111 back in april or so on a different setup so I am familiar with some of the features. I noticed on this install, some features were not working appropriately. I could not generate images outside of 512^2 because the onnx converter ui is locked to that, and I'm sure its for good reason, but no one has mentioned it anywhere.

Additionally for the life of me I can not get it to locate embeddings, even after checking that the model and textual inversion were trained on the same base model and have appropriate extensions. Unlimited CLIP also doesn't seem to work on directml but I'm not sure this is a bug so much as a feature not yet carried over? The problem is made worse with the lack of textual inversion. Finally whenever I am able to generate a 512^2 image, it doesn't add generation data to the png chunks for future generation despite me having it checked in the settings, meaning I've lost a lot of good seeds and prompts. I figured all this was an installation problem and moved all the models to do a clean install.

I encountered this issue again and it seems to stop the install. I am not sure if it is causing any missing features. Is there any way we can get this line also added to the requirements-onnx file on the main branch so I can verify that installation can complete without issues and start looking for other sources of the problems?