iq_readout.pdfs.pdf_from_hist2d#

pdf_from_hist2d(z, bins_x, bins_y, pdf_values)[source]#

Returns the PDF value from the 2D histogram bins closest to x.

Parameters:
znp.ndarray(…, 2)

Points in the 2D space.

bins_x: np.ndarray(n_bins_x)

Centers of the X-axis bins of the 2D histogram.

bins_y: np.ndarray(n_bins_y)

Centers of the Y-axis bins of the 2D histogram.

pdf_values: np.ndarray(n_bins_x, n_bins_y)

Normalized counts of the 2D histogram.

Returns:
prob: np.ndarray(…)

Values of the probability density function.