Skip to content

Commit

Permalink
Use tuples for slice dimensions
Browse files Browse the repository at this point in the history
  • Loading branch information
jvansanten committed Jan 23, 2025
1 parent 4601d19 commit 0b99c92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion toise/figures/diffuse/single_power_law.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def make_components(aeffs, emin=1e2, emax=1e11):
aeff, muon_aeff = copy(aeffs)
ebins = aeff.bin_edges[0]
mask = (ebins[1:] <= emax) & (ebins[:-1] >= emin)
aeff.values *= mask[[None] + [slice(None)] + [None] * (aeff.values.ndim - 2)]
aeff.values *= mask[(None, slice(None),) + (None,) * (aeff.values.ndim - 2)]

atmo = diffuse.AtmosphericNu.conventional(aeff, 1, veto_threshold=None)
atmo.prior = lambda v, **kwargs: -((v - 1) ** 2) / (2 * 0.1**2)
Expand Down

0 comments on commit 0b99c92

Please sign in to comment.