yippy.stellar_intens#

Module for handling stellar intensity data from stellar_intens files.

Classes#

StellarIntens

Class to handle and interpolate stellar intensity data.

Module Contents#

class yippy.stellar_intens.StellarIntens(yip_dir, stellar_intens_file, stellar_diam_file)[source]#

Class to handle and interpolate stellar intensity data.

This class loads stellar intensity data and corresponding stellar diameters, providing an interpolation interface to get the stellar intensity map for a given stellar diameter.

Attributes:
ln_interp (CubicSpline):

A spline interpolator that operates on the natural logarithm of the stellar intensities to ensure that interpolated values are non-negative.

Args:
yip_dir (Path):

Path to the directory containing the yield input package (YIP).

stellar_intens_file (str):

Filename of the FITS file containing the stellar intensity data.

stellar_diam_file (str):

Filename of the FITS file containing the stellar diameters.

Parameters:
diams#
psfs#
ln_interp#
__call__(stellar_diam, lam=None, D=None)[source]#

Returns the stellar intensity map at a specified stellar diameter.

Stellar intensity is interpolated based on a specified diameter using the previously configured cubic spline interpolator. The interpolation considers the logarithm of the intensity to ensure that all computed values are positive.

Args:
stellar_diam (Quantity):

The desired stellar diameter for which to retrieve the intensity map, in units of lambda/D.

lam (Quantity, optional):

Wavelength of observation, required if stellar_diam is in angular units.

D (Quantity, optional):

Diameter of the telescope, required if stellar_diam is in angular units.

Returns:
NDArray:

An interpolated 2D map of the stellar intensity at the given stellar diameter.

Parameters:

stellar_diam (astropy.units.Quantity)