SimSwap
SimSwap copied to clipboard
Wondering if anyone could tell me what this error means, i want to know why my GPU isn't being utilised.
2022-03-30 17:54:55.0301529 [E:onnxruntime:Default, provider_bridge_ort.cc:940 onnxruntime::ProviderLibrary::Get] LoadLibrary failed with error 126 "The specified module could not be found." when trying to load "C:\Users\calfr\anaconda3\envs\simswap\lib\site-packages\onnxruntime\capi\onnxruntime_providers_cuda.dll" input mean and std: 127.5 127.5 find model: ./insightface_func/models\antelope\glintr100.onnx recognition 2022-03-30 17:54:55.5913319 [E:onnxruntime:Default, provider_bridge_ort.cc:940 onnxruntime::ProviderLibrary::Get] LoadLibrary failed with error 126 "The specified module could not be found." when trying to load "C:\Users\calfr\anaconda3\envs\simswap\lib\site-packages\onnxruntime\capi\onnxruntime_providers_cuda.dll" find model: ./insightface_func/models\antelope\scrfd_10g_bnkps.onnx detection
@sevensleep92 Simply - because you installed incompatible version of cudatoolkit. Try to check it using this command "nvidia-smi" without quotes. If you have 11.x Version of cuda following instruction will help you. I just finally made proper working environment and want to share it with the world. My videocard is gtx1070, cuda verison 11.6. I bet this setup, i have installed will work with every 11.x versions of cuda.
First of all remove all of the packages from current environment or create new one. 1)conda create -n simswap python=3.6 2)conda activate simswap We need to install not the newest version of pythorch, but the one which contains proper version of cudatoolkit package. Lastest does not mean the best in our scenario. 3)conda install pytorch==1.8.0 torchvision==0.9.0 torchaudio==0.8.0 cudatoolkit=11.1 -c pytorch -c conda-forge 4)pip install --ignore-installed imageio Next step we are on purpose not installing onnxruntime, we will install gpu version at the end. 5)pip install insightface==0.2.1 moviepy We need last version of cudnn 6)conda install -c conda-forge cudnn and the last step onnxruntime-gpu version 1.9.0 7)pip install onnxruntime-gpu==1.9.0
This build of packages does not require any additional packages and if you made everything right it should work perfectly.
@Polukeev Thanks for sharing! ❤ I followed your instructions now onnx doesn't drop this error for me as well. Everything seems to work but...
I created 2 environments (versions) one without onnx (default) and another one I called: "SimSwap_GPU"
I did some tests with short videos and I get exactly the same iteration numbers on both. After I installed followed your instructions, it works with no errors but I also noticed when starting it says: "onnx: None" does it mean it's not even using my GPU?
How do I make my GPU actually used now? Is there a parameter or command I need to add to my batch files when I use the "test_video_******.py" python files?
or anything else I need to do to make it use my GPU, I want to try it to process faster but I have no idea how.
Thanks ahead!
Thanks for your shared. It's very helpfull, I'm successed runing now.