Lines Matching refs:trace
39 trace = trappy.FTrace()
41 for attr in trace.class_definitions.iterkeys():
42 self.assertTrue(hasattr(trace, attr))
47 trace = trappy.FTrace(scope="all")
49 for attr in trace.class_definitions.iterkeys():
50 self.assertTrue(hasattr(trace, attr))
55 trace = trappy.FTrace(scope="thermal")
57 for attr in trace.thermal_classes.iterkeys():
58 self.assertTrue(hasattr(trace, attr))
60 for attr in trace.sched_classes.iterkeys():
61 self.assertFalse(hasattr(trace, attr))
66 trace = trappy.FTrace(scope="sched")
68 for attr in trace.thermal_classes.iterkeys():
69 self.assertFalse(hasattr(trace, attr))
71 for attr in trace.sched_classes.iterkeys():
72 self.assertTrue(hasattr(trace, attr))
77 trace = trappy.FTrace(scope="custom")
79 for attr in trace.thermal_classes.iterkeys():
80 self.assertFalse(hasattr(trace, attr))
82 for attr in trace.sched_classes.iterkeys():
83 self.assertFalse(hasattr(trace, attr))
87 trace = trappy.FTrace(scope="custom")
89 self.assertTrue(hasattr(trace, "a_dynamic_event"))
96 trace = trappy.FTrace()
101 trace.add_parsed_event("sched_switch", dfr)
144 trace = trappy.FTrace()
146 self.assertEquals(round(trace.thermal.data_frame.index[0], 7), 0)
151 trace = trappy.FTrace(normalize_time=False)
153 self.assertNotEquals(round(trace.thermal.data_frame.index[0], 7), 0)
158 trace = trappy.FTrace(normalize_time=False)
160 basetime = trace.thermal.data_frame.index[0]
162 self.assertEqual(trace.basetime, basetime)
167 trace = trappy.FTrace(normalize_time=True)
169 duration = trace.thermal_governor.data_frame.index[-1] - trace.thermal.data_frame.index[0]
171 self.assertEqual(trace.get_duration(), duration)
176 trace = trappy.FTrace(normalize_time=False)
178 duration = trace.thermal_governor.data_frame.index[-1] - trace.thermal.data_frame.index[0]
180 self.assertEqual(trace.get_duration(), duration)
186 trace = trappy.FTrace(normalize_time=False)
188 prev_inpower_basetime = trace.cpu_in_power.data_frame.index[0]
189 prev_inpower_last = trace.cpu_in_power.data_frame.index[-1]
191 trace._normalize_time()
193 self.assertEquals(round(trace.thermal.data_frame.index[0], 7), 0)
195 exp_inpower_first = prev_inpower_basetime - trace.basetime
196 self.assertEquals(round(trace.cpu_in_power.data_frame.index[0] - exp_inpower_first, 7), 0)
198 exp_inpower_last = prev_inpower_last - trace.basetime
199 self.assertEquals(round(trace.cpu_in_power.data_frame.index[-1] - exp_inpower_last, 7), 0)
204 trace = trappy.FTrace(scope="custom", events=["cdev_update"])
206 self.assertGreater(len(trace.cdev_update.data_frame), 1)
209 trace = trappy.FTrace(scope="custom", events="foo")
210 self.assertTrue(hasattr(trace, "foo"))
215 trace = trappy.FTrace(scope="custom", events=events)
217 self.assertTrue(trace.sched_switch.parse_raw)
218 self.assertEquals(trace.sched_load_avg_sg.pivot, "cpus")
251 trace = trappy.FTrace()
253 trace.apply_callbacks(fn_map)
261 trace = trappy.FTrace()
264 trace.plot_freq_hists(self.map_label, axis)
269 trace = trappy.FTrace()
270 trace.plot_load(self.map_label, title="Util")
273 trace.plot_load(self.map_label, ax=ax)
278 trace = trappy.FTrace()
281 trace.plot_normalized_load(self.map_label, ax=ax)
286 trace = trappy.FTrace()
288 trace.plot_allfreqs(self.map_label)
293 trace.plot_allfreqs(self.map_label, ax=axis)
305 trace = trappy.FTrace()
309 trace.plot_allfreqs(map_label, ax=[axis])
319 trace = trappy.FTrace()
321 self.assertTrue(hasattr(trace, "_" + key))
322 self.assertEquals(getattr(trace, "_" + key), value)
337 trace = trappy.FTrace()
338 self.assertEquals(trace._cpus, None)
339 self.assertEquals(trace._version, None)
340 self.assertTrue(len(trace.thermal.data_frame) > 0)
344 trace = trappy.FTrace(window=(1.234726, 5.334726))
345 self.assertEquals(trace.thermal.data_frame.iloc[0]["temp"], 68989)
346 self.assertEquals(trace.thermal.data_frame.iloc[-1]["temp"], 69530)
350 trace = trappy.FTrace(abs_window=(1585, 1589.1))
351 self.assertEquals(trace.thermal.data_frame.iloc[0]["temp"], 68989)
352 self.assertEquals(trace.thermal.data_frame.iloc[-1]["temp"], 69530)
368 trace = trappy.FTrace()
369 self.assertTrue(hasattr(trace, "sched_switch"))
370 self.assertTrue(len(trace.sched_switch.data_frame) > 0)
371 self.assertTrue("prev_comm" in trace.sched_switch.data_frame.columns)
379 trace = trappy.FTrace(arbitrary_name)
380 self.assertTrue(hasattr(trace, "sched_switch"))
381 self.assertTrue(len(trace.sched_switch.data_frame) > 0)
395 trace = trappy.FTrace()
396 self.assertTrue(hasattr(trace, "sched_switch"))
397 self.assertTrue(len(trace.sched_switch.data_frame) > 0)
406 trace = trappy.FTrace(arbitrary_name)
407 self.assertTrue(hasattr(trace, "sched_switch"))
408 self.assertTrue(len(trace.sched_switch.data_frame) > 0)
422 trace = trappy.FTrace(normalize_time=False)
424 self.assertEqual(trace.basetime, 0)
445 trace = trappy.FTrace()
447 self.assertEqual(trace.thermal.data_frame.index[0], 0)