-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBATCH_IB_LUMINANCE.m
191 lines (127 loc) · 3.83 KB
/
BATCH_IB_LUMINANCE.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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
function BATCH_IB_LUMINANCE(delay_in, lum_in, weight_in, part_in)
pars.delay = delay_in;
pars.weight = weight_in;
pars.dist = 25;
pars.luminance = lum_in;
pars.noise = 20;
%%%%% CONTAINER SCRIPT, updated 2014 Alex Cope
%%% LOAD STANDARD PARAMETERS
DEFAULTS
%% MODIFY WEIGHTS FOR TESTING
%%% TRICKS
comp_input_from_fovea = false;
more_input_from_periphery = false;
more_phasic_in_periphery = false;
fixation_nogo_on = false;
input_normalised = false;
less_input_from_fovea = false;
nogo_on = false;
fovea_striatum_compensation = false;
fovea_striatum_comp_v2 = true;
fix_passthough = false;
fovea_STN_compensation = false;
%%%
jon_model = false;
degrees_to_edge = 24;
hack_model = true;
STIM_NOISE = 10;
FIXATION_STRENGTH = 0.5;
STIM_STRENGTH = pars.luminance;
BACKGROUND_NOISE = 0.3;
big_noise = false;
BIG_NOISE_WEIGHT = 0.035;
SC_SUPERIOR_TO_THAL = pars.weight;%2.0;
SC_SUPERIOR_TO_SC_BUILDUP = 20.0;
SIG_NOISE = 0;%30.0;
SIG_NOISE = pars.noise;%10;%20
long_delay = 1.5;
% 0 is crosses, 1 is distance scale gaussian blobs
%%%
%% Flags:
scopesOn = 0;
scopeOn = 0; %% vis scopes
concerto = false;
logging_on = 20; % 0 = none, 1 = light, 2 = heavy, higher numbers are task specific
%% Scopes:
%scopeTarg = 'SC_buildup/out>out';
scopeTarg = 'FEF/out>out';
scopeTarg2 = 'BG/STN/out>out';
scopeTargA = 'SC_buildup/out>out';
scopeTargB = 'BG/SNr/out>out';
visModel = 'digit';
taskType = 'JON';
%% exePars
executionStop = 4.2;
fS = 1000;
num_samples = fS * executionStop;
%% Bias:
%%%%%% set some interesting desire levels for features
if strcmp(visModel, 'digit')
num_channels = 10;
else
num_channels = 6;
end
D2_BIAS = 0.0;
DOPAMINE = 0.2;
%% Loop start:
for biasMode=1:1
if pars.delay < 0
minus = 'm';
else
minus = '';
end
runString = ['moo_' minus num2str(abs(pars.luminance*10)) '_' num2str(abs(pars.delay*10)) '_' num2str(pars.weight*100) '_' num2str(part_in)];
runString
eval(['fileStr = ''data' runString ''';']);
fileStr
eval([fileStr ' = [];']);
if (1==1)%exist(['./dataTemp/' fileStr '.mat']) == 0)
for repeatRun = 1:20%40
repeatRun
STIM_STRENGTH = pars.luminance;
delay_amount = pars.delay;
% end sim when we make a saccade, target set in STIMS.m
targetMode = 2;
targetVals = {};
targetVals{1} = [pars.dist, 0, 4];
targetVals{2} = single([pars.dist, 0, 0.001]);
%%%%%%%%%%% RUN IT
overrideName = ['sys_' runString];
RUN_MODEL
% figure(3);
% hold on;
% plot(squeeze(out.orient.FEF.out.out(30,38,:)));
% plot(squeeze(out.orient.FEF.out.out(1,38,:)));
%% ANALYSE
timeTaken = out.orient.SG.target(2,end) - long_delay;
if timeTaken > 0 && out.orient.SG.target(1,end) == 1;
eval([fileStr ' = [' fileStr '; timeTaken];']);
timeTaken
end
timeTaken
%% Loop end:
% if mod(repeatRun,20)==0
% figure(2);
% hold off;
% eval(['hist(' fileStr ',0:0.01:1);']);
% axis([0.1 0.5 0 80]);
% end
end
% save data
% eval(['save ./dataTemp/' fileStr ' ' fileStr ';']);
else
exit2 = 'data exists'
end
eval(['save ./dataTemp/' fileStr ' ' fileStr ';']);
% eval(['out = ' fileStr ';']);
% figure(20);
% subplot(1,17,parsNum);
% hold off
% imagesc(out.orient.FEF_input.out.out(:,:,1000)); colorbar;
% hold on
% plot(squeeze(out.orient.FEF.out.out(5,30,:)),'r');
% plot(squeeze(out.orient.BG.SNr.out.out(30,39,:)),'g');
end
% sys.orient.FEF_input.act.state
exit
end