From 3d8a5a9a3b6f2a808795d185afe2b1109c3227aa Mon Sep 17 00:00:00 2001 From: Amaury Chamayou Date: Wed, 15 Apr 2020 09:48:47 +0100 Subject: [PATCH] Bugfix for 0.2.14 --- cimetrics/plot.py | 4 ++-- setup.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cimetrics/plot.py b/cimetrics/plot.py index c00e3cd..540e927 100644 --- a/cimetrics/plot.py +++ b/cimetrics/plot.py @@ -126,9 +126,9 @@ def less_than_max_build_id(record): return df -def anomalies(series): +def anomalies(series, window_size): ts = series.set_index(pandas.date_range(start="1/1/1970", periods=len(series))) - ad = LevelShiftAD(window=3) + ad = LevelShiftAD(window=window_size) an = ad.fit_detect(ts).fillna(0).diff().fillna(0).reset_index(drop=True) return an[an > 0].dropna().index diff --git a/setup.py b/setup.py index 8815ee3..014da85 100644 --- a/setup.py +++ b/setup.py @@ -12,7 +12,7 @@ setup( name="cimetrics", - version="0.2.14", + version="0.2.15", description="Lightweight python module to track crucial metrics", long_description=long_description, long_description_content_type='text/markdown',