MatConvNet is a MATLAB toolbox implementingConvolutional NeuralNetworks (CNNs) for computer vision applications. It is simple,efficient, and can run and learn state-of-the-art CNNs. Severalexample CNNs
are included to classify and encode images.

1. Download MatConvNet

https://github.com/vlfeat/matconvnet

2. Make sure that MATLAB isconfigured to use your compiler.

3. Compiling the CPU support

Open MATLAB and issue the commands:

> cd <MatConvNet>
> addpath matlab
> vl_compilenn

At this point MatConvNet should start compiling. If all goes well, youare ready to use the library. If not, you can try debugging theproblem by running the complation script again in verbose mode:

> vl_compilenn('verbose', 1)

4. Compiling the GPU support

Assuming that there is only a single copy of the CUDA toolkitinstalled in your system and that it matches MATLAB's version, compilethe library with:

> vl_compilenn('enableGpu', true)
 

If you have multiple versions of the CUDA toolkit, or if the scriptcannot find the toolkit for any reason, specify the path to the CUDAtoolkit explicitly. For example, on a Mac this may look like:

> vl_compilenn('enableGpu', true, 'cudaRoot', '/Developer/NVIDIA/CUDA-6.0')

5. Examples

% setup MtConvNet in MATLAB

run matlab/vl_setupnn



% download a pre-trained CNN from the web

urlwrite('http://www.vlfeat.org/sandbox-matconvnet/models/imagenet-vgg-f.mat', ...

  'imagenet-vgg-f.mat') ;

net = load('imagenet-vgg-f.mat') ;



% obtain and preprocess an image

im = imread('peppers.png') ;

im_ = single(im) ; % note: 255 range

im_ = imresize(im_, net.normalization.imageSize(1:2)) ;

im_ = im_ - net.normalization.averageImage ;



% run the CNN

res = vl_simplenn(net, im_) ;



% show the classification result

scores = squeeze(gather(res(end).x)) ;

[bestScore, best] = max(scores) ;

figure(1) ; clf ; imagesc(im) ;

title(sprintf('%s (%d), score %.3f',...

net.classes.description{best}, best, bestScore)) ;

reference url:

http://www.vlfeat.org/matconvnet/mfiles/vl_compilenn/

http://www.vlfeat.org/matconvnet/install/

http://www.vlfeat.org/matconvnet/pretrained/

Ubuntu15.04 + Matlab2014a + MatConvNet install and compile的更多相关文章

  1. Install and Compile MatConvNet: CNNs for MATLAB --- Deep Learning framework

    Install and Compile MatConvNet: CNNs for MATLAB --- Deep Learning framework 2017-04-18  10:19:35 If ...

  2. 在centos7 ubuntu15.04 上通过bosh-lite 搭建单机环境cloudfoundry

    Bosh-lite简介       bosh-lite 是一个单机部署cloudfoundry的实验性工具,用于开发人员做poc 验证.Bosh-lite目前支持仅MAC OS X和Linux系统.B ...

  3. windows下安装ubuntu15.04

    本文主要介绍windows下安装ubuntu15.04,对与其他的版本也是适用的.现在要讲的是一种最简单ubuntu的安装方式. 1软件下载 1.磁盘分区工具DiskGenius 2.启动项修改工具E ...

  4. ubuntu15.04下安装docker

    ​##获得更多资料欢迎进入我的网站或者 csdn或者博客园 最近听说docker很火,不知道什么东西,只知道是一个容器,可以跨平台.闲来无事,我也来倒弄倒弄.本文主要介绍:ubuntu下的安装,以及基 ...

  5. U盘制作Ubuntu15.04启动盘失败

    先用ubuntu15.04光盘在已有xp的电脑上安装成功​ 随后在Ubuntu安装labview说glibc没安装​ 但是ldd --version显示是安装的新版的​ 后来怀疑是86_64的原因​ ...

  6. Ubuntu15.04上为火狐浏览器安装Adobe Flash Player插件

    前言:最新版的ubuntu好像没有flashplayer,而且更新源也无法更新成功,找些资料终于发现 这个需要自己手动配置.由于flashplayer无法安装,导致视频,百度上传等功能都无法使用: 安 ...

  7. 用U盘安装Ubuntu15.04

    用UltraISO刻录Ubuntu15.04到U盘安装,出现:Failed to load idlinux.c32错误,解决办法如下: source url: http://www.ubuntukyl ...

  8. 31. Ubuntu15.04系统中如何启用、禁用客人会话

    https://jingyan.baidu.com/article/046a7b3edf9639f9c27fa995.html 31. Ubuntu15.04系统中如何启用.禁用客人会话 听语音 | ...

  9. U盘安装Ubuntu15.04 出现boot failed: please change disks and press a key to continue

    1.根据国内的教程,用Ultraiso制作了一个Ubuntu15.04的U盘启动盘,在装系统的时候提示如下错误:boot failed: please change disks and press a ...

随机推荐

  1. Bootstrap3 表单-输出内联表单

    为 <form> 元素添加 .form-inline 类可使其内容左对齐并且表现为 inline-block 级别的控件.只适用于视口(viewport)至少在 768px 宽度时(视口宽 ...

  2. Sublime Text 3下C/C++开发环境搭建

    Sublime Text 3下C/C++开发环境搭建 之前在Linux Mint 17一周使用体验中简单介绍过Sublime Text. 1.Sublime Text 3安装 Ubuntu.Linux ...

  3. java 随机数高效生成

    分享牛,分享牛原创.近期去面试经常被问到java如何生产随机数,以及生成很大的字符串保证不能重复,还要考虑性能,之前本人面试别人的时候,可能不会问这个问题.既然这个java随机数问题经常被问到,那咱们 ...

  4. solr界面

    1.1 界面功能介绍 1.1.1 Analysis

  5. Android对话框Dialog深度剖析

    对话框 对话框是提示用户作出决定或输入额外信息的小窗口. 对话框不会填充屏幕,通常用于需要用户采取行动才能继续执行的模式事件. 对话框设计 Dialog 类是对话框的基类,但您应该避免直接实例化 Di ...

  6. Dynamics CRM2016 Web API之Expand related entities & $ref & $count

    本篇介绍两个关于1:N关系中通过主实体取关联子实体的api,这两个api会经常被用到而且比原来的odata方式更加方便,之前如果我们要取主实体下所有的关联实体的记录都是通过Retrieve Multi ...

  7. SKSpriteNode对象初始化在iPhone 6 plus中显示不正确的分析及解决

    一个SpriteKit项目在其他设备上运行都无问题(无论是真机或是模拟器),但是在iPhone6 Plus上会出现精灵对象纹理被过度放大的现象: 从上图中大家可以看到无论是主角或是道具球都过大了. 看 ...

  8. Impala中的代码生成技术

    Cloudera Impala是一种为Hadoop生态系统打造的开源MPP(massive parallel processing)数据库,它主要为分析型查询负载而设计,而非OLTP.Impala能最 ...

  9. java虚拟机 jvm 出入java栈 栈空间内存分配

    java栈空间是一块线程私有的内存空间,java堆和程序数据密切相关,那么java栈就是和线程执行密切相关.线程最基本的执行行为就是函数的调用.每次函数调用其实是通过java栈传递数据的. 数据结构中 ...

  10. 关于C语言中输出格式

    刷OJ题的时候,经常发现题目的输入输出会有相应的特殊要求,像位宽和位域输出就比较常见. 位宽:如果长度不足位宽大小,则默认情况下前面补空格. 标志位:有+有- 默认格式为左对齐. 在位宽前面加0,补全 ...