Closed cobrien7 closed 7 years ago
This patch should work exactly the same as https://github.com/ARM-software/lisa/pull/418, except that the new method is added to GenericFTrace instead of the LISA Trace class.
Hi Connor, Is it possible to not use the word 'analysis' in the core function? If I understand correctly, trappy is used for data generation and visualization, analysis usage of this will be in LISA. Also this feature may be used for https://github.com/ARM-software/trappy/issues/250. Considering this, I would call it run_event_callbacks
CC @cobrien7
I would say that TRAPpy
is mainly for data generation... while analysis AND visualisation is mainly in LISA. We know have some plotting methods in TRAPpy which are still there mainly for backward compatibility reasons., but future bits should be better organised according to a schema where everything which is not "generic DF generation and processing" should not be in TRAPpy.
Regarding the function name, what about something like a quite generic process_events
?
Hmm @derkling I prefer a more explicit name like run_event_callbacks
. @cobrien7 could you update this PR with the change?
Never mind, so @cobrien7 did change it. @sinkap I guess over to you then.
apply_callbacks
sounds good to me.
Done! :+1:
Some trace analysis tasks are most easily expressed by iterating over events in chronological order. Add a run_custom_analysis() method to the GenericFTrace class that will run user-defined functions on trace events in the order they occurred.
Signed-off-by: Connor O'Brien connoro@google.com