Tensorflow installation problem on Windows 10

不羁的心 提交于 2020-07-22 08:03:31

问题


I'm trying to install Tensorflow on a Win 10 machine.

I installed Python (3.7) successfully and then tried to followed the installation instructions on tensorflow.org.

When executing

pip install tensorflow

I get the following error message:

ERROR: Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: 'C:\Users\XXX\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.7_qbz5n2kfra8p0\LocalCache\local-packages\Python37\site-packages\tensorboard\_vendor\tensorflow_serving\sources\storage_path\__pycache__\file_system_storage_path_source_pb2.cpython-37.pyc'

Can anyone help? Thanks!


回答1:


The reason is that the Max_path limitation has not removed. You can read information about it from 3.1.2 on https://docs.python.org/3.7/using/windows.html. I meet the same trouble as you did and I solve it by setting the registry value HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem@LongPathsEnabled to 1. You can do it by Win+R, and type regedit and you can change the setting above. Hope my answer works for you.



来源:https://stackoverflow.com/questions/59388330/tensorflow-installation-problem-on-windows-10

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!