psf_single_doe_spectral
- colibri.optics.functional.psf_single_doe_spectral(height_map, aperture, refractive_index, wavelengths, source_distance, sensor_distance, pixel_size, approximation='fresnel')[source]
Calculate the point spread function (PSF) of an optical system comprising a diffractive optical element (DOE) for spectral imaging. The PSF is calculated as follows:
\[\mathbf{H}(\learnedOptics) = |\mathcal{P_2}(z_2, \lambda) \left( \mathcal{P_1}(z_1, \lambda)(\delta) * \learnedOptics \right)|^2\]where \(\mathcal{P_1}\) is an operator that describes the propagation of light from the source to the DOE at a distance \(z_1\), \(\mathcal{P_2}\) is an operator that describes the propagation of light from the DOE to the sensor at a distance \(z_2\), and \(\learnedOptics\) is the DOE.
The operator \(\mathcal{P_2}\) depends on the given approximation:
- Parameters:
height_map (torch.Tensor) – Height map of the DOE.
aperture (torch.Tensor) – Aperture mask.
refractive_index (callable) – Function to calculate the refractive index.
wavelengths (torch.Tensor) – Wavelengths in meters.
source_distance (float) – Distance from the source to the DOE in meters.
sensor_distance (float) – Distance from the DOE to the sensor in meters.
pixel_size (float) – Pixel size in meters.
approximation (str) – Type of propagation model (‘fresnel’, ‘angular_spectrum’, ‘fraunhofer’).
- Returns:
PSF of the optical system, normalized to unit energy.
- Return type:
torch.Tensor