From 5153d3eee67a0f33972b4c56d954eb1e667e2d83 Mon Sep 17 00:00:00 2001 From: brandon Date: Tue, 3 Sep 2024 16:47:49 -0700 Subject: [PATCH 1/4] actually reset detector during test --- test/unit/test_detector_reset.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/unit/test_detector_reset.py b/test/unit/test_detector_reset.py index 1a69b468..3b7560d1 100644 --- a/test/unit/test_detector_reset.py +++ b/test/unit/test_detector_reset.py @@ -27,7 +27,9 @@ def test_reset_retry(gl_experimental: ExperimentalApi): def test_reset_training(gl_experimental: ExperimentalApi): # If we reset a detector, we should have low confidence after the reset - low_confidence_threshold = 0.6 + low_confidence_threshold = 0.75 det = gl_experimental.get_or_create_detector("Test Detector for Resets", "is this a cat?") + gl_experimental.reset_detector(det.id) iq = gl_experimental.submit_image_query(det, "test/assets/cat.jpeg") assert iq.result.confidence < low_confidence_threshold + From 97759b72ba0965afb53d68b9b5067ece32d17f1b Mon Sep 17 00:00:00 2001 From: Auto-format Bot Date: Tue, 3 Sep 2024 23:48:47 +0000 Subject: [PATCH 2/4] Automatically reformatting code --- test/unit/test_detector_reset.py | 1 - 1 file changed, 1 deletion(-) diff --git a/test/unit/test_detector_reset.py b/test/unit/test_detector_reset.py index 3b7560d1..05347f30 100644 --- a/test/unit/test_detector_reset.py +++ b/test/unit/test_detector_reset.py @@ -32,4 +32,3 @@ def test_reset_training(gl_experimental: ExperimentalApi): gl_experimental.reset_detector(det.id) iq = gl_experimental.submit_image_query(det, "test/assets/cat.jpeg") assert iq.result.confidence < low_confidence_threshold - From 2ed38bb4818320ac4384c506941c1633551671e3 Mon Sep 17 00:00:00 2001 From: brandon Date: Tue, 3 Sep 2024 16:50:30 -0700 Subject: [PATCH 3/4] minor version bump --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 53e0e062..91e2e2ed 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,7 +9,7 @@ packages = [ {include = "**/*.py", from = "src"}, ] readme = "README.md" -version = "0.17.5" +version = "0.17.6" [tool.poetry.dependencies] # For certifi, use ">=" instead of "^" since it upgrades its "major version" every year, not really following semver From ff99d5f3746bfd4bf69f329c4e6fd0a0e5e9ca7a Mon Sep 17 00:00:00 2001 From: brandon Date: Tue, 3 Sep 2024 16:53:56 -0700 Subject: [PATCH 4/4] didn't mean to bump this after we figured out the real problem --- test/unit/test_detector_reset.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/test_detector_reset.py b/test/unit/test_detector_reset.py index 05347f30..db3ef1f0 100644 --- a/test/unit/test_detector_reset.py +++ b/test/unit/test_detector_reset.py @@ -27,7 +27,7 @@ def test_reset_retry(gl_experimental: ExperimentalApi): def test_reset_training(gl_experimental: ExperimentalApi): # If we reset a detector, we should have low confidence after the reset - low_confidence_threshold = 0.75 + low_confidence_threshold = 0.6 det = gl_experimental.get_or_create_detector("Test Detector for Resets", "is this a cat?") gl_experimental.reset_detector(det.id) iq = gl_experimental.submit_image_query(det, "test/assets/cat.jpeg")