diff --git a/bashscripts/runOnEciton.bash b/bashscripts/runOnEciton.bash index 5966ef3..0ff9df6 100755 --- a/bashscripts/runOnEciton.bash +++ b/bashscripts/runOnEciton.bash @@ -7,4 +7,4 @@ #sed 's,\./,,g' -i dirs.txt #sed '/^[[:blank:]]*$/d' -i dirs.txt -matlab < /home/hohlochj/masterarbeit/usedMcode/callAll.m > /nfs/wsi/ti/messor/hohlochj/log/$(date +%y-%m-%d--%T)-allDefault3Syn.log +matlab < /home/hohlochj/masterarbeit/usedMcode/callAll.m > /nfs/wsi/ti/messor/hohlochj/log/$(date +%y-%m-%d--%T)-EEGtoEMGandAutoencToKin.log diff --git a/usedMcode/callAll.m b/usedMcode/callAll.m index 366eb56..372c5cf 100644 --- a/usedMcode/callAll.m +++ b/usedMcode/callAll.m @@ -7,7 +7,7 @@ noSynergies=3; allSubjects=true; %run all subjects and days or only one random day for one random subject -name='EEGtoEMG'; %suffix for the output, has to be valid name for file (no space, /, ...) +name='EEGtoEMGandAutoencToKin'; %suffix for the output, has to be valid name for file (no space, /, ...) windowEMG=0.2; windowEEG=1; shiftEMG=0.05; diff --git a/usedMcode/ridgeCV.m b/usedMcode/ridgeCV.m index 7311cd3..6115e9f 100644 --- a/usedMcode/ridgeCV.m +++ b/usedMcode/ridgeCV.m @@ -10,7 +10,7 @@ elseif strcmp(data,'LF') eeg=true; trainingData=trainingDataEEGlf(eegOffset+1:end,:); - elseif strcmp(goal,'Autoenc') + elseif strcmp(data,'Autoenc') trainingData=synergiesAutoenc; else error('only EEG, EMG and LF are valid inputs for data'); @@ -18,9 +18,6 @@ factor=size(trainingDataEMG,1)/(size(trainingData,1)+eegOffset); - clear trainingDataEEG; - clear trainingDataEEGlf; - clear trainingDataEMG; if strcmp(goal,'Autoenc') predicted=shiftingMean(synergiesAutoenc,factor); @@ -30,14 +27,17 @@ predicted=shiftingMean(synergiesNNMF,factor); elseif strcmp(goal,'kin') predicted=shiftingMean(kinematics,factor); - elseif strcmp(data,'EMG') + elseif strcmp(goal,'EMG') predicted=trainingDataEMG; else error('only kin, Autoenc, PCA, NNMF and EMG are valid inputs for goal'); end - clear kinematics; + clear trainingDataEEG; + clear trainingDataEEGlf; + clear trainingDataEMG; clear synergies*; + clear kinematics; if eeg predicted=predicted(1:end-eegOffset,:); @@ -64,4 +64,4 @@ correlation(j)=mean(correlations); end -end \ No newline at end of file +end