chore: enforce ruff config and fix lint findings

This commit is contained in:
kemal committed 2026-08-15 20:45:02 +01:00
1 parent 06ce53bc44
commit dbbea1a95f
12 files changed
+42 -26

No files matched your search

+4 -4
View File
@@ -12,11 +12,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from .rls import RecursiveLeastSquares, AdaptiveConformal
from .nowcast import NowcastEnsemble
from .climatology import HarmonicClimatology
from .precip import PrecipitationModel, zambretti
from .anomaly import AnomalyMonitor
from .climatology import HarmonicClimatology
from .nowcast import NowcastEnsemble
from .precip import PrecipitationModel, zambretti
from .rls import AdaptiveConformal, RecursiveLeastSquares
__all__ = [
"RecursiveLeastSquares", "AdaptiveConformal", "NowcastEnsemble",
+2 -2
View File
@@ -141,9 +141,9 @@ class HarmonicClimatology:
sigma0 = self.resid_std.get(target, 1.0)
sigma = sigma0 * np.sqrt(1.0 + lead_h / 24.0)
return [
{"ts": float(t), "lead_h": float(l), "mu": float(m),
{"ts": float(t), "lead_h": float(lh), "mu": float(m),
"lo": float(m - 1.645 * s), "hi": float(m + 1.645 * s)}
for t, l, m, s in zip(grid, lead_h, mu, sigma)
for t, lh, m, s in zip(grid, lead_h, mu, sigma)
]
def anomaly_now(self, target: str, ts: float, observed: float) -> float:
+1 -1
View File
@@ -39,7 +39,7 @@ from __future__ import annotations
import math
import time
from typing import Dict, List, Optional, Tuple
from typing import Dict, List, Optional
import numpy as np