记录:Ubuntu 16.04下安装tensorflow和 keras (跑keras 搭建的CNN网络的手写数据库例子)

1.安装tensorflow。

pip install https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-1.8.0-cp27-cp27mu-manylinux1_x86_64.whl 

2.安装protobuf。

sudo pip install protobuf 

测试是否成功:

python
import google.protobuf

3.安装keras

sudo pip install keras

测试安装keras是否成功:

python
from keras.models import Sequential
model = Sequential()

4.我发现jupyter notebook 还挺好用的 装个ipython 和jupyter book吧

pip install ipython
pip install jupyter  

测试:jupyter notebook

在阿里云服务器上安装这些感觉还是很顺利啊!

我再去Github上下载了keras的源码,网址如下:
https://github.com/keras-team/keras

下载以后 上传到我的服务器

下载以后运行示例,在examples文件夹里

 cd keras-master/
 cd examples/
python mnist_cnn.py

你可能感兴趣的:(记录:Ubuntu 16.04下安装tensorflow和 keras (跑keras 搭建的CNN网络的手写数据库例子))