From b89a5b36438511ece660cddd97f61a3dd1d9d07d Mon Sep 17 00:00:00 2001 From: Daphne Demekas Date: Tue, 23 Apr 2024 11:05:22 -0400 Subject: [PATCH] refresh rate bug --- diplomat/__init__.py | 2 +- diplomat/predictors/sfpe/segmented_frame_pass_engine.py | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/diplomat/__init__.py b/diplomat/__init__.py index df76d64..d2d2bfd 100644 --- a/diplomat/__init__.py +++ b/diplomat/__init__.py @@ -2,7 +2,7 @@ A tool providing multi-animal tracking capabilities on top of other Deep learning based tracking software. """ -__version__ = "0.1.4" +__version__ = "0.1.5" # Can be used by functions to determine if diplomat was invoked through it's CLI interface. CLI_RUN = False diff --git a/diplomat/predictors/sfpe/segmented_frame_pass_engine.py b/diplomat/predictors/sfpe/segmented_frame_pass_engine.py index 97926bf..74149d7 100644 --- a/diplomat/predictors/sfpe/segmented_frame_pass_engine.py +++ b/diplomat/predictors/sfpe/segmented_frame_pass_engine.py @@ -137,9 +137,7 @@ def update(self, amt: int = 1): def rate_limit_update(self): new_time = time.monotonic() - if(new_time - self._last_update - - self._refresh_rate): + if(new_time - self._last_update > self._refresh_rate): self._last_update = new_time self.update_shared_mem(self._internal_prog_data)