54 virtual void endJob()
override ;
76 ecal_parts_.push_back(
"Barrel");
77 ecal_parts_.push_back(
"Endcap");
79 histFile_=
new TFile(
"histos.root",
"RECREATE");
80 for (
unsigned int i=0;
i<2;++
i) {
83 sprintf(t,
"%s_energy",ecal_parts_[
i].c_str());
84 ecal_et_[
i]=
new TH1I(t,
"Et",255,0,255);
88 sprintf(titleTTF,
"%s_ttf",ecal_parts_[
i].c_str());
89 ecal_tt_[
i]=
new TH1I(titleTTF,
"TTF",10,0,10);
93 sprintf(titleFG,
"%s_fgvb",ecal_parts_[
i].c_str());
94 ecal_fgvb_[
i]=
new TH1I(titleFG,
"FGVB",10,0,10);
99 ecal_tp_token_ = consumes<EcalTrigPrimDigiCollection> (
edm::InputTag(label_,producer_));
140 ecal_tt_[subdet]->Fill(d.
ttFlag());
155 for (
unsigned int i=0;
i<2;++
i) {
156 ecal_et_[
i]->Write();
157 ecal_tt_[
i]->Write();
158 ecal_fgvb_[
i]->Write();
T getParameter(std::string const &) const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
def analyze(function, filename, filter=None)
#define DEFINE_FWK_MODULE(type)
virtual void analyze(const edm::Event &, const edm::EventSetup &) override
edm::EDGetTokenT< EcalTrigPrimDigiCollection > ecal_tp_token_
int compressedEt() const
get the encoded/compressed Et of interesting sample
virtual void beginJob() override
int ietaAbs() const
get the absolute value of the tower ieta
const EcalTrigTowerDetId & id() const
T const * product() const
TPGCheck(const edm::ParameterSet &)
EcalSubdetector subDet() const
get the subDetector associated to the Trigger Tower
virtual void endJob() override
bool fineGrain() const
get the fine-grain bit of interesting sample
std::vector< std::string > ecal_parts_
int ttFlag() const
get the Trigger tower Flag of interesting sample