summaryrefslogtreecommitdiff
path: root/lib/pelt.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/pelt.py')
-rw-r--r--lib/pelt.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/pelt.py b/lib/pelt.py
index 613ae80..58bc9c1 100644
--- a/lib/pelt.py
+++ b/lib/pelt.py
@@ -1,5 +1,8 @@
+#!/usr/bin/env python3
+
import logging
import numpy as np
+import os
from multiprocessing import Pool
logger = logging.getLogger(__name__)
@@ -41,6 +44,13 @@ class PELT:
self.with_multiprocessing = True
self.__dict__.update(kwargs)
+ if os.getenv("DFATOOL_PELT_MODEL"):
+ self.model = os.getenv("DFATOOL_PELT_MODEL")
+ if os.getenv("DFATOOL_PELT_JUMP"):
+ self.jump = int(os.getenv("DFATOOL_PELT_JUMP"))
+ if os.getenv("DFATOOL_PELT_MIN_DIST"):
+ self.min_dist = int(os.getenv("DFATOOL_PELT_MIN_DIST"))
+
# signals: a set of uW measurements belonging to a single parameter configuration (i.e., a single by_param entry)
def needs_refinement(self, signals):
count = 0