您的位置:首页 > 其它

Colorful Image Colorization 的环境配置

2016-07-05 00:45 281 查看
原文链接:https://github.com/richzhang/colorization

步骤基本是按照Installation里的说明

1.安装依赖库

1.1Python相关库

Python libraries (numpy, pyplot, skimage, scipy)。相关命令:

sudo apt-get install python
sudo apt-get install python-numpy
sudo apt-get install python-matplotlib
sudo apt-get install python-scipy


1.2python的ipython notebook

Ubuntu ipython notebook的安装

ipython notebook简介

2.安装caffe

安装步骤主要参考Caffe在Ubuntu 14.04 64bit 下的安装caffe官方安装文档

说明:要根据自己机器的情况在Makefile.config里设置

依赖项

sudo apt-get install libgflags-dev libgoogle-glog-dev liblmdb-dev


安装ATLAS
sudo apt-get install libatlas-base-dev


编译。由于我只用CPU的集成显卡所以注意官方说明里的For CPU-only Caffe, uncomment CPU_ONLY := 1 in Makefile.config. 然后按下列命令编译

cp Makefile.config.example Makefile.config
# Adjust Makefile.config (按照机器情况修改)
make all
make test
make runtest


测试。终端里命令如下。如果没有报错即为安装成功

python
import caffe


3.具体配置

基本按照项目网站的Installation设置

follow项目

git clone -b master --single-branch https://github.com/richzhang/colorization.git[/code] 
cd 到demo目录里
cd ~/colorization/demo


运行ipython notebook
ipython notebook
。会自动提取demo目录里的colorization_demo_v0.ipynb并在浏览器里运行。鼠标点击相应的代码点击运行按钮即为运行相应代码块。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: