wf_psf.utils.preprocessing
Preprocessing.
A module with utils to preprocess data.
- Author:
Tobias Liaudat <tobias.liaudat@cea.fr>
Functions
|
Compute Zernike 4 value for a given defocus in WaveDifff conventions. |
|
Compute Zernike 4 value for a given defocus in zemax conventions. |
|
Compute Zernike 1(2) for a given shifts in x(y) in WaveDifff conventions. |
- wf_psf.utils.preprocessing.defocus_to_zk4_wavediff(dz, tel_focal_length=24.5, tel_diameter=1.2)[source]
Compute Zernike 4 value for a given defocus in WaveDifff conventions.
All inputs should be in [m].
The output zernike coefficient is in [um] units as expected by wavediff.
- wf_psf.utils.preprocessing.defocus_to_zk4_zemax(dz, tel_focal_length=24.5, tel_diameter=1.2)[source]
Compute Zernike 4 value for a given defocus in zemax conventions.
All inputs should be in [m].
- wf_psf.utils.preprocessing.shift_x_y_to_zk1_2_wavediff(dxy, tel_focal_length=24.5, tel_diameter=1.2)[source]
Compute Zernike 1(2) for a given shifts in x(y) in WaveDifff conventions.
All inputs should be in [m]. A displacement of, for example, 0.5 pixels should be scaled with the corresponding pixel scale, e.g. 12[um], to get a displacement in [m], which would be dxy=0.5*12e-6.
The output zernike coefficient is in [um] units as expected by wavediff.
To apply match the centroid with a dx that has a corresponding zk1, the new PSF should be generated with -zk1.
The same applies to dy and zk2.