calc_refined_offsets
- jwst.wfs_combine.wfs_combine.calc_refined_offsets(sci_nai_1, sci_nai_2, off_x, off_y, psf_size)[source]
Get overlap of the two images and calculate 2D cross correlation between the two subarrays.
The overlap image is based on the offsets. Then we slice on a subarray around the peak of the cross correlation image and find the first moment. The first moment provides a high S/N measurement of the offset between the two images.
- Parameters:
- sci_nai_1ndarray
Nominally aligned, interpolated SCI subarray (float) for image 1
- sci_nai_2ndarray
Nominally aligned, interpolated SCI subarray (float) for image 2
- off_xint
Offset in x-direction
- off_yint
Offset in y-direction
- psf_sizeint
The worst case PSF size
- Returns:
- refined_xfloat
The refined value of the x offset
- refined_yfloat
The refined value of the y offset