From 561b992d1281ff6fe37d46dfb9ba4b528a8c5f75 Mon Sep 17 00:00:00 2001 From: Alexandros Evangelou Date: Fri, 1 Jul 2022 14:24:51 +0300 Subject: [PATCH 1/2] Instead of go to Offtime go InterTrial at is_sleep_time check Issue: https://github.com/ef-lab/PyMouse/issues/298#issue-1276730989 When the is_sleep_time is True go to InterTrial to check if mouse is Hydrated or not --- Experiments/MatchPort.py | 2 +- Experiments/MatchToSample.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Experiments/MatchPort.py b/Experiments/MatchPort.py index f50828c4..a2b37f28 100644 --- a/Experiments/MatchPort.py +++ b/Experiments/MatchPort.py @@ -80,7 +80,7 @@ def next(self): if self.is_stopped(): return 'Exit' elif self.beh.is_sleep_time(): - return 'Offtime' + return 'InterTrial' elif self.resp_ready: return 'Trial' else: diff --git a/Experiments/MatchToSample.py b/Experiments/MatchToSample.py index 88c059b0..d5e21fa1 100644 --- a/Experiments/MatchToSample.py +++ b/Experiments/MatchToSample.py @@ -89,7 +89,7 @@ def next(self): if self.is_stopped(): return 'Exit' elif self.beh.is_sleep_time(): - return 'Offtime' + return 'InterTrial' elif self.resp_ready: return 'Cue' else: From 788c5747c0a11432c04afa60df110f518b24d872 Mon Sep 17 00:00:00 2001 From: Alexandros Evangelou Date: Tue, 12 Jul 2022 12:29:56 +0300 Subject: [PATCH 2/2] Add state as a Primary key on Trrial.StateOnset table --- core/Experiment.py | 1 - 1 file changed, 1 deletion(-) diff --git a/core/Experiment.py b/core/Experiment.py index fe10ea3d..2d45ef71 100644 --- a/core/Experiment.py +++ b/core/Experiment.py @@ -303,7 +303,6 @@ class StateOnset(dj.Part): # Trial state timestamps -> Trial time : int # time from session start (ms) - --- state : varchar(64) """