@@ -113,21 +113,11 @@ def prepare_objects(self: Producer, events: ak.Array, results: SelectionResult =
113
113
if "VetoLepton" not in events .fields and "VetoElectron" in events .fields and "VetoMuon" in events .fields :
114
114
# combine VetoElectron and VetoMuon into a single object (VetoLepton)
115
115
veto_lepton = ak .concatenate ([events .VetoMuon * 1 , events .VetoElectron * 1 ], axis = - 1 )
116
- # lepton_fields = set(events.VetoMuon.fields).intersection(events.VetoElectron.fields)
117
- # veto_lepton = ak.concatenate([
118
- # ak.zip({f: events.VetoMuon[f] for f in lepton_fields}),
119
- # ak.zip({f: events.VetoElectron[f] for f in lepton_fields}),
120
- # ], axis=-1)
121
116
events = set_ak_column (events , "VetoLepton" , veto_lepton [ak .argsort (veto_lepton .pt , ascending = False )])
122
117
123
118
if "Lepton" not in events .fields and "Electron" in events .fields and "Muon" in events .fields :
124
119
# combine Electron and Muon into a single object (Lepton)
125
120
lepton = ak .concatenate ([events .Muon * 1 , events .Electron * 1 ], axis = - 1 )
126
- # lepton_fields = set(events.Muon.fields).intersection(events.Electron.fields)
127
- # lepton = ak.concatenate([
128
- # ak.zip({f: events.Muon[f] for f in lepton_fields}),
129
- # ak.zip({f: events.Electron[f] for f in lepton_fields}),
130
- # ], axis=-1)
131
121
events = set_ak_column (events , "Lepton" , lepton [ak .argsort (lepton .pt , ascending = False )])
132
122
133
123
# transform MET into 4-vector
0 commit comments