]> Piment Noir Git Repositories - freqai-strategies.git/commit
fix(quickadapter): preserve zero power mean exponent in label selection
authorJérôme Benoit <jerome.benoit@piment-noir.org>
Thu, 17 Sep 2026 17:20:36 +0000 (19:20 +0200)
committerJérôme Benoit <jerome.benoit@piment-noir.org>
Thu, 17 Sep 2026 17:20:36 +0000 (19:20 +0200)
commitb9dbdbd23a35c36a2faa1ff0df08285252969d87
treedeb850f6b7f69eebb8448cce9c377f88f8ef1a93
parentb46132a31e81d83c545919713e8e414fed2e10ea
fix(quickadapter): preserve zero power mean exponent in label selection

_validate_power_mean_p returns 0.0 for p=0 (a finite float accepted by
README), and the falsy fallback silently rewrote it to 1.0, turning the
documented generalized-mean p=0 (geometric) into arithmetic. Use an
explicit None check for the fallback; map-based metrics are unchanged.

Verified in the QA image (Freqtrade 2026.8): p=0 now matches
geometric_mean selection (winner 1, identical distances), while p=None
keeps the arithmetic default.
quickadapter/user_data/freqaimodels/QuickAdapterRegressorV3.py