diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 65dec537..a9803219 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -10,11 +10,11 @@ repos: - id: mixed-line-ending - repo: https://github.com/charliermarsh/ruff-pre-commit # Ruff version. - rev: v0.1.9 + rev: v0.1.14 hooks: - id: ruff - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.1.9 + rev: v0.1.14 hooks: - id: ruff-format diff --git a/pyproject.toml b/pyproject.toml index 3c562567..d79e30be 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ classifiers = [ dev = [ "pre-commit>=3.4", "black>=23.7", - "ruff>=0.1", + "ruff>=0.1.14", "pytest>=7.4", "pytest-asyncio>=0.21", ] diff --git a/src/qseek/search.py b/src/qseek/search.py index aef9a174..eb0b0387 100644 --- a/src/qseek/search.py +++ b/src/qseek/search.py @@ -720,9 +720,10 @@ async def search( semblance.apply_cache(semblance_cache or {}) # Apply after normalization + threshold = parent.detection_threshold ** (1.0 / parent.image_mean_p) detection_idx, detection_semblance = await semblance.find_peaks( - height=parent.detection_threshold, - prominence=parent.detection_threshold, + height=threshold, + prominence=threshold, distance=round(parent.detection_blinding.total_seconds() * sampling_rate), )