Changeset 01f9722 in git
- Timestamp:
- Aug 13, 2018, 3:01:20 PM (6 years ago)
- Branches:
- ImprovedOutputFile, Timing, dual_readout, llp, master
- Children:
- 1d9c62a, 9047a02
- Parents:
- cdbca0d
- Location:
- classes
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
classes/DelphesClasses.h
rcdbca0d r01f9722 75 75 76 76 Float_t Weight; // weight for the event | hepup.XWGTUP 77 Float_t CrossSection; // cross-section (read from init, implemented only for Wizard evgen) 77 78 Float_t ScalePDF; // scale in GeV used in the calculation of the PDFs in the event | hepup.SCALUP 78 79 Float_t AlphaQED; // value of the QED coupling used in the event | hepup.AQEDUP -
classes/DelphesLHEFReader.cc
rcdbca0d r01f9722 31 31 #include <iostream> 32 32 #include <sstream> 33 #include <string> 33 34 34 35 #include <stdio.h> … … 54 55 DelphesLHEFReader::DelphesLHEFReader() : 55 56 fInputFile(0), fBuffer(0), fPDG(0), 56 fEventReady(kFALSE), fEventCounter(-1), fParticleCounter(-1) 57 fEventReady(kFALSE), fEventCounter(-1), fParticleCounter(-1), fCrossSection(1) 58 57 59 { 58 60 fBuffer = new char[kBufferSize]; … … 105 107 if(!fgets(fBuffer, kBufferSize, fInputFile)) return kFALSE; 106 108 109 // read cross section string from LHE file header (meant to work on Wizard output only) 110 if(strstr(fBuffer, "<xsecinfo ") && fEventCounter < 0) 111 { 112 DelphesStream bufferStream(fBuffer); 113 114 string buf = fBuffer; 115 string xsecstr="totxsec"; 116 117 if (buf.find(xsecstr) != string::npos) 118 { 119 buf = buf.substr(buf.find(xsecstr) + xsecstr.length()+1); 120 unsigned first = buf.find_first_of("\"")+1; 121 unsigned last = buf.find_last_of("\""); 122 xsecstr = buf.substr(first,last-first); 123 fCrossSection = stod(xsecstr); 124 } 125 } 126 107 127 if(strstr(fBuffer, "<event>")) 108 128 { … … 110 130 fEventCounter = 1; 111 131 } 132 112 133 else if(fEventCounter > 0) 113 134 { … … 206 227 element->ProcessID = fProcessID; 207 228 element->Weight = fWeight; 229 element->CrossSection = fCrossSection; 230 208 231 element->ScalePDF = fScalePDF; 209 232 element->AlphaQED = fAlphaQED; -
classes/DelphesLHEFReader.h
rcdbca0d r01f9722 79 79 80 80 int fParticleCounter, fProcessID; 81 double f Weight, fScalePDF, fAlphaQCD, fAlphaQED;81 double fCrossSection, fWeight, fScalePDF, fAlphaQCD, fAlphaQED; 82 82 83 83 int fPID, fStatus, fM1, fM2, fC1, fC2;
Note:
See TracChangeset
for help on using the changeset viewer.