diff options
author | Javi Merino <javi.merino@arm.com> | 2016-01-27 18:12:01 +0000 |
---|---|---|
committer | Javi Merino <javi.merino@arm.com> | 2016-01-27 18:12:01 +0000 |
commit | 7881a53f3898b121e04de245a80f24976ae198b6 (patch) | |
tree | f1610ed5f39cd4e015f2da0f718af7990eb2e87d /bart/thermal/ThermalAssert.py | |
parent | 79310bfbf0050de7330efbc84a5dc5d0834aa3eb (diff) | |
download | bart-7881a53f3898b121e04de245a80f24976ae198b6.tar.gz |
bart: Use trappy.FTrace instead of trappy.Run
As of c26a32321053 ("ftrace: rename Run to FTrace"), trappy deprecated
trappy.Run in favour of trappy.FTrace. Move bart to use the new interface.
Diffstat (limited to 'bart/thermal/ThermalAssert.py')
-rw-r--r-- | bart/thermal/ThermalAssert.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/bart/thermal/ThermalAssert.py b/bart/thermal/ThermalAssert.py index e7c3431..d0ffa78 100644 --- a/bart/thermal/ThermalAssert.py +++ b/bart/thermal/ThermalAssert.py @@ -25,17 +25,17 @@ import numpy as np # pylint: disable=too-many-arguments class ThermalAssert(object): - """A class that accepts a TRAPpy Run object and + """A class that accepts a TRAPpy FTrace object and provides assertions for thermal behaviours - :param run: A path to the trace file or a TRAPpy Run object - :type run: str, :mod:`trappy.run.Run` + :param ftrace: A path to the trace file or a TRAPpy FTrace object + :type ftrace: str, :mod:`trappy.ftrace.FTrace` """ - def __init__(self, run, config=None): + def __init__(self, ftrace, config=None): - self._run = Utils.init_run(run) - self._analyzer = Analyzer(self._run, config) + self._ftrace = Utils.init_ftrace(ftrace) + self._analyzer = Analyzer(self._ftrace, config) def getThermalResidency(self, temp_range, window, percent=False): """Return the total time spent in a given temperature range @@ -78,7 +78,7 @@ class ThermalAssert(object): if percent: result[pivot] = ( - result[pivot] * 100.0) / self._run.get_duration() + result[pivot] * 100.0) / self._ftrace.get_duration() return result |