Having trouble setting up Windows 10 GPU acceleration for BXT or SXT?

19 replies1.6k views
Doug Summers avatar
Hello all,

I'll acknowledge up front I'm no expert with the CUDA stack.   I had quite a bit of trouble setting up my windows 10 laptop with NVIDIA GPU for BXT and SXT.   I couldn't get the latest version of CUDA Toolkit (v12.0) to work under multiple attempted configurations/versions of the other dependencies.   After quite a bit of struggling, I found some additional helpful info, and now the GPU is functioning correctly.   I post here in case it helps folks who are having similar problems.  

In the end, what I found most useful was a web article that helped me understand the relationship of version dependencies between GPU "compute capability" (i.e. number) of my specific NVIDIA GPU, the CUDA Toolkit version (including graphics driver), and the corresponding CuDNN and TensorFlow version numbers.   While some may get lucky and find the latest versions work, others may need to be more careful with the version dependencies.   I went "back to basics" and aligned these versions to my hardware per the info in the post below.     Not all the info is needed for PixInsight use; just the dependencies listed above and then application as per the instructions given in PixInsight BXT documentation.  Part 1 and Part 2 of the following article may help.

https://medium.com/analytics-vidhya/step-by-step-guide-to-setup-gpu-with-tensorflow-on-windows-laptop-c84634f59857

Note that if you've already installed the wrong (incompatible) versions of these items, you'll have environment variables to remove or change (set by CUDA Toolkit installation) in addition to the unwind of components.   I hope this post helps others to avoid the pain/frustration that I experienced trying to get the GPU working.  The speed increase is worth the trouble once the dependencies are discovered and sorted.

Cheers, and CS,  Doug S.
Helpful Supportive
Bill McLaughlin avatar
One problem I have found is that the link provided (in the process documentation) for the tensorflow.dll does not appear to work and leads of a download error message. As far as I can tell, that is the only place to get that file.
Doug Summers avatar
Hi Bill,   yes that (broken) link is about where it all started for me.   I put in a Github ticket for the link, but I believe from my travels that they are not going to fix it.   Something has changed in the SW architecture for CUDA 12.0 is my guess.   Trying to find an alternate source is how I figured out that the packages are pretty version sensitive, leading to the post for how to find your specific GPU and the needed component versions (from legacy sources).
Dale Penkala avatar
I was able to get my i5 W-10 computer to work but my new Ryzen 9 with W-11 I’ve not been able to get working. I just doesn’t want to run it. I don’t know enough about computers to get real technical so I’ve decided to just live with whatever the speed is and be happy with it. I do know it would make a heck of a difference with my Ryzen 9 but I’m out of idea’s on how else to make it work. Maybe its a W-11 ?? I don’t know.

Dale
Andy Wray avatar
Dale Penkala:
Maybe its a W-11 ?? I don’t know.


Dale, FWIW:  it's not a Windows 11 issue as CUDA acceleration is working fine for me on my Win 11 computers.  Do you have the latest CUDA and graphics card drivers for your Nvidia card?  If so, then it is down to the tensorflow and CuDNN versions that we would have to get right for you.
Well Written Helpful Insightful Respectful Concise Supportive
Dale Penkala avatar
Andy Wray:
Dale Penkala:
Maybe its a W-11 ?? I don’t know.


Dale, FWIW:  it's not a Windows 11 issue as CUDA acceleration is working fine for me on my Win 11 computers.  Do you have the latest CUDA and graphics card drivers for your Nvidia card?  If so, then it is down to the tensorflow and CuDNN versions that we would have to get right for you.

Yes I have all the latest drivers for my setup Andy. I don’t know if you remember but I did exactly the same thing for my w11 I did for my w10 and 11 didn’t work. I got frustrated and gave up with it.

It’s been a while and I don’t even remember the procedure so I’d have to revisit it and try again. I don’t know what version I would need now.

Dale
Doug Summers avatar
Hi Dale,   Actually there's an argument to be made that having the latest drivers IS the problem.   If you look at the web page of my original post, you'll see how to discover what your GPU "compute capability" number is, along with the model number of your GPU.   Then, using the link in the web article, match up your GPU compute capability number to the corresponding CUDA Toolkit (possibly a LEGACY toolkit), CuDNN (also possible legacy), and Tensorflow GPU_only components.  The key point is that if the latest versions aren't working for you, you may need to be more precise about obtaining LEGACY components for your hardware.   The links provided point you towards how to determine what you have, and how to get the legacy versions of those components if you need them.   It worked for me when the latest versions did not.  CS  Doug
Well Written Helpful Insightful
Dale Penkala avatar
Doug Summers:
Hi Dale,   Actually there's an argument to be made that having the latest drivers IS the problem.   If you look at the web page of my original post, you'll see how to discover what your GPU "compute capability" number is, along with the model number of your GPU.   Then, using the link in the web article, match up your GPU compute capability number to the corresponding CUDA Toolkit (possibly a LEGACY toolkit), CuDNN (also possible legacy), and Tensorflow GPU_only components.  The key point is that if the latest versions aren't working for you, you may need to be more precise about obtaining LEGACY components for your hardware.   The links provided point you towards how to determine what you have, and how to get the legacy versions of those components if you need them.   It worked for me when the latest versions did not.  CS  Doug

Thanks Doug,
I’ll have to read that article more closely then and see if I can figure out what my problem is then.

Dale
Bill McLaughlin avatar
Dale Penkala:
match up your GPU compute capability number to the corresponding CUDA Toolkit (possibly a LEGACY toolkit), CuDNN (also possible legacy), and Tensorflow GPU_only components.  The key point is that if the latest versions aren't working for you, you may need to be more precise about obtaining LEGACY components for your hardware.


That begs the question:  Where does one get the older "tensorflow.dll"  (if there is such a thing)?  Even the new one is unavailable due to the broken link issue at Tensorflow.org, much less any older versions, if such is required.

I have to wonder if maybe we need to have some folks who have that file post it somewhere for those of us that cannot get it due to the link issue.
Doug Summers avatar
I believe that you can just cut/paste the following URL (changing the version number as needed) and you'll get the download for the file you want....   In this case, I put the download for version 2.3.0.   Then follow the instructions as given in the BXT documentation for placing the file.   Good luck    DougS.

https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-gpu-windows-x86_64-2.3.0.zip
Bill McLaughlin avatar
Doug Summers:
I believe that you can just cut/paste the following URL (changing the version number as needed) and you'll get the download for the file you want


Good idea but does not work with my version.

 I decided to upgrade my GPU to one that will use all of the current versions, which I have verified, and move the present 5 year old card to my non-Pixinsight office PC. The upgraded GPU will be better for other purposes as well since the image processing PC is also used for gaming.

Thankfully, video cards have come down a lot since the Crypto-Crap crash!
Bill McLaughlin avatar
I ran across this as well on how to install tensorflow for a more modern RTX 3000 series. I have yet to try it since I am waiting for my RTX 3060 Ti to show up.

https://medium.com/analytics-vidhya/using-tensorflow-on-windows-10-with-nvidia-rtx-3000-series-gpus-637ab2a4b163
Dale Penkala avatar
I started trying to do the procedure for this new way you guys here posted and when I looked up the version number it said that I needed 8.6 but when I went to look for the correct version the highest was 8.1. I really don’t like that I have to install such large software for just 2 files (I think thats all that is needed) I may try and install it on a standard HD where I have more space. I seem to remember that once I got the DLL files I was able to delete the rest of the software??  Anyway once I seen the version issue I just quite the attempted install because I just didn’t want to screw something up on my very well performing computer.

BTW @Bill McLaughlin thats the same GPU (RTX 3060x) I have so if you get that one figured out as to what version your going to use please post it here, because thats where I kinda got stumped.

Dale
Taras_M avatar
Hi all,

Only this one has worked for me: https://www.williamliphotos.com/starnet-cuda
Read carefully and do step by step, pay attention to his screeenshots as well, as sometimes it is not very obvious, what he wrote.

CS!
John Noble avatar
Couldn't resist the urge to reply I was so blown away with the results. I followed the instructions in the link in Taras_M post (R Croman had previously provided that when I asked for some help). Long story short StarXterminator on a full frame image ran in around 30 s it was taking 10 to 15 minutes before. I did have to work out how to get back to CUDA version 11.7 other than that it worked fine!

Now if only I understood what I've actually done that would be great!

Just as a side note my grown children convinced me we needed a better PC in the house for gaming over the holidays and we should build one for family fun. I then realized that what makes a good gaming PC makes a pretty good astro PC. So I have switched from my Surface Pro to a Ryzen 9 with 65 GB of RAM. Who knew Genshin Impact and Valorant were so well aligned with PixInsight and astrophotography. Three birds with one stone!

John
Helpful Engaging Supportive
Bill McLaughlin avatar
John Noble:
Long story short StarXterminator on a full frame image ran in around 30 s it was taking 10 to 15 minutes before. I did have to work out how to get back to CUDA version 11.7 other than that it worked fine!


I got mine running on a new 3060 Ti yesterday and it cut BlurX from about 90 seconds on the CPU only to 6.3 seconds using the GPU!  It is not the newest and fastest card but cost way less than a latest hot new 4090 and given that the 4090 might have only cut the 6.3 seconds down to one or two seconds, it was a good sweet spot price-wise.  It also helps when playing games, I can now crank up the detail with little impact. The biggest thing was finding the right files and between Russ's instructions and those for StarNet, I was able to find the right Tensorflow and Cuda files.
Helpful Engaging
Dale Penkala avatar
I'm fully admitting that I'm an idiot here but, I'm attempting this 1 more time and I think this is my last try to get this to work on my W 11 Ryzen 9 GPU RTX3060 machine. Based on what I have read and tried so far and this includes 2-3 different website and youtube video's I STILL have not been able to get my new machine to work.

I have used the v12.1, v11.8 and I'm getting ready to try the 11.7 version which I believe I've tried this with no success, but I've done this so many times with frustration I've kinda forgotten every different versions I've tried. Just so you know I have gone and adjusted the "environment variables" to reflect the current version of cuda that was installed.

CAN ANYONE GIVE ME MORE GUIDANCE BASED OFF OF MY SYSTEMS HARDWARE CONFIGURATION (W 11 Ryzen 9 GPU RTX3060) WHAT VERSIONS OF TENSORFLOW AND CUDA/cuDNN THEY ARE USING?

Any help here would be greatly appreciated!

I have thought about starting a thread that people would state there computer configurations and then tell what versions of Cuda/cuDNN etc.. they are using that worked for them. I thought this would help idiots like me and maybe help others that are having the same problem.

Dale
Konrad Krebs avatar
Hi Dale,

I also had trouble to have it running. I have Ryzen 9 with RTX 3050 and it works for me now. I followed the tutorial on youtube from Cuiv. https://youtu.be/qudzeaFXC84

I guess he uses this tutorial: https://rikutalvio.blogspot.com/2023/02/pixinsight-cuda.html

Maybe this will help you as well!

Regards,
Konrad
Dale Penkala avatar
Konrad Krebs:
Hi Dale,

I also had trouble to have it running. I have Ryzen 9 with RTX 3050 and it works for me now. I followed the tutorial on youtube from Cuiv. https://youtu.be/qudzeaFXC84

I guess he uses this tutorial: https://rikutalvio.blogspot.com/2023/02/pixinsight-cuda.html

Maybe this will help you as well!

Regards,
Konrad

Hello Konrad,
Thanks for your response, I did use that exact tutorial but not thru Quiv, it was thru another YT video that referenced that same workflow to install it. I did watch Quiv’s video and based on what he showed I did everything correctly so I guess I’m pretty much done. I’ve done so many different tutorials to get this thing to work without any success. It looks like I’m pretty much done with trying to make my system work.

Dale
Dale Penkala avatar
SUCCESS! 

The only thing I did was shut off my computer out of frustration, went upstairs and had something to eat and decided to do a portrait version of my M82. Went back to my office started up the computer again and HOLY _ _ _ _ it started working! I have NO IDEA why but maybe I had to reboot my system to get things to work??? NONE of the tutorials ever mentioned about restarting or if it was needed. 

Anyway thanks to everyone that responded and @Konrad Krebs for the Quiv video as it was a double check for me!

Dale