AUTOMATIC1111 / stable-diffusion-webui-rembg

Removes backgrounds from pictures. Extension for webui.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Onnxruntime error

ChrisTello opened this issue · comments

Im getting this error everytime i start A1111 but i also dont notice anything technically broken when using the AI. i havent done anything to change any links in the PATH settings. All i could think of is a recent issue with faceswaplabs which i believe also uses onnxruntime but that plugin is working.
Screenshot 2024-03-02 224244

ConnectTimeout: HTTPSConnectionPool(host='github.com', port=443): Max retries exceeded with url: /danielgatis/rembg/releases/download/v0.0.0/u2net_human_seg.onnx (Caused by ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x00000227127A43A0>, 'Connection to github.com timed out. (connect timeout=5)'))

commented

It's because this plugin installs the CPU version of rembg. You need to replace it with the GPU version.

Try this:

pip uninstall rembg
pip install rembg[gpu] onnxruntime-gpu

Don't forget to set venv or conda env based on your installation.