CMS 3D CMS Logo

CSCDQM Framework Guide

Introduction

CSCDQM Framework provides common services for both Local and Global CSC DQM. It includes analysis module, caching, etc. And should be extended in the nearest future.

The rationale in creating this framework/library is being sick in constantly changing Local and Global DQM code and being not efficient in both places. And having no spare time for hobbies. After starting to program this framework found myself even more busy.

Murphys Law: Everything done to improve it only makes it worse.

Quick Start Guide

Below are some steps that are necessary to go throught while trying to run the library.

Step 1: Implement cscdqm::MonitorObject

One should implement/extend cscdqm::MonitorObject interface which is the main (and only) Monitoring Object that goes into the library and is beinf manipulated uppon. Example:

class MyMonitorObject : public cscdqm::MonitorObject {
public:
// Implement virtual methods
};

Step 2: Implement cscdqm::MonitorObjectProvider

cscdqm::MonitorObjectProvider is the object which receives cscdqm::HistoBookRequest to get cscdqm::MonitorObject. Note that particular Monitor Object is being requested only once. After that received pointer to MonitorObject will be held in framework cache efficiently. Example:

class MyMonitorObjectProvider : public cscdqm::MonitorObjectProvider {
public:
// Your code
}
// Other methods, etc.
};

Step 3: Rock & Roll

In your code create cscdqm::Configuration object, supply whatever parameters you need (or load XML configuration file, or edm::ParameterSet), create your cscdqm::MonitorObjectProvider and then create cscdqm::Dispatcher object. Thats it. Now you can supply events to Dispatcher by calling appropriate method. Note that event processing methods differ in Local and Global DQM! You can call a methof to update fractional and efficiency histograms as well. Example:

class MyApplication {
private:
MyMonitorObjectProvider provider;
cscdqm::Dispatcher dispatcher;
public:
MyApplication() : dispatcher(&config, &provider) {
// do whatever with config object, i.e.
// config.setPARAMETER(x);
dispatcher.init();
}
~MyApplication() {
}
void processEvent(const char* data, const int32_t* dataSize, const uint32_t errorStat, const int32_t nodeNumber) {
dispatcher.processEvent(data, dataSize, errorStat, nodeNumber);
}
};
cscdqm::Dispatcher::updateFractionAndEfficiencyHistos
void updateFractionAndEfficiencyHistos()
On demand update fraction and efficiency MOs.
Definition: CSCDQM_Dispatcher.cc:244
config
Definition: config.py:1
CSCMonitorObject
cscdqm::MonitorObject implementation used in CSCMonitorModuleCmn
Definition: CSCMonitorObject.h:29
CSCDQM_MonitorObjectProvider.h
looper.config
config
Definition: looper.py:291
processEvent
dispatcher processEvent(e, inputTag, standby)
cscdqm::HistoBookRequest
Definition: CSCDQM_MonitorObjectProvider.h:31
cscdqm::Configuration
CSCDQM Framework Global Configuration.
Definition: CSCDQM_Configuration.h:233
CSCDQM_MonitorObject.h
cscdqm::Dispatcher::init
void init()
Initialize Dispatcher: book histograms, init processor, etc.
Definition: CSCDQM_Dispatcher.cc:85
cscdqm::Dispatcher
CSCDQM Framework frontend and Histogram Cache controller.
Definition: CSCDQM_Dispatcher.h:115
cscdqm::MonitorObject
Monitoring Object interface used to cover Root object and provide common interface to EventProcessor ...
Definition: CSCDQM_MonitorObject.h:35
data
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
cscdqm::MonitorObjectProvider::bookMonitorObject
virtual MonitorObject * bookMonitorObject(const HistoBookRequest &p_req)=0
cscdqm::MonitorObjectProvider
Interface for Histogram providing objects. Used by Event Processor to retrieve MonitorObject 's and b...
Definition: CSCDQM_MonitorObjectProvider.h:124