|
| KTThroughputProfiler (const std::string &name="throughput-profiler") |
|
virtual | ~KTThroughputProfiler () |
|
bool | Configure (const scarab::param_node &node) |
| Should perform parameter store and command-line configurations. More...
|
|
void | Start () |
|
void | Stop () |
|
void | StartProfiling (KTDataPtr data) |
|
void | Data (KTDataPtr data) |
|
void | Finish () |
|
timespec | Elapsed () |
|
bool | GetOutputFileFlag () const |
|
void | SetOutputFileFlag (bool flag) |
|
const std::string & | GetOutputFilename () const |
|
void | SetOutputFilename (const std::string &fname) |
|
| KTProcessor (const std::string &name="default-proc-name") |
|
virtual | ~KTProcessor () |
|
void | ConnectASlot (const std::string &signalName, KTProcessor *processor, const std::string &slotName, int groupNum=-1) |
|
void | ConnectASignal (KTProcessor *processor, const std::string &signalName, const std::string &slotName, int groupNum=-1) |
|
void | ConnectSignalToSlot (KTSignalWrapper *signal, KTSlotWrapper *slot, int groupNum=-1) |
|
template<class XProcessor > |
void | RegisterSignal (std::string name, XProcessor *signalPtr) |
|
template<class XTarget , typename XReturn > |
void | RegisterSlot (std::string name, XTarget *target, XReturn(XTarget::*funcPtr)()) |
|
template<class XTarget , typename XReturn , typename XArg1 > |
void | RegisterSlot (std::string name, XTarget *target, XReturn(XTarget::*funcPtr)(XArg1)) |
|
template<class XTarget , typename XReturn , typename XArg1 , typename XArg2 > |
void | RegisterSlot (std::string name, XTarget *target, XReturn(XTarget::*funcPtr)(XArg1, XArg2)) |
|
KTSignalWrapper * | GetSignal (const std::string &name) |
|
KTSlotWrapper * | GetSlot (const std::string &name) |
|
template<typename XSignalSig > |
void | RegisterSignal (std::string name, XSignalSig *signalPtr) |
|
| KTConfigurable (const std::string &name="default-name") |
|
virtual | ~KTConfigurable () |
|
bool | Configure (const std::string &config) |
| Implement the option for calling Configure without passing a parameter store node. More...
|
|
const std::string & | GetConfigName () const |
|
void | SetConfigName (const std::string &name) |
|
Measures the speed of data processing.
- Author
- N. S. Oblath
A single timer is used to count the total processing time.
The timer is started with a call to the Start function. The ProcessHeader function is provided as a convenient timer-starting slot called "start", since the Egg processor emits a matching signal before slice processing starts. If using the signal/slot interface, it's recommended to connect the "header" signal (e.g. from KTEggProcessor) to the "start" slot last (i.e. after any other processors have used the "header" signal).
The timer is stopped with a call to the Stop function. The Finish function is provided as a convenient timer-stopping slot called "stop". If using the signal/slot interface, it's recommended to connect the "egg-done" signal (e.g. from KTEggProcessor) to the "stop" slot first (i.e. before any other processors have used the "egg-done" signal).
Information printed:
- Number of slices processed
- Total throughput time – time in seconds between calling the Start function and the Stop function
- Data production rate – bytes per second calculated assuming the slices were recorded in real-time
- Data throughput rate – bytes per second through the analysis
- Analysis time factor – ratio of the data throughput rate to the data production rate. If this is 1, then the code analyzes the data at the same speed it was produced.
Configuration name: "throughput-profiler"
Available configuration values:
Slots:
- "start": void (KTEggHeader*) – Start the timer
- "data": void (KTDataPtr) – Increment the counter on the number of data slices
- "stop": void () – Stop the timer
Definition at line 77 of file KTThroughputProfiler.hh.