From 9c5d9424e06c4b12d00a2ef055d62f78bdae0bc3 Mon Sep 17 00:00:00 2001 From: LukasK13 Date: Thu, 18 Jun 2020 09:05:10 +0200 Subject: [PATCH] Bugfix: Calculate center index after oversampling --- esbo_etc/classes/psf/Airy.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esbo_etc/classes/psf/Airy.py b/esbo_etc/classes/psf/Airy.py index 7ba5911..ce78d08 100644 --- a/esbo_etc/classes/psf/Airy.py +++ b/esbo_etc/classes/psf/Airy.py @@ -236,7 +236,7 @@ class Airy(IPSF): # Oversample the reduced mask mask_red_os = self._rebin(mask_red, self.__osf).view(PixelMask) # Calculate the new PSF-center indices of the reduced mask - psf_center_ind = [x * self.__osf for x in psf_center_ind] + psf_center_ind = [(x + 0.5) * self.__osf - 0.5 for x in psf_center_ind] reduced_observation_angle_pixel = (mask.pixel_size / ( self.__f_number * self.__d_aperture) * self.__d_aperture / self.__wl).decompose()