SilverLabUCL / PySilverLabNWB

Python tools for working with Silver Lab data in the NWB2 format
MIT License
1 stars 0 forks source link

Inconsistencies in trial times in header #76

Open ageorgou opened 3 years ago

ageorgou commented 3 years ago

For LabVIEW versions 2.3.1 onwards, we read the start and stop time of each trial from the header file (trigger times in section [Intertrial FIFO Times]). However, it seems that in some datasets not all times are listed; for example, the header has Number of trials = 30.000 but only 58 trigger times.

In those cases, the MATLAB code falls back to the encoder (speed data), as we do for older versions. We currently don't check whether all times are listed (i.e. whether they are consistent with Number of trials), but instead use the listed times to infer the number of trials.

Is this a common enough situation that we should handle it using the speed data, or should we throw an error?