-
Notifications
You must be signed in to change notification settings - Fork 82
/
Copy pathinstall.m
44 lines (38 loc) · 1.34 KB
/
install.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
% Compile libraries and download network
[home_dir, name, ext] = fileparts(mfilename('fullpath'));
warning('ON', 'CCOT:install')
% mtimesx
if exist('external_libs/mtimesx', 'dir') == 7
cd external_libs/mtimesx
mtimesx_build;
cd(home_dir)
else
error('CCOT:install', 'Mtimesx not found.')
end
% PDollar toolbox
if exist('external_libs/pdollar_toolbox/external', 'dir') == 7
cd external_libs/pdollar_toolbox/external
toolboxCompile;
cd(home_dir)
else
warning('CCOT:install', 'PDollars toolbox not found. Clone this submodule if you want to use HOG features. Skipping for now.')
end
% matconvnet
if exist('external_libs/matconvnet/matlab', 'dir') == 7
cd external_libs/matconvnet/matlab
vl_compilenn;
status = movefile('mex/vl_*.mex*');
cd(home_dir)
% donwload network
cd feature_extraction
mkdir networks
cd networks
if ~(exist('imagenet-vgg-m-2048.mat', 'file') == 2)
disp('Downloading the network "imagenet-vgg-m-2048.mat" from "http://www.vlfeat.org/matconvnet/models/imagenet-vgg-m-2048.mat"...')
urlwrite('http://www.vlfeat.org/matconvnet/models/imagenet-vgg-m-2048.mat', 'imagenet-vgg-m-2048.mat')
disp('Done!')
end
cd(home_dir)
else
warning('CCOT:install', 'Matconvnet not found. Clone this submodule if you want to use CNN features. Skipping for now.')
end