tensorflow安装记录
来源:互联网 发布:郭敬明作品集软件下载 编辑:程序博客网 时间:2024/06/09 19:12
环境:
win7+vmware
Ubuntu 16.04.3 LTS
Python 2.7.12 (default, Nov 20 2017, 18:23:56)
[GCC 5.4.0 20160609] on linux2
Type "help", "copyright", "credits" or "license" for more information.
正确的安装姿势:
sudo apt-get install python-pip python-dev
很顺利,但是需要更新pip到最新版本.
pip install --upgrade pip
由于国内到国外有大墙(我司有用搬瓦工服务器搭建的shadow vpn),就下载whl安装
安装文件分享出来:http://download.csdn.net/download/yx511500623/10152547
最后:
root@zsj-ubuntn:~# pip install '/root/桌面/tensorflow-0.8.0-cp27-none-linux_x86_64.whl'
Processing ./??/tensorflow-0.8.0-cp27-none-linux_x86_64.whl
Collecting numpy>=1.8.2 (from tensorflow==0.8.0)
Downloading numpy-1.13.3-cp27-cp27mu-manylinux1_x86_64.whl (16.6MB)
100% |████████████████████████████████| 16.7MB 8.3kB/s
Collecting six>=1.10.0 (from tensorflow==0.8.0)
Downloading six-1.11.0-py2.py3-none-any.whl
Collecting protobuf==3.0.0b2 (from tensorflow==0.8.0)
Downloading protobuf-3.0.0b2-py2.py3-none-any.whl (326kB)
100% |████████████████████████████████| 327kB 40kB/s
Requirement already satisfied: wheel in /usr/lib/python2.7/dist-packages (from tensorflow==0.8.0)
Requirement already satisfied: setuptools in /usr/lib/python2.7/dist-packages (from protobuf==3.0.0b2->tensorflow==0.8.0)
Installing collected packages: numpy, six, protobuf, tensorflow
Successfully installed numpy-1.13.3 protobuf-3.0.0b2 six-1.11.0 tensorflow-0.8.0
root@zsj-ubuntn:~#
用tensorflow输出hello world
oot@zsj-ubuntn:~# python
Python 2.7.12 (default, Nov 20 2017, 18:23:56)
[GCC 5.4.0 20160609] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
>>> hello =tf.constant(´Hello TensorFlow!
File "<stdin>", line 1
hello =tf.constant(´Hello TensorFlow!
^
SyntaxError: invalid syntax
>>> hello =tf.constant(´Hello TensorFlow!´)
File "<stdin>", line 1
hello =tf.constant(´Hello TensorFlow!´)
^
SyntaxError: invalid syntax
>>> hello =tf.constant(´Hello TensorFlow!´)
File "<stdin>", line 1
hello =tf.constant(´Hello TensorFlow!´)
^
SyntaxError: invalid syntax
>>>
>>> hello =tf.constant('Hello TensorFlow!')
>>> sess=tf.Session()
>>> print sess.rum(hello)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'Session' object has no attribute 'rum'
>>> print sess.run(hello)
Hello TensorFlow!
>>> a=ft.constant(10)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'ft' is not defined
>>> a=tf.constant(10)
>>> b=tf.constant(32)
>>> print sess.run(a+b)
42
>>>
折腾了2个晚上才搞定,本来用的centos6 后来下载的ubuntu iso重新安装
- Tensorflow安装记录
- Tensorflow 安装记录
- tensorflow安装记录
- 虚拟机安装tensorflow记录
- tensorflow安装记录
- TensorFlow安装步骤记录
- tensorflow学习记录--1.安装
- Golang版Tensorflow安装记录
- tensorflow安装及注意事项记录
- TensorFlow cpu-only 安装记录
- Centos python36 安装tensorflow记录
- Tensorflow在centos上安装记录
- tensorflow使用记录(一)安装
- 安装keras和tensorflow的一些记录
- 记录 python3.6.1 tensorflow 安装 可视化
- tensorflow+win7 64位安装记录
- TensorFlow 记录
- tensorflow学习记录(一):在windows下的安装
- 2017最新||Genymotion在eclipse和Android studio中的插件添加
- DUBBO简单入门
- TCP原理 I/O 缓存
- JavaScript中闭包设计
- Linux 文件基本属性
- tensorflow安装记录
- c语言 坐标系的转化 数组元素顺序的变换
- Android事件触摸机制
- Python基础-高级特性-切片(Slice)
- Windows程序设计:画刷
- 快速求素数表——埃氏筛法与欧拉筛法
- Ruby 加密(md5,sha1,base64)
- Okhttp3+Rxjava+Retrofit2封装
- Redis入门