00001 #ifndef RecoTauTag_RecoTau_RecoTauDiscriminantFunctions_h 00002 #define RecoTauTag_RecoTau_RecoTauDiscriminantFunctions_h 00003 00004 /* 00005 * RecoTauDiscriminantFunctions 00006 * 00007 * Collection of unary functions used to compute tau discriminant values. 00008 * Each function here (may be) used in an MVA discriminator. 00009 * 00010 * The functions all have the form 00011 * ReturnType Function(const PFTau& tau) 00012 * where ReturnType is either vector<double> or double. 00013 * 00014 * Author: Evan K. Friis, UC Davis 00015 * 00016 * $Id $ 00017 */ 00018 00019 #include "DataFormats/TauReco/interface/PFTau.h" 00020 #include <vector> 00021 00022 namespace reco { namespace tau { namespace disc { 00023 00024 // Save typing 00025 typedef const PFTau& Tau; 00026 typedef std::vector<double> VDouble; 00027 00030 PFCandidateRef mainTrack(const PFTau& tau); 00031 00032 // HPStanc variables 00033 double JetPt(Tau tau); 00034 double JetEta(Tau tau); 00035 double JetWidth(Tau tau); 00036 00037 double SignalPtFraction(Tau tau); 00038 double IsolationChargedPtFraction(Tau tau); 00039 double IsolationECALPtFraction(Tau tau); 00040 double IsolationNeutralHadronPtFraction(Tau tau); 00041 double MainTrackPtFraction(Tau tau); 00042 double IsolationChargedAveragePtFraction(Tau tau); 00043 double ScaledEtaJetCollimation(Tau tau); 00044 double ScaledPhiJetCollimation(Tau tau); 00045 double ScaledOpeningDeltaR(Tau tau); 00046 VDouble Dalitz2(Tau tau); 00047 00048 // Sum of charged isolation activity above/below 1 GeV 00049 double IsolationChargedSumHard(Tau tau); 00050 double IsolationChargedSumSoft(Tau tau); 00051 double IsolationChargedSumHardRelative(Tau tau); 00052 double IsolationChargedSumSoftRelative(Tau tau); 00053 00054 // Sum of ecal isolation activity above/below 1.5 GeV 00055 double IsolationECALSumHard(Tau tau); 00056 double IsolationECALSumSoft(Tau tau); 00057 double IsolationECALSumHardRelative(Tau tau); 00058 double IsolationECALSumSoftRelative(Tau tau); 00059 00060 // Fraction of signal energy carried by pizeros. 00061 double EMFraction(Tau tau); 00062 00063 // Absolute significance of impact parameter 00064 double ImpactParameterSignificance(Tau tau); 00065 00066 double Pt(Tau tau) { return tau.pt(); } 00067 double Eta(Tau tau) { return tau.eta(); } 00068 double Mass(Tau tau) { return tau.mass(); } 00069 double DecayMode(Tau tau) { return tau.decayMode(); } 00070 00071 // Number of objects in isolation cone 00072 double OutlierN(Tau); 00073 00074 // Number of charged objects in isolation cone 00075 double OutlierNCharged(Tau); 00076 00077 double OutlierSumPt(Tau); 00078 double ChargedOutlierSumPt(Tau); 00079 double NeutralOutlierSumPt(Tau); 00080 00081 // Pt of the main track 00082 double MainTrackPt(Tau); 00083 // Eta of the main track 00084 double MainTrackEta(Tau); 00085 // Angle of main track to tau axis 00086 double MainTrackAngle(Tau); 00087 00088 // Exactly the same as "Mass", needed for backwards compatability 00089 double InvariantMassOfSignal(Tau tau) { return tau.mass(); } 00090 00091 // Quanitites of tracks 00092 VDouble TrackPt(Tau); 00093 VDouble TrackAngle(Tau); 00094 VDouble TrackEta(Tau); 00095 00096 // Quanitites of PiZeros 00097 VDouble PiZeroPt(Tau); 00098 VDouble PiZeroAngle(Tau); 00099 VDouble PiZeroEta(Tau); 00100 00101 // Isolation quantities 00102 VDouble OutlierPt(Tau); 00103 VDouble OutlierAngle(Tau); 00104 VDouble ChargedOutlierPt(Tau); 00105 VDouble ChargedOutlierAngle(Tau); 00106 VDouble NeutralOutlierPt(Tau); 00107 VDouble NeutralOutlierAngle(Tau); 00108 00109 // Dalitz for three prongs 00110 VDouble Dalitz(Tau); 00111 00112 // Deprecated functions needed for backwards compatability 00113 VDouble FilteredObjectPt(Tau); 00114 VDouble GammaOccupancy(Tau); 00115 VDouble GammaPt(Tau); 00116 VDouble InvariantMassOfSignalWithFiltered(Tau); 00117 VDouble InvariantMass(Tau); 00118 VDouble OutlierMass(Tau); 00119 00120 }}} // end namespace reco::tau::disc 00121 #endif