15 using namespace dqmTnP;
35 myDQMrootFolder( pset.getUntrackedParameter<string>(
"MyDQMrootFolder") ),
36 verbose( pset.getUntrackedParameter<bool>(
"Verbose",
false) ),
37 efficiencies( pset.getUntrackedParameter<
VParameterSet>(
"Efficiencies") )
40 plots = savePlotsInRootFileName!=
"" ?
new TFile(savePlotsInRootFileName,
"recreate") : 0;
48 LogError(
"DQMGenericTnPClient")<<
"Could not find DQMStore service\n";
64 if(allME==0 || passME==0){
65 LogDebug(
"DQMGenericTnPClient")<<
"Could not find MEs: "<<allMEname<<
" or "<<passMEname<<endl;
68 TH1 *
all = allME->getTH1();
69 TH1 *pass = passME->
getTH1();
73 if(fitFunction==
"GaussianPlusLinear"){
81 }
else if(fitFunction==
"VoigtianPlusExponential"){
91 LogError(
"DQMGenericTnPClient")<<
"Fit function: "<<fitFunction<<
" does not exist"<<endl;
95 int dimensions = all->GetDimension();
97 if(massDimension>dimensions){
98 LogError(
"DQMGenericTnPClient")<<
"Monitoring Element "<<allMEname<<
" has smaller dimension than "<<massDimension<<endl;
105 if ( string::npos != slashPos ) {
106 effDir +=
"/"+effName.substr(0, slashPos);
107 effName.erase(0, slashPos+1);
110 TString
prefix(effDir.c_str());
111 prefix.ReplaceAll(
'/',
'_');
115 TProfile* effChi2 = 0;
116 TString
error = fitter->calculateEfficiency((TH2*)pass, (TH2*)all, massDimension, eff, effChi2,
plots?
prefix+effName.c_str():
"");
118 LogError(
"DQMGenericTnPClient")<<error<<endl;
125 }
else if(dimensions==3){
127 TProfile2D* effChi2 = 0;
128 TString
error = fitter->calculateEfficiency((TH3*)pass, (TH3*)all, massDimension, eff, effChi2,
plots?
prefix+effName.c_str():
"");
130 LogError(
"DQMGenericTnPClient")<<error<<endl;
T getUntrackedParameter(std::string const &, T const &) const
GaussianPlusLinearFitter * GPLfitter
#define DEFINE_FWK_MODULE(type)
std::vector< ParameterSet > VParameterSet
void calculateEfficiency(const ParameterSet &pset)
void setup(double expectedMean_, double massLow, double massHigh, double expectedSigma_)
void setup(double expectedMean_, double massLow, double massHigh, double expectedSigma_, double width_)
DQMGenericTnPClient(const edm::ParameterSet &pset)
VoigtianPlusExponentialFitter * VPEfitter
tuple DQMGenericTnPClient
virtual ~DQMGenericTnPClient()
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
MonitorElement * get(const std::string &path) const
get ME from full pathname (e.g. "my/long/dir/my_histo")
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
virtual void endRun(const edm::Run &run, const edm::EventSetup &setup)
virtual void analyze(const edm::Event &event, const edm::EventSetup &eventSetup)
const VParameterSet efficiencies
void setCurrentFolder(const std::string &fullpath)
MonitorElement * bookProfile2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, int nchZ, double lowZ, double highZ, const char *option="s")