-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathunittest.m
95 lines (63 loc) · 1.55 KB
/
unittest.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
clear
randn('seed',1);
rand('seed',1);
N = 64; % number of sources
S = 64; % time points in original sources
J = 96; % number of basis functions for source generation
R = 50; % number of time points in basis functions generating sources
P = S+R-1; % number of selection locations for source generation
Jrows = 48;
save_every = 200;
display_every = 100;
reload_every = 20;
dataid = 'auditorydata3';
dataid = 'polytrode_highpass_P436';
dataid = 'zebramovie';
srate = 15;
datatype = 'vid075';
switch datatype
case 'vid075'
data_root = '../data/vid075-whiteframes';
data_root = '../data/vid075-chunks';
num_chunks = 56;
Nsz = sqrt(N);
Fr = 128;
Fc = 128;
Ft = 64;
buff = 4;
topmargin = 15;
end
mintype_inf = 'minFunc';
mintype_inf = 'minimize';
mintype_inf = 'mintotol';
mintype_inf = 'gd';
mintype_inf = 'lbfgsb';
mintype_lrn = 'minimize';
lrn_searches = 3;
mintype_lrn = 'gd';
opts_lbfgs_a = lbfgs_options('iprint', -1, 'maxits', 20, ...
'factr', 0.01, ...
'cb', @cb_a);
lambda = 0.7;
gamma = 0.001;
gamma = 0;
eta = 0.01;
eta_up = 1.01;
eta_down = 0.99;
eta_log = [];
target_angle = 0.05;
target_angle = 0.01;
paramstr = sprintf('%s_J=%03d_R=%03d_N=%03d_%s', ...
dataid, J, R, N, datestr(now,30));
reinit
num_trials = 1000;
for q = 1:20
sparsenet
phi = timeshift_phi(phi);
end
for q = 1:20
sparsenet
phi = timeshift_phi(phi);
target_angle = target_angle * 0.9;
end
sparsenet