MomentMorphInterpolator

class pyirf.interpolation.MomentMorphInterpolator(grid_points, bin_edges, binned_pdf, normalization=PDFNormalization.AREA)[source]

Bases: DiscretePDFInterpolator

Interpolator class providing Moment Morphing to interpolate discretized PDFs.

Methods Summary

__call__(target_point)

Providing a common __call__ interface

interpolate(target_point)

Takes a grid of binned pdfs for a bunch of different parameters and interpolates it to given value of those parameters.

Methods Documentation

__call__(target_point)

Providing a common __call__ interface

Parameters:
target_point: np.ndarray, shape=(1, n_dims)

Target for inter-/extrapolation When target_point is outside of the grids convex hull but extrapolator is None

Returns:
Interpolated result.
interpolate(target_point)[source]

Takes a grid of binned pdfs for a bunch of different parameters and interpolates it to given value of those parameters. This function calls implementations of the moment morphing interpolation pocedure introduced in [1].

Parameters:
target_point: numpy.ndarray, shape=(1, n_dims)

Value for which the interpolation is performed (target point)

Returns:
f_new: numpy.ndarray, shape=(1,…,n_bins)

Interpolated and binned pdf

References

[1]

M. Baak, S. Gadatsch, R. Harrington and W. Verkerke (2015). Interpolation between multi-dimensional histograms using a new non-linear moment morphing method Nucl. Instrum. Methods Phys. Res. A 771, 39-48. https://doi.org/10.1016/j.nima.2014.10.033