5 |
|
#include "MitAna/DataCont/interface/ObjArray.h" |
6 |
|
#include "MitPhysics/Utils/interface/IsolationTools.h" |
7 |
|
#include "MitCommon/MathTools/interface/MathUtils.h" |
8 |
– |
#include "MitPhysics/Utils/interface/MuonTools.h" |
8 |
|
|
9 |
|
using namespace mithep; |
10 |
|
|
16 |
|
fPrintDebug(false), |
17 |
|
fMuonName(Names::gkMuonBrn), |
18 |
|
fCleanMuonsName(Names::gkCleanMuonsName), |
20 |
– |
fMuonIDType("Tight"), |
21 |
– |
fMuonIsoType("TrackCalo"), |
19 |
|
fMuons(0), |
20 |
|
fTrackIsolationCut(3.0), |
21 |
|
fCaloIsolationCut(3.0), |
22 |
|
fCombIsolationCut(-1.0), |
23 |
< |
fTMOneStationLooseCut(false), |
23 |
> |
fTMOneStationLooseCut(true), |
24 |
|
fTMOneStationTightCut (false), |
25 |
< |
fTM2DCompatibilityLooseCut(false), |
25 |
> |
fTM2DCompatibilityLooseCut(true), |
26 |
|
fTM2DCompatibilityTightCut(false), |
27 |
+ |
fMuonSlidingIso(true), |
28 |
|
fMuonPtMin(10), |
29 |
|
fNEventsProcessed(0) |
30 |
|
{ |
52 |
|
cerr << endl << "MuonIDMod : Process Event " << fNEventsProcessed << " Time: " << ctime(&systime) << endl; |
53 |
|
} |
54 |
|
|
57 |
– |
MuonTools myMuonTools; |
58 |
– |
|
55 |
|
//Get Muons |
56 |
|
LoadBranch(fMuonName); |
57 |
|
ObjArray<Muon> *CleanMuons = new ObjArray<Muon>; |
72 |
|
if(MuonClass == 0) allCuts = true; |
73 |
|
|
74 |
|
// Isolation requirements |
75 |
< |
if(fCombIsolationCut < 0.0){ |
75 |
> |
if(fMuonSlidingIso == true){ // Fix version |
76 |
> |
double totalIso = 1.0 * mu->IsoR03SumPt() + |
77 |
> |
1.0 * mu->IsoR03EmEt() + |
78 |
> |
1.0 * mu->IsoR03HadEt(); |
79 |
> |
bool theIso = false; |
80 |
> |
if((totalIso < (mu->Pt()-10.0)*5.0/15.0) || |
81 |
> |
(totalIso < 5.0 && mu->Pt() > 25)) theIso = true; |
82 |
> |
if(theIso == false) allCuts = false; |
83 |
> |
} |
84 |
> |
else if(fCombIsolationCut < 0.0){ // Different tracker and Cal iso |
85 |
|
if(mu->IsoR03SumPt() >= fTrackIsolationCut) allCuts = false; |
86 |
|
if(mu->IsoR03EmEt() + |
87 |
|
mu->IsoR03HadEt() >= fCaloIsolationCut) allCuts = false; |
88 |
|
} |
89 |
< |
else { |
89 |
> |
else { // Combined iso |
90 |
|
if(1.0 * mu->IsoR03SumPt() + |
91 |
|
1.0 * mu->IsoR03EmEt() + |
92 |
< |
1.0 * mu->IsoR03HadEt() >= fCombIsolationCut) allCuts = false; |
88 |
< |
|
92 |
> |
1.0 * mu->IsoR03HadEt() >= fCombIsolationCut) allCuts = false; |
93 |
|
} |
94 |
|
|
95 |
|
// Muon chambers and calo compatibility requirements |