33 gSystem->Load(
"libFWCoreFWLite" );
39 std::cout <<
"Usage : " << argv[0] <<
" [parameters.py]" << std::endl;
55 TH1F* jetPt_ = theDir.
make<TH1F>(
"jetPt",
"pt", 100, 0.,300.);
56 TH1F* jetEta_ = theDir.make<TH1F>(
"jetEta",
"eta", 100, -3., 3.);
57 TH1F* jetPhi_ = theDir.make<TH1F>(
"jetPhi",
"phi", 100, -5., 5.);
58 TH1F* disc_ = theDir.make<TH1F>(
"disc",
"Discriminant", 100, 0.0, 10.0);
59 TH1F* constituentPt_ = theDir.make<TH1F>(
"constituentPt",
"Constituent pT", 100, 0, 300.0);
62 TFile* inFile = TFile::Open(input_.c_str());
81 if( iEvent==1000 )
break;
84 if(iEvent>0 && iEvent%1==0){
85 std::cout <<
" processing event: " << iEvent << std::endl;
91 event.getByLabel(jets_, jets);
94 for(
unsigned i=0;
i<jets->size(); ++
i){
96 jetPt_ ->Fill( (*jets)[
i].
pt() );
97 jetEta_->Fill( (*jets)[
i].
eta() );
98 jetPhi_->Fill( (*jets)[
i].
phi() );
101 if( svTagInfos != 0 ) {
107 std::vector<reco::PFCandidatePtr>
const & pfConstituents = (*jets)[
i].getPFConstituents();
108 for( std::vector<reco::PFCandidatePtr>::const_iterator ibegin=pfConstituents.begin(), iend=pfConstituents.end(), iconstituent=ibegin; iconstituent!=iend; ++iconstituent){
109 constituentPt_->Fill( (*iconstituent)->pt() );
T getParameter(std::string const &) const
Event const & toBegin()
Go to the very first Event.
static void enable()
enable automatic library loading
T * make(const Args &...args) const
make new ROOT object
unsigned int nVertices() const
virtual bool atEnd() const
TFileDirectory mkdir(const std::string &dir, const std::string &descr="")
create a new subdirectory
Geom::Phi< T > phi() const
Measurement1D flightDistance(unsigned int index, int dim=0) const
std::shared_ptr< edm::ProcessDesc > processDesc() const
edm::Service< TFileService > fs