英文:
Tensorflow for GPU without Conda not working
问题
I wanted to use tensorflow for GPU for my current project so I followed a tutorial from youtube to install it without using conda (https://www.youtube.com/watch?v=-Q6SM_usn84)
我想在当前项目中使用GPU来使用tensorflow,所以我按照YouTube上的教程安装,而没有使用conda(https://www.youtube.com/watch?v=-Q6SM_usn84)
I followed the tutorial and turns out there is no CUDA 11.2 for windows 11. Hence I installed the latest version i.e. CUDA 12 and followed the rest of the tutorial.
我按照教程操作,结果发现Windows 11上没有CUDA 11.2。因此,我安装了最新版本的CUDA 12,并按照教程的其余部分继续操作。
I then proceeded to create a virtualenv using python 3.10.10 and installed tensorflow using:
然后,我继续使用Python 3.10.10创建了一个虚拟环境,并安装了tensorflow:
pip3 install --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow_cpu-2.11.0-cp310-cp310-win_amd64.whl
It did install successfully and imports but does not list my GPU as a physical device available.
它成功安装并导入了,但未将我的GPU列为可用的物理设备。
After a bit of research I came across this "https://forums.developer.nvidia.com/t/how-do-i-install-cuda-11-0-on-windows-11-not-wsl2-windows-itself/192251" and reinstalled CUDA 11.2 for windows 10 in my windows 11 machine. Everything is still the same. It imports but does not list my GPU as a physical device available.
经过一些研究,我找到了这个链接"https://forums.developer.nvidia.com/t/how-do-i-install-cuda-11-0-on-windows-11-not-wsl2-windows-itself/192251",并在我的Windows 11机器上重新安装了CUDA 11.2。一切仍然如故,它可以导入,但不将我的GPU列为可用的物理设备。
英文:
I wanted to use tensorflow for GPU for my current project so I followed a tutorial from youtube to install it without using conda (https://www.youtube.com/watch?v=-Q6SM_usn84)
I followed the tutorial and turns out there is no CUDA 11.2 for windows 11. Hence I installed the latest version i.e. CUDA 12 and followed the rest of the tutorial.
I then proceeded to create a virtualenv using python 3.10.10 and installed tensorflow using:
pip3 install --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow_cpu-2.11.0-cp310-cp310-win_amd64.whl
It did install successfully and imports but does not list my GPU as a physical device available.
After a bit of research I came across this "https://forums.developer.nvidia.com/t/how-do-i-install-cuda-11-0-on-windows-11-not-wsl2-windows-itself/192251" and reinstalled CUDA 11.2 for windows 10 in my windows 11 machine. Everything is still the same.
It imports but does not list my GPU as a physical device available.
答案1
得分: 1
"TensorFlow 2.10是最后一个支持本机Windows上的GPU的TensorFlow版本。从TensorFlow 2.11开始,您需要在WSL2中安装TensorFlow,或者安装tensorflow-cpu,可选地,尝试TensorFlow-DirectML-Plugin。"
请安装TensorFlow 2.10,并按照此链接中提到的逐步说明链接来安装支持GPU的TensorFlow。确保满足链接中提供的硬件和软件要求。
您需要安装CUDA 11.2
和cuDNN 8.1
以便根据构建配置启用TensorFlow 2.10的GPU支持。
英文:
> "TensorFlow 2.10 was the last TensorFlow release that supported GPU on
> native-Windows. Starting with TensorFlow 2.11, you will need to
> install TensorFlow in WSL2, or install tensorflow-cpu and, optionally,
> try the TensorFlow-DirectML-Plugin"
Please install TensorFlow 2.10 and follow the Step-by-step instructions mentioned in this link to install TensorFlow with GPU support. Make sure all the Hardware and Software requirements are met as given in the link.
You need to install CUDA 11.2
and cuDNN 8.1
for tensorflow 2.10 to enable the GPU support as per the build configuration.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论