Closed jakobchwastek closed 3 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 100.00%. Comparing base (
6a3af88
) to head (09f4a20
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Description
Fixes issue #626
Implemented changes
Introduced support for seconds, milliseconds and steps as units of timestamps in the
time_column
Added a
time_unit
parameter to the constructor of GazeDataFrameAdd a
time_unit
attribute in the DatasetDefinition classDeveloped a private function in GazeDataFrame to convert input timestamps to milliseconds.- Expand functions
gaze.from_csv
,gaze.from_pandas
,gaze.from_numpy
to include atime_unit
parameterIncorporated
time_unit
into existing local dataset definitionsUpdated tests and documentation examples to reflect these changes.
A
time_unit
specification is mandatory when atime_column
is included in the data. To ensure compatibility with certain event detection methods (e.g. idt) I choosed to cast time values to integer after conversion to millis when possible. For example, float timestamps in seconds with millisecond precision (e.g.,[0.001, 0.002]
) are converted to integer milliseconds ([1, 2]
).Type of change
How Has This Been Tested?
GazeDataFrame
to include the specification of thetime_unit
.Checklist: