Fork me on GitHub

Changeset 350 in svn for trunk/src


Ignore:
Timestamp:
May 6, 2009, 8:57:21 PM (16 years ago)
Author:
severine ovyn
Message:

first test HepMC

Location:
trunk/src
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/HEPEVTConverter.cc

    r295 r350  
    176176
    177177  ExRootTreeWriter *treeWriter = new ExRootTreeWriter(outputFileName, "GEN");
    178   ExRootTreeBranch *branchGen = treeWriter->NewBranch("Particle", GenParticle::Class());
     178  ExRootTreeBranch *branchGen = treeWriter->NewBranch("Particle", TRootC::GenParticle::Class());
    179179 
    180180  ifstream infile(inputFileList.c_str());
     
    211211      Float_t signEta;
    212212     
    213       GenParticle *element;
     213      TRootC::GenParticle *element;
    214214     
    215215      // Loop over all events
     
    222222          for(particle = 0; particle < event.Nhep; ++particle)
    223223            {
    224               element = (GenParticle*) branchGen->NewEntry();
     224              element = (TRootC::GenParticle*) branchGen->NewEntry();
    225225             
    226226              element->PID = event.Idhep[particle];     
  • trunk/src/HEPMCConverter.cc

    r347 r350  
    5555  ExRootTreeWriter *treeWriter = new ExRootTreeWriter(outputFileName, "GEN");
    5656  ExRootTreeBranch *branchGenEvent = treeWriter->NewBranch("Event", TRootGenEvent::Class());
    57   ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", GenParticle::Class());
     57  ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", TRootC::GenParticle::Class());
    5858 
    5959  // Open the datafile list
  • trunk/src/JetsUtil.cc

    r315 r350  
    190190
    191191
    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)
     192void 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)
    193193{
    194194  TRootJet *elementJet;
  • trunk/src/STDHEPConverter.cc

    r295 r350  
    6262  else Nmax = myhepevt.nhep;
    6363
    64   GenParticle *element;
     64  TRootC::GenParticle *element;
    6565
    6666  Double_t signPz;
     
    7070  for(number = 0; number < Nmax; ++number)
    7171  {
    72     element = static_cast<GenParticle*>(branch->NewEntry());
     72    element = static_cast<TRootC::GenParticle*>(branch->NewEntry());
    7373
    7474    element->PID = myhepevt.idhep[number];
     
    119119  ExRootTreeBranch *branchGenEvent = treeWriter->NewBranch("Event", TRootGenEvent::Class());
    120120  // generated particles from HEPEVT
    121   ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", GenParticle::Class());
     121  ExRootTreeBranch *branchGenParticle = treeWriter->NewBranch("Particle", TRootC::GenParticle::Class());
    122122 
    123123  // Open a stream connected to an event file:
  • trunk/src/SmearUtil.cc

    r333 r350  
    10641064//used by Btaggedjet
    10651065///// Attention : bug removed => CONERADIUS/2 -> CONERADIUS !!
    1066 int RESOLution::Bjets(const TSimpleArray<GenParticle> &subarray, const float& eta, const float& phi) {
     1066int RESOLution::Bjets(const TSimpleArray<TRootC::GenParticle> &subarray, const float& eta, const float& phi) {
    10671067  float emax=0;
    10681068  int Ppid=0;
     
    10811081
    10821082//******************** 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) {
     1083bool RESOLution::Btaggedjet(const TLorentzVector &JET, const TSimpleArray<TRootC::GenParticle> &subarray) {
    10841084  if(      rand()%100 < (BTAG_b+1)    && Bjets(subarray,JET.Eta(),JET.Phi())==pB ) return true; // b-tag of b-jets is 40%
    10851085  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.