Add saturation max slider to UI and image processing logic

This commit is contained in:
lm
2026-03-22 17:42:26 +01:00
parent daf226a80f
commit ff9dec0eff
6 changed files with 20 additions and 7 deletions
+4 -4
View File
@@ -12,18 +12,18 @@ def test_stats_summary():
matches_excl=10, total_excl=20
)
# Mock translator
def mock_t(key, **kwargs):
if key == "stats.placeholder":
return "Placeholder"
return f"{kwargs['with_pct']:.1f} {kwargs['without_pct']:.1f} {kwargs['excluded_pct']:.1f} {kwargs['excluded_match_pct']:.1f}"
if not kwargs:
return key
return f"{kwargs['with_pct']:.1f} {kwargs['without_pct']:.1f} {kwargs['excluded_pct']:.1f}"
res = s.summary(mock_t)
# with_pct: 40/80 = 50.0
# without_pct: 50/100 = 50.0
# excluded_pct: 20/100 = 20.0
# excluded_match_pct: 10/20 = 50.0
assert res == "50.0 50.0 20.0 50.0"
assert res == "50.0 50.0 20.0"
def test_stats_empty():
s = Stats()