Skip to content

Commit

Permalink
unit tests working locally
Browse files Browse the repository at this point in the history
  • Loading branch information
HenryDayHall committed Apr 8, 2023
1 parent ed800ca commit 497b528
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions jet_tools/MassPeaks.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,8 @@ def combined_jet_mass(eventWise, jet_name, jet_idxs,
"""
assert eventWise.selected_event is not None
try:
jet_idxs = list(jet_idxs)
except TypeError:
pass
if hasattr(jet_idxs, '__len__') and not len(jet_idxs):
return 0.
if signal_background == 'both': # jsut use the jet roots
jet_roots = getattr(eventWise, jet_name + "_Parent") == -1
e = ak.flatten(getattr(eventWise, jet_name + "_Energy")[jet_roots])[jet_idxs]
Expand Down

0 comments on commit 497b528

Please sign in to comment.