且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

无法加载本机 TensorFlow 运行时.原因:找不到图像.我究竟做错了什么?

更新时间:2023-10-18 15:57:22

感谢您的所有建议.我尝试使用

Thank you for all your suggestions. I tried installing the CPU only version of TensorFlow using

{
pip install --upgrade https://storage.googleapis.com/tensorflow/mac/cpu/tensorflow-1.0.1-py2-none-any.whl
}

解决了问题.有趣的是消息指出我没有使用 GPU.

which fixed the problem. The interesting thing were the messages stating that I was not using the GPU.

{
Python 2.7.10 (default, Jul 13 2015, 12:05:58) 
[GCC 4.2.1 Compatible Apple LLVM 6.1.0 (clang-602.0.53)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
>>> hello = tf.constant('Hello, TensorFlow!')
>>> sess = tf.Session()
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
>>> print(sess.run(hello))
Hello, TensorFlow!
}