CMS 3D CMS Logo

QGLikelihoodSystematicsDBReader.cc
Go to the documentation of this file.
1 #include <memory>
12 
14 public:
17 
18 private:
19  void beginJob() override {}
20  void analyze(const edm::Event&, const edm::EventSetup&) override;
21  void endJob() override {}
22 
26 };
27 
29  mPayloadName = iConfig.getUntrackedParameter<std::string>("payloadName");
31  mPrintScreen = iConfig.getUntrackedParameter<bool>("printScreen");
32  mCreateTextFile = iConfig.getUntrackedParameter<bool>("createTextFile");
33 }
34 
36  edm::LogInfo("UserOutput") << "Inspecting QGLikelihood payload with label:" << mPayloadName << std::endl;
38 
39  std::vector<QGLikelihoodSystematicsObject::Entry> const& data = QGLSysPar->data;
40  edm::LogInfo("UserOutput") << "There are " << data.size()
41  << " entries (categories with parameters for smearing):" << std::endl;
42  for (auto idata = data.begin(); idata != data.end(); ++idata) {
43  int qgBin = idata->systCategory.QGIndex;
44  double etaMin = idata->systCategory.EtaMin;
45  double etaMax = idata->systCategory.EtaMax;
46  double rhoMin = idata->systCategory.RhoMin;
47  double rhoMax = idata->systCategory.RhoMax;
48  double ptMin = idata->systCategory.PtMin;
49  double ptMax = idata->systCategory.PtMax;
50  double a = idata->a;
51  double b = idata->b;
52  double lmin = idata->lmin;
53  double lmax = idata->lmax;
54 
55  char buff[1000];
56  sprintf(buff,
57  "qg=%1d, ptMin=%8.2f, ptMax=%8.2f, etaMin=%3.1f, etaMax=%3.1f, rhoMin=%6.2f, rhoMax=%6.2f, a=%7.3f, "
58  "b=%7.3f, lmin=%6.2f, lmax=%6.2f",
59  qgBin,
60  ptMin,
61  ptMax,
62  etaMin,
63  etaMax,
64  rhoMin,
65  rhoMax,
66  a,
67  b,
68  lmin,
69  lmax);
70  edm::LogVerbatim("UserOutput") << buff << std::endl;
71  }
72 }
73 
Log< level::Info, true > LogVerbatim
void analyze(const edm::Event &, const edm::EventSetup &) override
edm::ESGetToken< QGLikelihoodSystematicsObject, QGLikelihoodSystematicsRcd > mPayloadToken
constexpr float ptMin
T getUntrackedParameter(std::string const &, T const &) const
int iEvent
Definition: GenABIO.cc:224
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
Definition: EventSetup.h:130
Log< level::Info, false > LogInfo
double b
Definition: hdecay.h:120
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:80
double a
Definition: hdecay.h:121
QGLikelihoodSystematicsDBReader(const edm::ParameterSet &)