Commit 10b6bd97 authored by James Desjardins's avatar James Desjardins
Browse files

Updated various config files and scripts to have James' defaults.

Prepping for the notion of moving between scratch and project as well.
parent feb528d3
......@@ -9,11 +9,11 @@ remote_user_name
remote_exec_host
graham.computecanada.ca
remote_project_archive
dtn.sharcnet.ca:~/projects/group_name/user_name/project_name/
graham.computecanada.ca:/project/group_name/user_name/project_name/
remote_project_work
dtn.sharcnet.ca:~/projects/group_name/user_name/project_name/
graham.computecanada.ca:/scratch/group_name/user_name/project_name/
remote_dependency
dtn.sharcnet.ca:~/projects/group_name/user_name/project_name/bids/code/lossless/dependencies
graham.computecanada.ca:/scratch/group_name/user_name/project_name/bids/code/lossless/dependencies
mount_archive
remote_archive
mount_work
......
log
bids/derivatives/lossless/log
local_project
local_dependency
bids/code/lossless/dependencies
remote_user_name
jdesjard
remote_exec_host
cedar.computecanada.ca
remote_project_archive
cedar.computecanada.ca:/project/projects/def-jdesjard/git_face_13/
remote_project_work
cedar.computecanada.ca:/project/projects/def-jdesjard/git_face_13/
remote_dependency
cedar.computecanada.ca:/project/projects/def-jdesjard/git_face_13/bids/code/lossless/dependencies
mount_archive
remote_archive
mount_work
remote_work
misc
[config_dir] bids/code/lossless/config
[data_dir]
[script_dir] bids/code/lossless/scripts
system_cmds
sshfs [remote_user_name]@[remote_project_archive] [cd]/[mount_archive]
sshfs [remote_user_name]@[remote_project_work] [cd]/[mount_work]
meld [local_project]/analysis [cd]/[mount_work]/analysis &
meld [local_project]/analysis [cd]/[mount_archive]/analysis [cd]/[mount_work]/analysis &
fusermount -u [cd]/[mount_archive]
fusermount -u [cd]/[mount_work]
......@@ -3,37 +3,37 @@ file_name
exec_func
ef_sbatch
replace_string
[in_path],analysis/data/1_init
[in_path],[]
[aref_trim],30
[recur_sec],1
[limit_sec],[0 1]
[sd_t_meth],'na'
[sd_t_vals],'[.15 .85]'
[sd_t_o],6
[sd_t_meth],na
[sd_t_vals],[.15 .85]
[sd_t_o],3
[sd_t_p],.2
[sd_t_pad],1
[sd_ch_meth],'q'
[sd_ch_meth],q
[sd_ch_vals],[.15 .85]
[sd_ch_o],6
[sd_ch_o],3
[sd_ch_p],.2
[ref_loc_file],bids/code/lossless/misc/standard_1020_bucanl19.elc
[low_bound_hz],1
[high_bound_hz],30
[save_f_res],1
[n_nbr_ch],3
[r_ch_meth],'q'
[r_ch_meth],q
[r_ch_vals],[.15,.85]
[r_ch_o],3
[r_ch_p],.2
[bridge_trim],40
[bridge_z],6
[n_nbr_t],3
[r_t_meth],'q'
[r_t_meth],q
[r_t_vals],[.15 .85]
[r_t_o],3
[r_t_p],.2
[min_gap_ms],2000
[out_path],analysis/data/2_preproc
[out_path],bids/derivatives/lossless
[amica_param_file],bids/code/lossless/misc/amica15_default.param
[amica_threads_s02],8
order
......
......@@ -3,15 +3,15 @@ file_name
exec_func
ef_sbatch
replace_string
[in_path],analysis/data/2_preproc
[in_path],bids/derivatives/lossless
[recur_sec],1
[limit_sec],[0 1]
[sd_t_meth],'q'
[sd_t_meth],q
[sd_t_vals],[.15 .85]
[sd_t_o],3
[sd_t_p],.2
[min_gap_ms],2000
[out_path],analysis/data/2_preproc
[out_path],bids/derivatives/lossless
[amica_param_file],bids/code/lossless/misc/amica_default.param
[amica_threads_s07_08_09],8
order
......
......@@ -3,14 +3,16 @@ file_name
exec_func
ef_sbatch
replace_string
[in_path],bids/derivatives/lossless
[recur_sec],1
[limit_sec],[0 1]
[sd_t_meth],'q'
[sd_t_meth],q
[sd_t_vals],[.15 .85]
[sd_t_o],3
[sd_t_p],.2
[min_gap_ms],2000
[icr_crit],0.05
[out_path],bids/derivatives/lossless
order
[5 4]
session_init
......
......@@ -37,9 +37,9 @@
% save_diff = [savediff] YES if you want to save the filter residuals (Default: NO)
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
if ~exist('bids/derivatives/lossless/[/,1,batch_dfn,/,-1]','dir');
disp('Making directory bids/derivatives/lossless/[/,1,batch_dfn,/,-1]');
mkdir bids/derivatives/lossless/[/,1,batch_dfn,/,-1]
if ~exist('[out_path]/[/,1,batch_dfn,/,-1]','dir');
disp('Making directory [out_path]/[/,1,batch_dfn,/,-1]');
mkdir [out_path]/[/,1,batch_dfn,/,-1]
end
%% LOAD DATASET
......@@ -86,12 +86,12 @@ logging_log('INFO', 'CALCULATED EPOCH SD...');
% Create the window criteria vector for flagging ch_sd time_info...
logging_log('INFO', 'Assessing window data sd distributions...')
if strcmp([sd_t_meth],'na');
if strcmp('[sd_t_meth]','na');
flag_sd_t_inds=[];
else
[~,flag_sd_t_inds]=marks_array2flags(data_sd_t, ...
'flag_dim','col', ...
'init_method',[sd_t_meth], ...
'init_method','[sd_t_meth]', ...
'init_vals',[sd_t_vals], ...
'init_crit',[sd_t_o], ...
'flag_method','fixed', ...
......@@ -132,7 +132,7 @@ logging_log('INFO', 'CALCULATED CHAN SD...');
logging_log('INFO', 'Assessing window data sd distributions...')
[~,flag_sd_ch_inds]=marks_array2flags(data_sd_ch, ...
'flag_dim','row', ...
'init_method',[sd_ch_meth], ...
'init_method','[sd_ch_meth]', ...
'init_vals',[sd_ch_vals], ...
'init_crit',[sd_ch_o], ...
'flag_method','fixed', ...
......@@ -181,14 +181,14 @@ EEG.setname = 'filtHP';
EEG = eeg_checkset( EEG );
if [save_f_res]
% Save high pass filter residual data array
logging_log('DEBUG', 'Saving file: bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_hpd.mat...');
logging_log('DEBUG', 'Saving file: [out_path]/[/,1,batch_dfn,_,-1]_hpd.mat...');
data = pre_hp_data - EEG.data;
try OCTAVE_VERSION;
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_hpd.mat','data');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_hpd.mat','data');
catch
save('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_hpd.mat','data');
save('[out_path]/[/,1,batch_dfn,_,-1]_hpd.mat','data');
end
logging_log('DEBUG', 'TIME TO: SAVE bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_hpd.mat FILE...');
logging_log('DEBUG', 'TIME TO: SAVE [out_path]/[/,1,batch_dfn,_,-1]_hpd.mat FILE...');
end
logging_log('INFO', 'FILTERED HIGH PASS...');
clear pre_hp_data
......@@ -205,14 +205,14 @@ EEG.setname = 'filtLP';
EEG = eeg_checkset( EEG );
if [save_f_res]
% Save high pass filter residual data array
logging_log('DEBUG', 'Saving file: bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_lpd.mat...');
logging_log('DEBUG', 'Saving file: [out_path]/[/,1,batch_dfn,_,-1]_lpd.mat...');
data = pre_lp_data - EEG.data;
try OCTAVE_VERSION;
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_lpd.mat','data');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_lpd.mat','data');
catch
save('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_lpd.mat','data');
save('[out_path]/[/,1,batch_dfn,_,-1]_lpd.mat','data');
end
logging_log('DEBUG', 'TIME TO: SAVE bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_lpd.mat FILE...');
logging_log('DEBUG', 'TIME TO: SAVE [out_path]/[/,1,batch_dfn,_,-1]_lpd.mat FILE...');
end
logging_log('INFO', 'FILTERED LOW PASS...');
clear pre_lp_data
......@@ -240,7 +240,7 @@ epoch_inds = marks_label2index(EEG.marks.time_info,{'manual'},'indexes','invert'
logging_log('INFO', 'Assessing channel r distributions criteria...')
[~,flag_r_ch_inds]=marks_array2flags(data_r_ch, ...
'flag_dim','row', ...
'init_method',[r_ch_meth], ...
'init_method','[r_ch_meth]', ...
'init_vals',[r_ch_vals], ...
'init_dir','neg', ...
'init_crit',[r_ch_o], ...
......@@ -323,7 +323,7 @@ logging_log('INFO', 'CALCULATED NEAREST NEIGHBOUR R VALUES...');
logging_log('INFO', 'Assessing epoch r distributions criteria...')
[~,flag_r_t_inds]=marks_array2flags(data_r_t, ...
'flag_dim','col', ...
'init_method',[r_t_meth], ...
'init_method','[r_t_meth]', ...
'init_vals',[r_t_vals], ...
'init_dir','neg', ...
'init_crit',[r_t_o], ...
......@@ -361,14 +361,10 @@ logging_log('INFO', 'COMBINED MARKS STRUCTURE INTO MANUAL FLAGS...');
%% SAVE sa.set FILE
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
logging_log('INFO', 'Saving file: [batch_dfn,_,-1]_sa.set...');
if ~exist('bids/derivatives/lossless/[/,1,batch_dfn,/,-1]','dir');
if strncmpi('/','[batch_dfn,/,-1]',1);
mkdir('bids/derivatives/lossless/[/,1,batch_dfn,/,-1]');
else
mkdir('bids/derivatives/lossless/[batch_dfn,/,-1]');
end
if ~exist('[out_path]/[/,1,batch_dfn,/,-1]','dir');
mkdir('[out_path]/[/,1,batch_dfn,/,-1]');
end
EEG = pop_saveset( EEG, 'filename','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_sa.set');
EEG = pop_saveset( EEG, 'filename','[out_path]/[/,1,batch_dfn,_,-1]_sa.set');
logging_log('INFO', 'SAVED sa FILE...');
%%%-----------------------------------------------------------------------
......@@ -387,31 +383,31 @@ logging_log('INFO', 'TIME TO: PURGE DATA...');
EEG.data = double(EEG.data);
% Save the SA purge file
logging_log('INFO',sprintf('%s','Saving file: bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_sa_purge.set...'));
EEG = pop_saveset( EEG, 'filename','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_sa_purge.set');
logging_log('INFO',sprintf('%s','Saving file: [out_path]/[/,1,batch_dfn,_,-1]_sa_purge.set...'));
EEG = pop_saveset( EEG, 'filename','[out_path]/[/,1,batch_dfn,_,-1]_sa_purge.set');
% Save diagnostic arrays
try OCTAVE_VERSION;
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_sd_t.mat','data_sd_t');
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_sd_ch.mat','data_sd_ch');
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_r_ch.mat','data_r_ch');
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_r_t.mat','data_r_t');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_data_sd_t.mat','data_sd_t');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_data_sd_ch.mat','data_sd_ch');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_data_r_ch.mat','data_r_ch');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_data_r_t.mat','data_r_t');
catch
save('bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_sd_t.mat','data_sd_t');
save('bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_sd_ch.mat','data_sd_ch');
save('bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_r_ch.mat','data_r_ch');
save('bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_data_r_t.mat','data_r_t');
save('[out_path]/[/,1,batch_dfn,_,-1]_data_sd_t.mat','data_sd_t');
save('[out_path]/[/,1,batch_dfn,_,-1]_data_sd_ch.mat','data_sd_ch');
save('[out_path]/[/,1,batch_dfn,_,-1]_data_r_ch.mat','data_r_ch');
save('[out_path]/[/,1,batch_dfn,_,-1]_data_r_t.mat','data_r_t');
end
% Save the AMICA parameter file
swapstr = file_strswap('[amica_param_file]', ...
'[repstr_fdt_fname]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_sa_purge.fdt', ...
'[repstr_outpath]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_init', ...
'[repstr_fdt_fname]','[out_path]/[/,1,batch_dfn,_,-1]_sa_purge.fdt', ...
'[repstr_outpath]','[out_path]/[/,1,batch_dfn,_,-1]_amicaout_init', ...
'[repstr_nbchan]', num2str(EEG.nbchan), ...
'[repstr_pnts]', sprintf('%12.0f',EEG.pnts), ...
'[repstr_tpp]', '[amica_threads_s02]', ...
'[repstr_pca]', num2str(EEG.nbchan));
fidparam = fopen('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_init.param','w');
fidparam = fopen('[out_path]/[/,1,batch_dfn,_,-1]_init.param','w');
fprintf(fidparam,'%s',swapstr);
fclose(fidparam);
......@@ -419,8 +415,8 @@ fclose(fidparam);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Needed for MPI jobs on cluster only in order to prevent a race effect bug.
[~] = rmdir('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_init','s');
mkdir bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_init;
[~] = rmdir('[out_path]/[/,1,batch_dfn,_,-1]_amicaout_init','s');
mkdir [out_path]/[/,1,batch_dfn,_,-1]_amicaout_init;
logging_log('INFO', 'Created Amica Output Folder');
logging_log('INFO', 'Scalpart complete');
......
......@@ -27,7 +27,7 @@
% Load the EEG datafile
logging_log('INFO', 'Loading set file: [batch_dfn,_,-1]_sa.set...');
tic;
EEG = pop_loadset('filepath','[batch_dfp]','filename','/derivatives/lossless/[/,1,batch_dfn,_,-1]_sa.set');
EEG = pop_loadset('filepath','[in_path]','filename','[/,1,batch_dfn,_,-1]_sa.set');
EEG = eeg_checkset( EEG );
logging_log('INFO', 'TIME TO: LOAD DATASET...');
toc
......@@ -38,7 +38,7 @@ icatimeind = find(~EEG.marks.time_info(1).flags);
% Load AMICA Model 1
tic;
EEG.amica(1).models=loadmodout15('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_init');
EEG.amica(1).models=loadmodout15('[out_path]/[/,1,batch_dfn,_,-1]_amicaout_init');
EEG.icaweights=EEG.amica(1).models.W;
EEG.icasphere=EEG.amica(1).models.S(1:EEG.amica(1).models.num_pcs,:);
EEG=eeg_checkset(EEG);
......@@ -93,7 +93,7 @@ epoch_inds=marks_label2index(EEG.marks.time_info,{'manual'},'indexes','invert','
logging_log('INFO', 'Assessing window icaact sd distributions...')
[~,flag_t_inds]=marks_array2flags(icaact_sd1_t, ...
'flag_dim','col', ...
'init_method',[sd_t_meth], ...
'init_method','[sd_t_meth]', ...
'init_vals',[sd_t_vals], ...
'init_crit',[sd_t_o], ...
'flag_method','fixed', ...
......@@ -138,7 +138,7 @@ toc
tic;
logging_log('INFO', 'Saving file: [batch_dfn,_,-1]_compart_data.set...');
EEG = pop_saveset( EEG, 'filename','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_compart_data.set');
EEG = pop_saveset( EEG, 'filename','[out_path]/[/,1,batch_dfn,_,-1]_compart_data.set');
logging_log('INFO', 'TIME TO: SAVE compart_data FILE...');
toc;
%% SAVE compart_data_purge FILE
......@@ -168,13 +168,13 @@ toc;
% Saving File to enter next ICAs
logging_log('INFO', 'Saving the Param files');
sprintf('%s','Saving file: [batch_dfn,_,-1]_compart_data_purge.set...\n');
EEG = pop_saveset( EEG, 'filename','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_compart_data_purge.set');
EEG = pop_saveset( EEG, 'filename','[out_path]/[/,1,batch_dfn,_,-1]_compart_data_purge.set');
% Save diagnostic arrays
try OCTAVE_VERSION;
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_icaact_sd1_t.mat','icaact_sd1_t');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_icaact_sd1_t.mat','icaact_sd1_t');
catch
save('bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_icaact_sd1_t.mat','icaact_sd1_t');
save('[out_path]/[/,1,batch_dfn,_,-1]_icaact_sd1_t.mat','icaact_sd1_t');
end
%% SAVE AMICA PARAMETER FILES
......@@ -186,39 +186,39 @@ tic;
% A
% Saving AMICA Parameter File
swapstr=file_strswap('[amica_param_file]', ...
'[repstr_fdt_fname]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_compart_data_purge.fdt', ...
'[repstr_outpath]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_A', ...
'[repstr_fdt_fname]','[out_path]/[/,1,batch_dfn,_,-1]_compart_data_purge.fdt', ...
'[repstr_outpath]','[out_path]/[/,1,batch_dfn,_,-1]_amicaout_A', ...
'[repstr_nbchan]', num2str(EEG.nbchan), ...
'[repstr_pnts]', sprintf('%12.0f',EEG.pnts), ...
'[repstr_tpp]', '[amica_threads_s07_08_09]', ...
'[repstr_pca]', num2str(EEG.nbchan));
fidparam=fopen('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_A.param','w');
fidparam=fopen('[out_path]/[/,1,batch_dfn,_,-1]_A.param','w');
fprintf(fidparam,'%s',swapstr);
fclose(fidparam);
% B
% Saving AMICA Parameter File
swapstr=file_strswap('[amica_param_file]', ...
'[repstr_fdt_fname]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_compart_data_purge.fdt', ...
'[repstr_outpath]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_B', ...
'[repstr_fdt_fname]','[out_path]/[/,1,batch_dfn,_,-1]_compart_data_purge.fdt', ...
'[repstr_outpath]','[out_path]/[/,1,batch_dfn,_,-1]_amicaout_B', ...
'[repstr_nbchan]', num2str(EEG.nbchan), ...
'[repstr_pnts]', sprintf('%12.0f',EEG.pnts), ...
'[repstr_tpp]', '[amica_threads_s07_08_09]', ...
'[repstr_pca]', num2str(EEG.nbchan));
fidparam=fopen('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_B.param','w');
fidparam=fopen('[out_path]/[/,1,batch_dfn,_,-1]_B.param','w');
fprintf(fidparam,'%s',swapstr);
fclose(fidparam);
% C
% Saving AMICA Parameter File
swapstr=file_strswap('[amica_param_file]', ...
'[repstr_fdt_fname]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_compart_data_purge.fdt', ...
'[repstr_outpath]','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_C', ...
'[repstr_fdt_fname]','[out_path]/[/,1,batch_dfn,_,-1]_compart_data_purge.fdt', ...
'[repstr_outpath]','[out_path]/[/,1,batch_dfn,_,-1]_amicaout_C', ...
'[repstr_nbchan]', num2str(EEG.nbchan), ...
'[repstr_pnts]', sprintf('%12.0f',EEG.pnts), ...
'[repstr_tpp]', '[amica_threads_s07_08_09]', ...
'[repstr_pca]', num2str(EEG.nbchan));
fidparam=fopen('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_C.param','w');
fidparam=fopen('[out_path]/[/,1,batch_dfn,_,-1]_C.param','w');
fprintf(fidparam,'%s',swapstr);
fclose(fidparam);
......@@ -226,14 +226,14 @@ fclose(fidparam);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Needed for MPI jobs on cluster. Otherwise race effect will occur.
[~] = rmdir('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_A','s');
[~] = rmdir('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_B','s');
[~] = rmdir('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_C','s');
[~] = rmdir('[out_path]/[/,1,batch_dfn,_,-1]_amicaout_A','s');
[~] = rmdir('[out_path]/[/,1,batch_dfn,_,-1]_amicaout_B','s');
[~] = rmdir('[out_path]/[/,1,batch_dfn,_,-1]_amicaout_C','s');
mkdir 'bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_A';
mkdir 'bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_B';
mkdir 'bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_C';
mkdir '[out_path]/[/,1,batch_dfn,_,-1]_amicaout_A';
mkdir '[out_path]/[/,1,batch_dfn,_,-1]_amicaout_B';
mkdir '[out_path]/[/,1,batch_dfn,_,-1]_amicaout_C';
logging_log('INFO', 'TIME TO: CREATE AMICA PARAMETER FILES...');
toc
......
......@@ -21,7 +21,7 @@
logging_log('INFO', 'Loading set file: [batch_dfn,_,-1]_compart_data.set...');
tic;
EEG = pop_loadset('filepath','[batch_dfp]','filename','/derivatives/lossless/[/,1,batch_dfn,_,-1]_compart_data.set');
EEG = pop_loadset('filepath','[in_path]','filename','[/,1,batch_dfn,_,-1]_compart_data.set');
EEG = eeg_checkset( EEG );
logging_log('INFO', 'TIME TO: LOAD DATASET...');
toc
......@@ -32,7 +32,7 @@ EEG.icachansind = marks_label2index(EEG.marks.chan_info,{'manual','rank'},'indic
% Load Amica A
logging_log('INFO', 'Loading Amica ABC...');
tic;
EEG.amica(2).models=loadmodout15('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_A');
EEG.amica(2).models=loadmodout15('[in_path]/[/,1,batch_dfn,_,-1]_amicaout_A');
EEG.icaweights=EEG.amica(2).models.W;
EEG.icasphere=EEG.amica(2).models.S(1:EEG.amica(2).models.num_pcs,:);
......@@ -52,9 +52,9 @@ EEG.icawinv = [];
EEG.icawinv = pinv(EEG.icaweights * EEG.icasphere);
% Load Amica B
EEG.amica(3).models=loadmodout15('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_B');
EEG.amica(3).models=loadmodout15('[in_path]/[/,1,batch_dfn,_,-1]_amicaout_B');
% Load Amica C
EEG.amica(4).models=loadmodout15('bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_amicaout_C');
EEG.amica(4).models=loadmodout15('[in_path]/[/,1,batch_dfn,_,-1]_amicaout_C');
logging_log('INFO', 'TIME TO: LOAD ICA ABC INFO...');
toc
......@@ -157,7 +157,7 @@ epoch_inds=marks_label2index(EEG.marks.time_info,{'manual'},'indexes','invert','
logging_log('INFO', 'Assessing window icaact sd distributions...')
[~,flag_sd_t_inds]=marks_array2flags(icaact_sd2_t, ...
'flag_dim','col', ...
'init_method',[sd_t_meth], ...
'init_method','[sd_t_meth]', ...
'init_vals',[sd_t_vals], ...
'init_crit',[sd_t_o], ...
'flag_method','fixed', ...
......@@ -193,7 +193,7 @@ tic;
logging_log('INFO', 'Assessing window icaact sd distributions...')
[~,flag_ta_t_inds]=marks_array2flags(icaact_ta_t, ...
'flag_dim','col', ...
'init_method',[sd_t_meth], ...
'init_method','[sd_t_meth]', ...
'init_vals',[sd_t_vals], ...
'init_crit',[sd_t_o], ...
'flag_method','fixed', ...
......@@ -230,7 +230,7 @@ logging_log('INFO', 'TIME TO: CALCULATE BETA ICAACT POWER...');
logging_log('INFO', 'Assessing window icaact sd distributions...')
[~,flag_b_t_inds]=marks_array2flags(icaact_b_t, ...
'flag_dim','col', ...
'init_method',[sd_t_meth], ...
'init_method','[sd_t_meth]', ...
'init_vals',[sd_t_vals], ...
'init_crit',[sd_t_o], ...
'flag_method','fixed', ...
......@@ -391,17 +391,17 @@ toc
%% SAVE LOSSLESS DERIVATIVE *_eeg.set FILE (same name as the input file from the
% BIDS root directory [but located in the derivatives/lossless directory]).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
logging_log('INFO','Saving set file: bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_eeg.set...');
logging_log('INFO','Saving set file: [out_path]/[/,1,batch_dfn,_,-1]_eeg.set...');
tic;
EEG = pop_saveset( EEG, 'filename','bids/derivatives/lossless/[/,1,batch_dfn,_,-1]_eeg.set');
EEG = pop_saveset( EEG, 'filename','[out_path]/[/,1,batch_dfn,_,-1]_eeg.set');
logging_log('INFO','TIME TO: SAVE DIP DATA SET...');
toc
% Save diagnostic arrays
try OCTAVE_VERSION;
save('-mat7-binary','bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_icaact_sd1_t.mat','icaact_sd2_t');
save('-mat7-binary','[out_path]/[/,1,batch_dfn,_,-1]_icaact_sd1_t.mat','icaact_sd2_t');
catch
save('bids/derivatives/lossless/[/,1,batch_dfn,.,-1]_icaact_sd1_t.mat','icaact_sd2_t');
save('[out_path]/[/,1,batch_dfn,_,-1]_icaact_sd1_t.mat','icaact_sd2_t');
end
logging_log('INFO', 'Scheduler: [scheduler]');
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment