From bf5c508a7a8477e1159239ef9527340f2191490d Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Thu, 4 Sep 2025 00:56:05 +0200 Subject: [PATCH] perf(qav3): less strict min # of extrema at train optimization MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- quickadapter/user_data/strategies/Utils.py | 2 +- scripts/docker-upgrade.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/quickadapter/user_data/strategies/Utils.py b/quickadapter/user_data/strategies/Utils.py index 840b323..29d67e8 100644 --- a/quickadapter/user_data/strategies/Utils.py +++ b/quickadapter/user_data/strategies/Utils.py @@ -148,7 +148,7 @@ def format_number(value: int | float, significant_digits: int = 5) -> str: @lru_cache(maxsize=128) def calculate_min_extrema( - length: int, fit_live_predictions_candles: int, min_extrema: int = 4 + length: int, fit_live_predictions_candles: int, min_extrema: int = 2 ) -> int: return int(round(length / fit_live_predictions_candles) * min_extrema) diff --git a/scripts/docker-upgrade.sh b/scripts/docker-upgrade.sh index 069bcd7..a9c8749 100755 --- a/scripts/docker-upgrade.sh +++ b/scripts/docker-upgrade.sh @@ -145,7 +145,7 @@ fi echo_timestamped "Info: docker image pull for ${REMOTE_DOCKER_IMAGE}" local_digest=$(command docker image inspect --format='{{.Id}}' "$REMOTE_DOCKER_IMAGE" 2>/dev/null || command echo "none") -if ! command docker image pull --quiet "$REMOTE_DOCKER_IMAGE"; then +if ! command docker image pull --quiet "$REMOTE_DOCKER_IMAGE" >/dev/null 2>&1; then echo_timestamped "Error: docker image pull failed for ${REMOTE_DOCKER_IMAGE}" exit 1 fi @@ -170,7 +170,7 @@ if [ "$rebuild_local_image" = true ]; then echo_timestamped "Error: docker compose down failed" exit 1 fi - if ! command docker image rm "$LOCAL_DOCKER_IMAGE"; then + if ! command docker image rm "$LOCAL_DOCKER_IMAGE" >/dev/null 2>&1; then echo_timestamped "Warning: docker image rm failed for ${LOCAL_DOCKER_IMAGE}" fi if ! command docker compose --progress quiet up -d; then -- 2.43.0