michaelschaub / calcium-imaging-analysis

3 stars 1 forks source link

Sessions get extracted with different numer of trials than SVD sometimes #5

Closed DaminK closed 3 years ago

DaminK commented 3 years ago

Exact same code works on my laptop, but extracts only 187 instead of 696 trials on my PC. Deleting pkl-files and reextract doesn't help.

DaminK commented 3 years ago

Apperantly it was an older version of the GN-06 data, but eventhough it only extracted 187 files the getitem method got a missmatch for boolean masks with the length of 187 as internally it expected 696 trials.

trial_preselection = ((svd.n_targets == 6) & (svd.n_distractors == 0) & (svd.auto_reward == 0) & (svd.both_spouts == 1)) --> shape of 187 svd_pre = svd[ :, trial_preselection ] --> expected shape of 696 svd[ : , :]
--> shape of 187

Works now with "newer" dataset, but shouldn't have happenend

Joloco109 commented 3 years ago

(Accidentally) Closed by commit e9c6fae1 by asserting correct dimensions in init