-
Notifications
You must be signed in to change notification settings - Fork 5
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
after forge-extension update: error message with local path (which is not mine) when "background removal" activated #26
Comments
This is a ONNX related issue. @Haoming02 do you know if we need to add any extra dep requirement to the extension?
Can you share your generation setup?
Yes. They are removed. Previously they are just short-hand for testing purpose. |
The |
looked at the path, that is given in the error message "2024-06-08 18:29:40.9022887 [E:onnxruntime:Default, provider_bridge_ort.cc:1534 onnxruntime::TryGetProviderInfo_TensorRT] D:\a_work\1\s\onnxruntime\core\session\provider_bridge_ort.cc:1209 onnxruntime::ProviderLibrary::Get [ONNXRuntimeError] : 1 : FAIL : LoadLibrary failed with error 126 "" when trying to load "E:\ai_gh_repos\webui_forge_cu121_torch21\system\python\lib\site-packages\onnxruntime\capi\onnxruntime_providers_tensorrt.dll"" so, it is there. |
Hmm. By default, it should be using the CPU one. Why is it loading the tensorrt one? I also had this issue before, but after I manually |
And yeah, I just checked my installation. My I guess the problem is, the Webui checks that Hence why yours is still using providers other than CPU. |
Others also had the same issue: danielgatis/rembg#312 The simplest solution is to uninstall the gpu version and install the cpu version... |
yes, i just installed the rembg extension and it shows the same behaviour. |
from what I remember the cpu version is pretty slow even on my 14700k and consumes a lot of power. Maybe we should revert to the old rembg implementation that didn't have any issues running on GPU. The current one doesn't use the embedded python but searches for dependencies system wide for some reason and fails if you don't have cudnn etc installed and added to path. |
It's instant on 13700 though? How large of an image were you processing? |
strange, it was probably around 5-7 secs last time I checked with a 900px-1024px image |
btw, can anyone try pip uninstall rembg
pip install rembg[gpu] to see if it can work with non-CPU version of |
Pain... So you either get fricked by |
yup these dependency/package compatibility issues are a huge pain, fortunately I don’t get them so often. I’ll keep trying, the harder the better. Giving up is the last thing I can do. |
@dermesut @huchenlei @Haoming02 lil update from me A) I got rid of all the errors and warnings, however the bg extraction speed incresed drastically and took 1 minute for 800px image. :O B) I've removed the tensorrt libs, replaced the rembg finally started to use cuda instead of tensorrt and the bg extraction speed went down to 1-2 secs. So to summarize: tensorrt (onnxruntime): 60 secs N.B. also to mention that I had a newer driver with CUDA 12.5, that onnxruntime didn't support yet. Make sure you have the right cuda and cudnn versions. https://onnxruntime.ai/docs/execution-providers/CUDA-ExecutionProvider.html#requirements or just wait for a newer version (1.18.1) later this month. |
I just checked on my Automatic1111 installation, which has both But the IC-Light still works fine with no error. Tested on Forge as well, still no error. Also tested by renaming the TensorRT folder (to break the SYSTEM PATH), still no error. Guess I will test with a clean install later. |
Could just be a driver & cuda/onnx compatibility issue, like in my case. |
After updating
|
I happened to encounter that after installing onnxruntime-gpu, an error would be reported. I uninstalled onnxruntime and installed it again, and the error disappeared. |
"
2024-06-08 11:30:02.0788894 [E:onnxruntime:Default, provider_bridge_ort.cc:1534 onnxruntime::TryGetProviderInfo_TensorRT] D:\a_work\1\s\onnxruntime\core\session\provider_bridge_ort.cc:1209 onnxruntime::ProviderLibrary::Get [ONNXRuntimeError] : 1 : FAIL : LoadLibrary failed with error 126 "" when trying to load "E:\ai_gh_repos\webui_forge_cu121_torch21\system\python\lib\site-packages\onnxruntime\capi\onnxruntime_providers_tensorrt.dll"
*************** EP Error ***************
EP Error D:\a_work\1\s\onnxruntime\python\onnxruntime_pybind_state.cc:456 onnxruntime::python::RegisterTensorRTPluginsAsCustomOps Please install TensorRT libraries as mentioned in the GPU requirements page, make sure they're in the PATH or LD_LIBRARY_PATH, and that your GPU is supported.
when using ['TensorrtExecutionProvider', 'CUDAExecutionProvider', 'CPUExecutionProvider']
Falling back to ['CUDAExecutionProvider', 'CPUExecutionProvider'] and retrying.
"
still, rendering is being done, but unsable if background removal is activated.
if not, everything seems to be working as expected.
not sure, if related to that:
in img2img, i see barely a difference between the the generated image and the init-image, if "Reinforce Foreground" is activated. as though ic-light didn't do any relighting at all.
more of a question:
prior to this update, txt2img in fbc mode had gradients. now there only the option to use a custom image. is there s.th. wrong on my side or have those been removed?
The text was updated successfully, but these errors were encountered: