前景提要:需要一个显存>2GB的Nvidia GPU


1.在 PI 的 bin 目录中复制现有的 tensorflow.dll 文件

2.使用 Resources -> Updates -> Manage Repositories 将以下内容添加到 PI 存储库列表中:

3.运行 Resources -> Updates -> Check for Updates,继续下载

(请耐心等待 - 这是一个 1.5GB 的软件包),然后退出 PI 以完成更新

4*. 如果要恢复仅CPU工作请将存储库替换如下并重复步骤2-3



I finally got around to preparing a repository containing the CUDA/cuDNN software libraries needed to enable GPU acceleration of AI-based tools. This didn't used to be possible due to onerous license restrictions, but those have since been relaxed a bit.This is for Windows only at the moment: if this goes well I'll work on the Linux version. This isn't needed for MacOS users – the "CoreML" library provided by Apple is used, so Mac users with capable hardware get GPU acceleration of RC Astro tools out of the box.THIS IS EXPERIMENTAL – please READ this post completely, and proceed at your own risk. I can only test on a small number of hardware configs. I recommend backing up your PixInsight installation so you can roll back if it goes sideways. At the very least make a copy of the existing tensorflow.dll file in PI's bin directory – putting that back and restarting PI should effectively revert.There is a second repository to revert to CPU-only operation if something goes wrong. In the worst case, you may have to re-install PixInsight. Please roll with this if it happens, and provide kind feedback so I can try to fix it.You need a capable NVIDIA GPU. This means one with ≥ 2GB of RAM and compute capability ≥ 3.5. Check this NVIDIA page if in doubt about your GPU's capabilities. You'll need at least several GB of free disk space.The GPU repository installs version 2.10 of the "GPU-only" version of tensorflow.dll. On the TensorFlow project page, it clearly says "GPU only," but in my testing it ran in CPU-only mode just fine if there was no GPU installed. I have no idea if this will be the case on every machine. Along with the TensorFlow library, the necessary CUDA/cuDNN libraries (version 11.8) and the zlib compression library (version are installed.The CPU repository installs version 2.10 of the CPU-only build of tensorflow.dll.These libraries are all the property of the respective organizations that created them. They are distributed via these repositories for use with PixInsight/RC Astro tools only in accordance with relevant license agreements. You can find these agreements in PI's etc/legal/licenses directory after installation.To proceed, add the following to your PI repository list using Resources -> Updates -> Manage Repositories:

Then run Resources -> Updates -> Check for Updates, proceed with the download (be patient – it's a 1.5GB package), and then quit PI to complete the update. You should now enjoy GPU acceleration of RC Astro tools. This should "just work." No environment variables to set unless you want to constrain TensorFlow to only use as much GPU memory as needed (see the notes about TF_FORCE_GPU_ALLOW_GROWTH here). I've had limited success getting that setting to actually work – TensorFlow is very GPU-memory-grabby.If it doesn't work – running BXT/NXT/SXT causes a crash or doesn't use the GPU – let me know your hardware details, PI version, OS version, etc., and the full text of any error messages. If you manage to get things working where others have not, please share.You can revert to the CPU-only tensorflow.dll by changing the repository entry to

and going through the update process again. If you want to revert yet again to the GPU version, you'll need to change the repo entry again AND do a Resources -> Updates -> Reset Updates.Thanks for testing... let me know how it goes!