美文网首页
tensorflow学习 (一)安装

tensorflow学习 (一)安装

作者: 对酒当歌的夜 | 来源:发表于2017-06-28 18:23 被阅读10次

环境:使用的mac系统,安装了python3.5
教程: 极客学院-中文教程

1.安装python3.5,找廖雪峰官网
2.安装 pip3
$ sudo easy_install pip3

3.安装 TensorFlow

$ sudo easy_install --upgrade six

$ sudo pip3 install --upgrade https://storage.googleapis.com/tensorflow/mac/tensorflow-0.8.0-py3-none-any.whl

4.不出意外的话就安装成功了-test
打开一个 python 终端:

$ python
>>>import tensorflow as tf
>>>hello = tf.constant('Hello, TensorFlow!')
>>> sess = tf.Session()
>>> print( sess.run(hello))
Hello, TensorFlow!

>>> a = tf.constant(10)
>>> b = tf.constant(32)
>>> print( sess.run(a+b))
42
>>>

相关文章

网友评论

      本文标题:tensorflow学习 (一)安装

      本文链接:https://www.haomeiwen.com/subject/dxtpcxtx.html