Changeset 350 in svn
- Timestamp:
- May 6, 2009, 8:57:21 PM (16 years ago)
- Location:
- trunk
- Files:
-
- 1 added
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Delphes.cpp
r344 r350 46 46 #include "HEPEVTConverter.h" 47 47 #include "LHEFConverter.h" 48 #include "HepMCConverter.h" 48 49 #include "STDHEPConverter.h" 49 50 #include "LHCOConverter.h" … … 273 274 converter = new HEPEVTConverter(inputFileList,outputfilename);//case ntpl file in input list 274 275 } 275 else if(line.length() == 1+line.find_last_of(".hepmc")) 276 { 277 cout <<"** hepmc file format detected**"<<endl;278 cout <<"** Delphes can not yet used this format **"<<endl;279 return -1;276 else if(line.length() == 1+line.find_last_of(".hepmc")) 277 { 278 cout <<"** HepMC ASCII file format detected **"<<endl; 279 cout <<"** This can take several minutes **"<< endl; 280 converter = new HepMCConverter(inputFileList,outputfilename); 280 281 } 281 282 else { … … 332 333 vector<int> NTrackJet; 333 334 334 TSimpleArray< GenParticle> NFCentralQ;335 TSimpleArray<TRootC::GenParticle> NFCentralQ; 335 336 336 337 D_CaloList list_of_calorimeters; … … 392 393 // 2.1a Loop over all particles in event, to fill the towers 393 394 itGen.Reset(); 394 GenParticle *particleG;395 while( (particleG = ( GenParticle*) itGen.Next()) )395 TRootC::GenParticle *particleG; 396 while( (particleG = (TRootC::GenParticle*) itGen.Next()) ) 396 397 { 397 398 TRootGenParticle *particle = new TRootGenParticle(particleG); -
trunk/Examples/src/Analysis_Ex.cc
r270 r350 145 145 //***************************************************** 146 146 TIter itGen((TCollection*)GEN); 147 GenParticle *gen;147 TRootC::GenParticle *gen; 148 148 itGen.Reset(); 149 while( (gen = ( GenParticle*) itGen.Next()) )149 while( (gen = (TRootC::GenParticle*) itGen.Next()) ) 150 150 { 151 151 PID = gen->PID; // particle HEP ID number -
trunk/Makefile
r335 r350 16 16 SrcSuf = cc 17 17 18 CXXFLAGS += $(ROOTCFLAGS) -DDROP_CGAL -I. -Iinterface -IUtilities/mcfio -IUtilities/stdhep -IUtilities/Hector/include -IUtilities/CDFCones/interface -IExamples -IUtilities/FROG/Includes/FROG -IUtilities/ExRootAnalysis/interface -IUtilities/Fastjet/include/fastjet -IUtilities/Fastjet/plugins/CDFCones -IUtilities/Fastjet/plugins/CDFCones/interface -IUtilities/Fastjet/plugins/SISCone -IUtilities/CLHEP/Units 18 CXXFLAGS += $(ROOTCFLAGS) -DDROP_CGAL -I. -Iinterface -IUtilities/mcfio -IUtilities/stdhep -IUtilities/Hector/include -IUtilities/CDFCones/interface -IExamples -IUtilities/FROG/Includes/FROG -IUtilities/ExRootAnalysis/interface -IUtilities/Fastjet/include/fastjet -IUtilities/Fastjet/plugins/CDFCones -IUtilities/Fastjet/plugins/CDFCones/interface -IUtilities/Fastjet/plugins/SISCone -IUtilities/CLHEP/Units -IUtilities/HepMC/interface 19 19 # -pg -g 20 20 LIBS = $(ROOTLIBS) -lEG $(SYSLIBS) … … 121 121 tmp/src/LHEFConverter.$(ObjSuf): \ 122 122 src/LHEFConverter.$(SrcSuf) 123 tmp/src/HepMCConverter.$(ObjSuf): \ 124 src/HepMCConverter.$(SrcSuf) 123 125 tmp/src/FrogUtil.$(ObjSuf): \ 124 126 src/FrogUtil.$(SrcSuf) … … 129 131 tmp/src/D_Constants.$(ObjSuf): \ 130 132 src/D_Constants.$(SrcSuf) 133 tmp/src/HEPMCConverter.$(ObjSuf): \ 134 src/HEPMCConverter.$(SrcSuf) 131 135 tmp/src/TreeClasses.$(ObjSuf): \ 132 136 src/TreeClasses.$(SrcSuf) … … 304 308 Examples/src/Analysis_Ex.$(SrcSuf) \ 305 309 Examples/interface/Analysis_Ex.h 310 tmp/Utilities/HepMC/src/SearchVector.$(ObjSuf): \ 311 Utilities/HepMC/src/SearchVector.$(SrcSuf) 312 tmp/Utilities/HepMC/src/Units.$(ObjSuf): \ 313 Utilities/HepMC/src/Units.$(SrcSuf) 314 tmp/Utilities/HepMC/src/Polarization.$(ObjSuf): \ 315 Utilities/HepMC/src/Polarization.$(SrcSuf) 316 tmp/Utilities/HepMC/src/ParticleData.$(ObjSuf): \ 317 Utilities/HepMC/src/ParticleData.$(SrcSuf) 318 tmp/Utilities/HepMC/src/IO_PDG_ParticleDataTable.$(ObjSuf): \ 319 Utilities/HepMC/src/IO_PDG_ParticleDataTable.$(SrcSuf) 320 tmp/Utilities/HepMC/src/Flow.$(ObjSuf): \ 321 Utilities/HepMC/src/Flow.$(SrcSuf) 322 tmp/Utilities/HepMC/src/GenEvent.$(ObjSuf): \ 323 Utilities/HepMC/src/GenEvent.$(SrcSuf) 324 tmp/Utilities/HepMC/src/IO_Ascii.$(ObjSuf): \ 325 Utilities/HepMC/src/IO_Ascii.$(SrcSuf) 326 tmp/Utilities/HepMC/src/GenParticle.$(ObjSuf): \ 327 Utilities/HepMC/src/GenParticle.$(SrcSuf) 328 tmp/Utilities/HepMC/src/IO_GenEvent.$(ObjSuf): \ 329 Utilities/HepMC/src/IO_GenEvent.$(SrcSuf) 330 tmp/Utilities/HepMC/src/GenVertex.$(ObjSuf): \ 331 Utilities/HepMC/src/GenVertex.$(SrcSuf) 332 tmp/Utilities/HepMC/src/CompareGenEvent.$(ObjSuf): \ 333 Utilities/HepMC/src/CompareGenEvent.$(SrcSuf) 334 tmp/Utilities/HepMC/src/IO_AsciiParticles.$(ObjSuf): \ 335 Utilities/HepMC/src/IO_AsciiParticles.$(SrcSuf) 336 tmp/Utilities/HepMC/src/CommonIO.$(ObjSuf): \ 337 Utilities/HepMC/src/CommonIO.$(SrcSuf) 306 338 SOURCE_OBJ = \ 307 339 tmp/src/JetsUtil.$(ObjSuf) \ … … 312 344 tmp/src/VeryForward.$(ObjSuf) \ 313 345 tmp/src/LHEFConverter.$(ObjSuf) \ 346 tmp/src/HepMCConverter.$(ObjSuf) \ 314 347 tmp/src/FrogUtil.$(ObjSuf) \ 315 348 tmp/src/STDHEPConverter.$(ObjSuf) \ 316 349 tmp/src/HEPEVTConverter.$(ObjSuf) \ 317 350 tmp/src/D_Constants.$(ObjSuf) \ 351 tmp/src/HEPMCConverter.$(ObjSuf) \ 318 352 tmp/src/TreeClasses.$(ObjSuf) \ 319 353 tmp/src/LHCOConverter.$(ObjSuf) \ … … 400 434 tmp/Utilities/Fastjet/plugins/SISCone/src/momentum.$(ObjSuf) \ 401 435 tmp/Utilities/Fastjet/plugins/SISCone/src/quadtree.$(ObjSuf) \ 402 tmp/Examples/src/Analysis_Ex.$(ObjSuf) 436 tmp/Examples/src/Analysis_Ex.$(ObjSuf) \ 437 tmp/Utilities/HepMC/src/SearchVector.$(ObjSuf) \ 438 tmp/Utilities/HepMC/src/Units.$(ObjSuf) \ 439 tmp/Utilities/HepMC/src/Polarization.$(ObjSuf) \ 440 tmp/Utilities/HepMC/src/ParticleData.$(ObjSuf) \ 441 tmp/Utilities/HepMC/src/IO_PDG_ParticleDataTable.$(ObjSuf) \ 442 tmp/Utilities/HepMC/src/Flow.$(ObjSuf) \ 443 tmp/Utilities/HepMC/src/GenEvent.$(ObjSuf) \ 444 tmp/Utilities/HepMC/src/IO_Ascii.$(ObjSuf) \ 445 tmp/Utilities/HepMC/src/GenParticle.$(ObjSuf) \ 446 tmp/Utilities/HepMC/src/IO_GenEvent.$(ObjSuf) \ 447 tmp/Utilities/HepMC/src/GenVertex.$(ObjSuf) \ 448 tmp/Utilities/HepMC/src/CompareGenEvent.$(ObjSuf) \ 449 tmp/Utilities/HepMC/src/IO_AsciiParticles.$(ObjSuf) \ 450 tmp/Utilities/HepMC/src/CommonIO.$(ObjSuf) 403 451 404 452 tmp/Utilities/mcfio/mcfio_UserDictionary.$(ObjSuf): \ -
trunk/Utilities/ExRootAnalysis/interface/BlockClasses.h
r323 r350 177 177 //-------------------------------------------------------------------------- 178 178 class TRootGenParticle; 179 180 namespace TRootC { 179 181 class GenParticle: public TRootParticle { 180 182 … … 202 204 ClassDef(GenParticle, 1) 203 205 }; 206 } 204 207 205 208 //--------------------------------------------------------------------------- … … 210 213 TRootGenParticle() {_initialised=false;} 211 214 TRootGenParticle(const int pid): PID(pid) {_initialised=false;} 212 TRootGenParticle( GenParticle* part);215 TRootGenParticle(TRootC::GenParticle* part); 213 216 214 217 int PID; // particle HEP ID number [RawHepEventParticle::pid()] -
trunk/genMakefile.tcl
r296 r350 217 217 SrcSuf = cc 218 218 219 CXXFLAGS += $(ROOTCFLAGS) -DDROP_CGAL -I. -Iinterface -IUtilities/mcfio -IUtilities/stdhep -IUtilities/Hector/include -IUtilities/CDFCones/interface -IExamples -IUtilities/FROG/Includes/FROG -IUtilities/ExRootAnalysis/interface -IUtilities/Fastjet/include/fastjet -IUtilities/Fastjet/plugins/CDFCones -IUtilities/Fastjet/plugins/CDFCones/interface -IUtilities/Fastjet/plugins/SISCone -IUtilities/CLHEP/Units 219 CXXFLAGS += $(ROOTCFLAGS) -DDROP_CGAL -I. -Iinterface -IUtilities/mcfio -IUtilities/stdhep -IUtilities/Hector/include -IUtilities/CDFCones/interface -IExamples -IUtilities/FROG/Includes/FROG -IUtilities/ExRootAnalysis/interface -IUtilities/Fastjet/include/fastjet -IUtilities/Fastjet/plugins/CDFCones -IUtilities/Fastjet/plugins/CDFCones/interface -IUtilities/Fastjet/plugins/SISCone -IUtilities/CLHEP/Units -IUtilities/HepMC/interface 220 220 # -pg -g 221 221 LIBS = $(ROOTLIBS) -lEG $(SYSLIBS) … … 239 239 dictDeps {DICT} {Utilities/ExRootAnalysis/src/*LinkDef.h} {src/*LinkDef.h} {Examples/src/*LinkDef.h} 240 240 241 sourceDeps {SOURCE} {src/*.cc} {Utilities/ExRootAnalysis/src/*.cc} {Utilities/Hector/src/*.cc} {Utilities/CDFCones/src/*cc} {Utilities/Fastjet/src/*.cc} {Utilities/Fastjet/plugins/CDFCones/*.cc} {Utilities/Fastjet/plugins/CDFCones/src/*.cc} {Utilities/Fastjet/plugins/SISCone/*.cc} {Utilities/Fastjet/plugins/SISCone/src/*.cc} {Examples/src/*.cc} 241 sourceDeps {SOURCE} {src/*.cc} {Utilities/ExRootAnalysis/src/*.cc} {Utilities/Hector/src/*.cc} {Utilities/CDFCones/src/*cc} {Utilities/Fastjet/src/*.cc} {Utilities/Fastjet/plugins/CDFCones/*.cc} {Utilities/Fastjet/plugins/CDFCones/src/*.cc} {Utilities/Fastjet/plugins/SISCone/*.cc} {Utilities/Fastjet/plugins/SISCone/src/*.cc} {Examples/src/*.cc} {Utilities/HepMC/src/*.cc} 242 242 243 243 stdhepDeps -
trunk/interface/JetsUtil.h
r319 r350 83 83 vector<fastjet::PseudoJet> RunJetsResol(const vector<fastjet::PseudoJet>& input_particles); 84 84 85 void RunJetBtagging(ExRootTreeWriter *treeWriter, ExRootTreeBranch *branchJet,const vector<fastjet::PseudoJet> & sorted_jets,const TSimpleArray< GenParticle> & NFCentralQ, const vector<int> &NTrackJet, const vector<float> &EHADEEM);85 void RunJetBtagging(ExRootTreeWriter *treeWriter, ExRootTreeBranch *branchJet,const vector<fastjet::PseudoJet> & sorted_jets,const TSimpleArray<TRootC::GenParticle> & NFCentralQ, const vector<int> &NTrackJet, const vector<float> &EHADEEM); 86 86 87 87 void RunTauJets(ExRootTreeWriter *treeWriter, ExRootTreeBranch *branchTauJet,const vector<fastjet::PseudoJet> & sorted_jets,const vector<PhysicsTower> & towers, const vector<TRootTracks> & TrackCentral, const vector<int> &NTrackJet, const vector<float> &EHADEEM); -
trunk/interface/SmearUtil.h
r332 r350 227 227 228 228 /// b-jets 229 int Bjets(const TSimpleArray< GenParticle> &subarray, const float& eta, const float& phi);229 int Bjets(const TSimpleArray<TRootC::GenParticle> &subarray, const float& eta, const float& phi); 230 230 231 231 /// b-tag efficiency and misidentification 232 bool Btaggedjet(const TLorentzVector &JET, const TSimpleArray< GenParticle> &subarray);232 bool Btaggedjet(const TLorentzVector &JET, const TSimpleArray<TRootC::GenParticle> &subarray); 233 233 234 234 /// Lepton isolation based on tracking -
trunk/src/HEPEVTConverter.cc
r295 r350 176 176 177 177 ExRootTreeWriter *treeWriter = new ExRootTreeWriter(outputFileName, "GEN"); 178 ExRootTreeBranch *branchGen = treeWriter->NewBranch("Particle", GenParticle::Class());178 ExRootTreeBranch *branchGen = treeWriter->NewBranch("Particle", TRootC::GenParticle::Class()); 179 179 180 180 ifstream infile(inputFileList.c_str()); … … 211 211 Float_t signEta; 212 212 213 GenParticle *element;213 TRootC::GenParticle *element; 214 214 215 215 // Loop over all events … … 222 222 for(particle = 0; particle < event.Nhep; ++particle) 223 223 { 224 element = ( GenParticle*) branchGen->NewEntry();224 element = (TRootC::GenParticle*) branchGen->NewEntry(); 225 225 226 226 element->PID = event.Idhep[particle]; -
trunk/src/HEPMCConverter.cc
r347 r350 55 55 ExRootTreeWriter *treeWriter = new ExRootTreeWriter(outputFileName, "GEN"); 56 56 ExRootTreeBranch *branchGenEvent = treeWriter->NewBranch("Event", TRootGenEvent::Class()); 57 ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", GenParticle::Class());57 ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", TRootC::GenParticle::Class()); 58 58 59 59 // Open the datafile list -
trunk/src/JetsUtil.cc
r315 r350 190 190 191 191 192 void JetsUtil::RunJetBtagging(ExRootTreeWriter *treeWriter, ExRootTreeBranch *branchJet,const vector<fastjet::PseudoJet> & sorted_jets,const TSimpleArray< GenParticle>& NFCentralQ, const vector<int> &NTrackJet, const vector<float> &EHADEEM)192 void JetsUtil::RunJetBtagging(ExRootTreeWriter *treeWriter, ExRootTreeBranch *branchJet,const vector<fastjet::PseudoJet> & sorted_jets,const TSimpleArray<TRootC::GenParticle>& NFCentralQ, const vector<int> &NTrackJet, const vector<float> &EHADEEM) 193 193 { 194 194 TRootJet *elementJet; -
trunk/src/STDHEPConverter.cc
r295 r350 62 62 else Nmax = myhepevt.nhep; 63 63 64 GenParticle *element;64 TRootC::GenParticle *element; 65 65 66 66 Double_t signPz; … … 70 70 for(number = 0; number < Nmax; ++number) 71 71 { 72 element = static_cast< GenParticle*>(branch->NewEntry());72 element = static_cast<TRootC::GenParticle*>(branch->NewEntry()); 73 73 74 74 element->PID = myhepevt.idhep[number]; … … 119 119 ExRootTreeBranch *branchGenEvent = treeWriter->NewBranch("Event", TRootGenEvent::Class()); 120 120 // generated particles from HEPEVT 121 ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", GenParticle::Class());121 ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", TRootC::GenParticle::Class()); 122 122 123 123 // Open a stream connected to an event file: -
trunk/src/SmearUtil.cc
r333 r350 1064 1064 //used by Btaggedjet 1065 1065 ///// Attention : bug removed => CONERADIUS/2 -> CONERADIUS !! 1066 int RESOLution::Bjets(const TSimpleArray< GenParticle> &subarray, const float& eta, const float& phi) {1066 int RESOLution::Bjets(const TSimpleArray<TRootC::GenParticle> &subarray, const float& eta, const float& phi) { 1067 1067 float emax=0; 1068 1068 int Ppid=0; … … 1081 1081 1082 1082 //******************** Simulates the b-tagging efficiency for real bjet, or the misendentification for other jets**************** 1083 bool RESOLution::Btaggedjet(const TLorentzVector &JET, const TSimpleArray< GenParticle> &subarray) {1083 bool RESOLution::Btaggedjet(const TLorentzVector &JET, const TSimpleArray<TRootC::GenParticle> &subarray) { 1084 1084 if( rand()%100 < (BTAG_b+1) && Bjets(subarray,JET.Eta(),JET.Phi())==pB ) return true; // b-tag of b-jets is 40% 1085 1085 else if( rand()%100 < (BTAG_mistag_c+1) && Bjets(subarray,JET.Eta(),JET.Phi())==pC ) return true; // b-tag of c-jets is 10%
Note:
See TracChangeset
for help on using the changeset viewer.