Skip to content

Commit

Permalink
Tried to work through compile trial Records - but not sure it works
Browse files Browse the repository at this point in the history
  • Loading branch information
balajisriram committed Apr 23, 2018
1 parent 8adfb96 commit 8d77ccd
Show file tree
Hide file tree
Showing 10 changed files with 237 additions and 374 deletions.
4 changes: 2 additions & 2 deletions bootstrap/standAloneRun.m
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ function standAloneRun(subjectID,BCoreServerPath,setup)
BCoreUtil.replicateTrialRecords({rx.standAlonePath},deleteOnSuccess);
end
[~, ~] = rx.emptyAllBoxes('done running trials in standAloneRun',auth);
% BCoreUtil.compileDetailedRecords(subjectID);
% BCoreUtil.compileRecords(subjectID);
cleanup;
catch ex
disp(['CAUGHT ERROR: ' getReport(ex,'extended')])
Expand All @@ -93,7 +93,7 @@ function standAloneRun(subjectID,BCoreServerPath,setup)
[~, ~] = rx.emptyAllBoxes('done running trials in standAloneRun',auth);
cleanup;
BCoreUtil.replicateTrialRecords({rx.standAlonePath},deleteOnSuccess);
% BCoreUtil.compileDetailedRecords(subjectID);
% BCoreUtil.compileRecords(subjectID);
cleanup;
rethrow(ex)
end
Expand Down
482 changes: 230 additions & 252 deletions classes/core/BCoreUtil.m

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion classes/core/protocols/stimManagers/stimManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -757,7 +757,7 @@ function displayCumulativePhysAnalysis(sm,cumulativeData)

% adding code to get details about reinforcement
[out.potentialRewardMS,compiledLUT] = extractFieldAndEnsure(trialRecords, {'reinforcementManager','rewardSizeULorMS'},'scalar',compiledLUT);
[out.potentialRequestRewardMS,compiledLUT] = extractFieldAndEnsure(trialRecords, {'reinforcementManager','reinforcementManager','requestRewardSizeULorMS'},'scalar',compiledLUT);
[out.potentialRequestRewardMS,compiledLUT] = extractFieldAndEnsure(trialRecords, {'reinforcementManager','reinforcementManager','requestRewardSizeULorMS'},'scalar',compiledLUT);
[out.potentialRewardScalar,compiledLUT] = extractFieldAndEnsure(trialRecords, {'reinforcementManager','reinforcementManager','scalar'},'scalar',compiledLUT);
[out.potentialPenalty,compiledLUT] = extractFieldAndEnsure(trialRecords, {'reinforcementManager','reinforcementManager','msPenalty'},'scalar',compiledLUT);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1139,7 +1139,7 @@ function displayCumulativePhysAnalysis(sm,cumulativedata,parameters)
timeWindowFramesStim=ceil(timeWindowMsStim*(refreshRate/1000));

if (ischar(stimulusDetails.strategy) && strcmp(stimulusDetails.strategy,'expert')) || ...
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(BCoreUtil.LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
seeds=stimulusDetails.seedValues;
spatialDim = stimulusDetails.spatialDim;

Expand Down Expand Up @@ -1741,7 +1741,7 @@ function displayCumulativePhysAnalysis(sm,cumulativedata,parameters)
end

if (ischar(stimulusDetails.strategy) && strcmp(stimulusDetails.strategy,'expert')) || ...
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(BCoreUtil.LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
seeds=stimulusDetails.seedValues;
spatialDim = stimulusDetails.spatialDim;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1147,7 +1147,7 @@ function displayCumulativePhysAnalysis(sm,cumulativedata,parameters)
timeWindowFramesStim=ceil(timeWindowMsStim*(refreshRate/1000));

if (ischar(stimulusDetails.strategy) && strcmp(stimulusDetails.strategy,'expert')) || ...
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(BCoreUtil.LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
seeds=stimulusDetails.seedValues;
spatialDim = stimulusDetails.spatialDim;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1355,7 +1355,7 @@ function displayCumulativePhysAnalysis(sm,cumulativedata,parameters)
timeWindowFramesStim=ceil(timeWindowMsStim*(refreshRate/1000));

if (ischar(stimulusDetails.strategy) && strcmp(stimulusDetails.strategy,'expert')) || ...
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
(exist('fieldsInLUT','var') && ismember('stimDetails.strategy',fieldsInLUT) && strcmp(BCoreUtil.LUTlookup(sessionLUT,stimulusDetails.strategy),'expert'))
seeds=stimulusDetails.seedValues;
spatialDim = stimulusDetails.spatialDim;

Expand Down
10 changes: 0 additions & 10 deletions util/infrastructure/LUTlookup.m

This file was deleted.

22 changes: 0 additions & 22 deletions util/other/matlaby/datenumFor30.m

This file was deleted.

32 changes: 0 additions & 32 deletions util/trials/addOrFindInLUT.m

This file was deleted.

51 changes: 0 additions & 51 deletions util/trials/loadDetailedTrialRecords.m

This file was deleted.

0 comments on commit 8d77ccd

Please sign in to comment.