From 9ed9c95cdbfa1ab122a866049f2a27daf0e496b1 Mon Sep 17 00:00:00 2001 From: Rohan Satapathy <61920401+rohansatapathy@users.noreply.github.com> Date: Mon, 25 Mar 2024 14:46:25 -0400 Subject: [PATCH] Fix text scale in annotated video --- LabGym/analyzebehaviors.py | 4 ++-- LabGym/analyzebehaviorsdetector.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/LabGym/analyzebehaviors.py b/LabGym/analyzebehaviors.py index 555b59e..d76e1f0 100644 --- a/LabGym/analyzebehaviors.py +++ b/LabGym/analyzebehaviors.py @@ -820,8 +820,8 @@ def annotate_video(self, behavior_to_include, show_legend=True, interact_all=Fal print("Annotating video...") print(datetime.datetime.now()) - text_scl = max(min(self.background.shape[0], self.background.shape[1]) / 960, 0.5) - text_tk = max(1, int(min(self.background.shape[0], self.background.shape[1]) / 960)) + text_scl = 1 + text_tk = 2 if self.categorize_behavior is True: colors = {} diff --git a/LabGym/analyzebehaviorsdetector.py b/LabGym/analyzebehaviorsdetector.py index 297ec1a..59a9ed5 100644 --- a/LabGym/analyzebehaviorsdetector.py +++ b/LabGym/analyzebehaviorsdetector.py @@ -1418,8 +1418,8 @@ def annotate_video(self, animal_to_include, behavior_to_include, show_legend=Tru print("Annotating video...") print(datetime.datetime.now()) - text_scl = max(min(self.background.shape[0], self.background.shape[1]) / 960, 0.5) - text_tk = max(1, int(min(self.background.shape[0], self.background.shape[1]) / 960)) + text_scl = 1 + text_tk = 2 if self.categorize_behavior is True: colors = {}