From a51632ea7a8ef39b357dee88fb7e8246cce24f4e Mon Sep 17 00:00:00 2001 From: Théo de la Hogue Date: Thu, 6 Jul 2023 15:57:26 +0200 Subject: Finishing gaze movement outputted on unvalid gaze position at terminate time. --- src/argaze/GazeAnalysis/DispersionThresholdIdentification.py | 2 +- src/argaze/GazeAnalysis/VelocityThresholdIdentification.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/argaze/GazeAnalysis/DispersionThresholdIdentification.py b/src/argaze/GazeAnalysis/DispersionThresholdIdentification.py index 230e402..42450e5 100644 --- a/src/argaze/GazeAnalysis/DispersionThresholdIdentification.py +++ b/src/argaze/GazeAnalysis/DispersionThresholdIdentification.py @@ -124,7 +124,7 @@ class GazeMovementIdentifier(GazeFeatures.GazeMovementIdentifier): # Ignore non valid gaze position if not gaze_position.valid: - return GazeFeatures.UnvalidGazeMovement() if not terminate else self.current_fixation + return GazeFeatures.UnvalidGazeMovement() if not terminate else self.current_fixation.finish() # Check if too much time elapsed since last gaze position if len(self.__valid_positions) > 0: diff --git a/src/argaze/GazeAnalysis/VelocityThresholdIdentification.py b/src/argaze/GazeAnalysis/VelocityThresholdIdentification.py index a514ea7..c00a778 100644 --- a/src/argaze/GazeAnalysis/VelocityThresholdIdentification.py +++ b/src/argaze/GazeAnalysis/VelocityThresholdIdentification.py @@ -133,7 +133,7 @@ class GazeMovementIdentifier(GazeFeatures.GazeMovementIdentifier): # Ignore non valid gaze position if not gaze_position.valid: - return GazeFeatures.UnvalidGazeMovement() if not terminate else self.current_fixation + return GazeFeatures.UnvalidGazeMovement() if not terminate else self.current_fixation.finish() # Store first valid position if self.__last_ts < 0: -- cgit v1.1