Skip to content

Commit

Permalink
Remove calibration speed boosting through fixations
Browse files Browse the repository at this point in the history
Also applies black.

Feature was removed since the fixation detector always requires calibrated gaze to work properly.
  • Loading branch information
papr committed Nov 21, 2019
1 parent 380f5bc commit cb650e0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,6 @@ def recent_events(self, events):
ref["screen_pos"] = marker_pos
ref["timestamp"] = frame.timestamp
self.ref_list.append(ref)
if events.get("fixations", []):
self.counter -= 5
if self.counter <= 0:
# last sample before counter done and moving on
audio.tink()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -226,9 +226,14 @@ def open_window(self, title="new_window"):
)
self.monitor_idx = 0
monitor = glfwGetMonitors()[self.monitor_idx]
width, height, redBits, blueBits, greenBits, refreshRate = glfwGetVideoMode(
monitor
)
(
width,
height,
redBits,
blueBits,
greenBits,
refreshRate,
) = glfwGetVideoMode(monitor)
else:
monitor = None
width, height = 640, 360
Expand Down Expand Up @@ -342,11 +347,9 @@ def recent_events(self, events):
# Always save pupil positions
self.pupil_list.extend(events["pupil"])

if on_position and len(self.markers) and events.get("fixations", []):
fixation_boost = 5
if on_position and len(self.markers):
self.screen_marker_state = min(
self.sample_duration + self.lead_in,
self.screen_marker_state + fixation_boost,
self.sample_duration + self.lead_in, self.screen_marker_state,
)

# Animate the screen marker
Expand Down

0 comments on commit cb650e0

Please sign in to comment.