Commit 07264375 authored by Arthur Vigan's avatar Arthur Vigan
Browse files

Merge branch 'master' into avigan

parents 030850fe 70831f39
No preview for this file type
......@@ -28,6 +28,12 @@ rot_flag = 1
#Flag for missing segments (1 = missing segments ; 0 = no missing segments)
miss_flag = 1
# Configuration of M1 amplitude errors: 1 & 2 refer to two different missing segment configurations
# A & B refer to two different reflectivity errors configurations
# In both cases there is a uniform distribution of reflectivity for each segment that ranges between 100% and 95%.
# This 95% value comes from paper "Towards a Stray Light Analysis of the ELT" from R. Holzlöhner at ESO
# Reflectivity errors are randomly distributed over M1, i.e., I have not assumed any specific recoating strategy (spiral, etc.)
ELT_amplitude_errors = 'CONFIG_1A'
#Flag for E-ELT M1 phase aberrations
eeltphase_flag = 1
......@@ -62,7 +68,7 @@ RMS_gamma = 1 #%0.6;%0.3;
# Gamma factor to increase the strengh of the AO residuals (for DSP_gamma >1)
DSP_gamma = 1
APODIZER = 'SP_1'
APODIZER = 'SP_2'
#disp(['Observation time will be: ' num2str(Delta_HA) 'h'])
#disp(['Observation starts ' num2str(HA_offset) 'h before meridian'])
......@@ -91,31 +97,29 @@ T_exp = 1/60
N_exp = np.int(T_obs/T_exp)# %60 exposures per hour = 1 per minute
##############################################################################
BAND = 'TEST_K' # %Choose between the bands defined hereafter (use a valid string)
BAND = 'TEST_H' # %Choose between the bands defined hereafter (use a valid string)
### Bands ###
VIS_band = [0.463, 0.641, 0.820, 3500]
IZJ_band = [0.810, 1.090, 1.369, 3500]
HK_band = [1.45, 1.950, 2.45, 3500]
VIS_band = [0.458, 0.639, 0.820, 3100]
IZJ_band = [0.811, 1.090, 1.369, 3355]
HK_band = [1.450, 1.950, 2.450, 3355]
# Test band with R=7000 resolution, but only 43 wavelengths
H_small_band = [1.620, 1.625, 1.630, 7000]
IZ_band = [0.830, 0.940, 1.050, 7000]
J_band = [1.046, 1.185, 1.324, 7000]
H_band = [1.435, 1.625, 1.815, 7000]
K_band = [1.951, 2.210, 2.469, 7000]
IZ_band = [0.830, 0.940, 1.050, 7104]
J_band = [1.046, 1.185, 1.324, 7104]
H_band = [1.435, 1.625, 1.815, 7104]
K_band = [1.951, 2.210, 2.469, 7104]
Z_high = [0.829, 0.866, 0.902, 17000]
#J_high=[1.190, 1.245, 1.300, 17000] # not actually present in harmoni
H_high = [1.541, 1.609, 1.676, 17000]
#K_high=[2.093, 2.190, 2.287, 17000] # old definition ; not correct anymore
K1_high = [2.024, 2.113, 2.202, 17000]
K2_high = [2.197, 2.294, 2.390, 17000]
Z_high = [0.828, 0.865, 0.902, 17385]
H_high = [1.538, 1.608, 1.678, 17385]
K1_high = [2.017, 2.109, 2.201, 17385]
K2_high = [2.199, 2.300, 2.400, 17385]
if BAND == 'TEST_H':
N_LD = 6
N_LD = 3
LBD_min = H_band[0]*1e-6
LBD_max = H_band[2]*1e-6
if APODIZER == 'SP_1':
......@@ -131,8 +135,8 @@ if BAND == 'TEST_H':
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_NoADC.fits')
FPM = 'FPM_H'
else:
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
#MASK_OFFSET = -7 # mas
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK_OFFSET = -7 #mas
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = 0 # mas
FPM = 'FPM_H'
......@@ -145,19 +149,19 @@ elif BAND == 'TEST_K':
MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_NoADC.fits')
FPM = 'FPM_K'
else:
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
#MASK_OFFSET = 0 # mas
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK_OFFSET = 0 # mas
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = 7 # mas
FPM = 'FPM_H'
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
else:
if ADC_flag == 0:
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_NoADC.fits')
FPM = 'FPM_K'
else:
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_ADC.fits')
MASK_OFFSET = 0 # mas
MASK_OFFSET = -2#0 # mas
FPM = 'FPM_K'
elif BAND == 'HK':
N_LD = round((HK_band[2]-HK_band[0])/(HK_band[1]/HK_band[3]))
......@@ -168,12 +172,12 @@ elif BAND == 'HK':
MASK = fits.getdata(COM_DIR + 'FPM_HK_SP1_NoADC.fits')
FPM = 'FPM_HK'
else:
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
#MASK_OFFSET = -22 # mas
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK_OFFSET = -22 # mas
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = -15 # mas
FPM = 'FPM_H'
#MASK = fits.getdata(COM_DIR + 'FPM_HK_SP1_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_HK_SP1_ADC.fits')
else:
if ADC_flag == 0:
MASK = fits.getdata(COM_DIR + 'FPM_HK_SP2_NoADC.fits')
......@@ -182,7 +186,7 @@ elif BAND == 'HK':
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_ADC.fits')
MASK_OFFSET = -30 # mas
FPM = 'FPM_K'
#MASK = fits.getdata(COM_DIR + 'FPM_HK_SP2_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_HK_SP2_ADC.fits')
elif BAND == 'H':
N_LD = round((H_band[2]-H_band[0])/(H_band[1]/H_band[3]))
LBD_min = H_band[0]*1e-6
......@@ -215,7 +219,7 @@ elif BAND == 'K':
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = 7 # mas
FPM = 'FPM_H'
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
else:
if ADC_flag == 0:
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_NoADC.fits')
......@@ -244,10 +248,10 @@ elif BAND == 'H_high':
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = 0 # mas
FPM = 'FPM_H'
#elif BAND == 'K_high':
# N_LD=round((K_high[2]-K_high[0])/(K_high[1]/K_high[3]))
# LBD_min = K_high[0]*1e-6
# LBD_max = K_high[2]*1e-6
#elif BAND == 'K_high':
# N_LD = round((K_high[2]-K_high[0])/(K_high[1]/K_high[3]))
# LBD_min = K_high[0]*1e-6
# LBD_max = K_high[2]*1e-6
elif BAND == 'K1_high':
N_LD = round((K1_high[2]-K1_high[0])/(K1_high[1]/K1_high[3]))
LBD_min = K1_high[0]*1e-6
......@@ -260,7 +264,7 @@ elif BAND == 'K1_high':
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = 7 # mas
FPM = 'FPM_H'
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
else:
if ADC_flag == 0:
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_NoADC.fits')
......@@ -281,7 +285,7 @@ elif BAND == 'K2_high':
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
MASK_OFFSET = 7 # mas
FPM = 'FPM_H'
#MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_K_SP1_ADC.fits')
else:
if ADC_flag == 0:
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_NoADC.fits')
......@@ -301,17 +305,18 @@ else:
FPM = 'FPM_HK'
else:
MASK = fits.getdata(COM_DIR + 'FPM_H_SP2_ADC.fits')
#MASK = fits.getdata(COM_DIR + 'FPM_HK_SP1_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_HK_SP1_ADC.fits')
MASK_OFFSET = -15 # mas
FPM = 'FPM_2'
FPM = 'FPM_H'
else:
if ADC_flag == 0:
MASK = fits.getdata(COM_DIR + 'FPM_HK_SP2_NoADC.fits')
FPM = 'FPM_HK'
else:
MASK = fits.getdata(COM_DIR + 'FPM_K_SP2_ADC.fits')
MASK_OFFSET = -30 # mas
FPM = 'FPM_K'
#MASK = fits.getdata(COM_DIR + 'FPM_HK_SP2_ADC.fits')
# MASK = fits.getdata(COM_DIR + 'FPM_HK_SP2_ADC.fits')
# Science wavelength vector
if N_LD == 1:
......@@ -351,7 +356,7 @@ Wind_Angle_vect = PARANG(DEC, HA_vect)
# ___ _ __ __| | ___ | |_ _ __ __ _ _ __ __ _ _ __ ___ ___| |_ ___ _ __ ___ ___| | ___ ___| |_ _ ___ _ __
# / _ \ '_ \ / _` | / _ \| _| | '_ \ / _` | '__/ _` | '_ ` _ \ / _ \ __/ _ \ '__| / __|/ _ \ |/ _ \/ __| __| |/ _ \| '_ \
# | __/ | | | (_| | | (_) | | | |_) | (_| | | | (_| | | | | | | __/ || __/ | \__ \ __/ | __/ (__| |_| | (_) | | | |
# \___|_| |_|\__, _| \___/|_| | .__/ \__, _|_| \__, _|_| |_| |_|\___|\__\___|_| |___/\___|_|\___|\___|\__|_|\___/|_| |_|
# \___|_| |_|\__,_| \___/|_| | .__/ \__,_|_| \__, _|_||_| |_|\___|\__\___|_| |___/\___|_|\___|\___|\__|_|\___/|_| |_|
# | |
# |_|
......@@ -388,14 +393,14 @@ else:
log.info('Rotation: NO')
if (miss_flag == 1):
log.info('Missing Segments: YES')
log.info('M1 Amplitude errors: YES')
else:
log.info('Missing Segments: NO')
log.info('M1 Amplitude errors: NO')
if (eeltphase_flag == 1):
log.info('EELT phase: YES')
log.info('M1 phase errors: YES')
else:
log.info('EELT phase: NO')
log.info('M1 phase errors: NO')
if (ADC_flag == 1):
log.info('Fixed ADC: YES')
......@@ -440,7 +445,7 @@ N_im = 215
FOV = N_im * MASperPIXEL
# Focal Plane Mask transmission & detector geometry
MASK = 1-((1-MASK)*(1-1e-4))
#MASK = 1-((1-MASK)*(1-1e-4)) #not necessary anymore (hardcoded in FPM)
x_mask, X_mask, Y_mask, R_mask, T_mask = VECT(len(MASK), FOV)
MASK[np.abs(Y_mask) > 610/2] = 0
......@@ -449,7 +454,7 @@ fits.writeto(path_directory + 'FOCAL_PLANE_MASK.fits', MASK)
start_dir = os.getcwd()
#os.chdir(path_directory)
Ideal_PSF = PSF(ft(SP, 1, 1132/1024, 1132/1024, MAS2LD(FOV, 38.542, 1650e-9), MAS2LD(FOV, 38.542, 1650e-9), 1, N_im, N_im))
fits.writeto(path_directory + '_Ideal_PSF.fits', Ideal_PSF, overwrite=True)
fits.writeto(path_directory + 'Ideal_PSF.fits', Ideal_PSF, overwrite=True)
#os.chdir(start_dir)
respix = 0.0376387
......@@ -467,12 +472,19 @@ M1pupil1132_1024 = fits.getdata(COM_DIR + 'PUPIL_1132_1024D38.542.fits')
PUP_NORM_INTENSITY = np.sum(M1pupil1132_1024**2*(1132/1024/1132)*(1132/1024/1132))
MISSSEG = fits.getdata(COM_DIR + 'MissingSegments_1132.fits')
MISSSEG = miss_flag*MISSSEG
if ELT_amplitude_errors == 'CONFIG_1A':
MISSSEG = fits.getdata(COM_DIR + 'ELT_1a_MS=7_RE=5.fits')
elif ELT_amplitude_errors == 'CONFIG_1B':
MISSSEG = fits.getdata(COM_DIR + 'ELT_1b_MS=7_RE=5.fits')
elif ELT_amplitude_errors == 'CONFIG_2A':
MISSSEG = fits.getdata(COM_DIR + 'ELT_2a_MS=7_RE=5.fits')
elif ELT_amplitude_errors == 'CONFIG_2B':
MISSSEG = fits.getdata(COM_DIR + 'ELT_2b_MS=7_RE=5.fits')
MISSSEG = np.sqrt(MISSSEG)
ORIGINAL_PUPIL = M1pupil1132_1024
M1pupil1132_1024 = M1pupil1132_1024*(1-MISSSEG)
M1pupil1132_1024 = M1pupil1132_1024*MISSSEG
P_M4 = EELTNLS(1024, 100, 100, 110) ### EELTNLS not written yet!!! ###
P_M4 = np.pad(P_M4, [54, 54], 'constant', constant_values=(0, 0))
......@@ -591,9 +603,10 @@ df = np.abs(f1D[1]-f1D[0])*fudge_df
# ____) |_| |_| | | | |__| | |____ / ____ \| | _| |_| |\ | |__| | | |____ / . \| | | |__| |____) | |__| | | \ \| |____ ____) |
# |_____/|_____|_| |_|\____/|______/_/ \_\_| |_____|_| \_|\_____| |______/_/ \_\_| \____/|_____/ \____/|_| \_\______|_____/
#
SR = np.zeros((len(HA_vect), N_LD))
SHIFT_PSF = np.zeros((len(HA_vect), N_LD))
SHIFT_MASK = np.zeros((len(HA_vect), N_LD))
SHIFT_PSF = np.zeros((len(HA_vect), N_LD))
log.info('Computing the different exposures...')
for i in range(len(HA_vect)):
......@@ -627,7 +640,7 @@ for i in range(len(HA_vect)):
#PUPILLE_0 = minterp2d(x, x, np.transpose(P_M4), x, x+pix_shift_0)
EELT_phase_0 = shift(1.0*EELT_phase, pix_shift_diff_0, output=None, order=1, mode='constant', cval=0.0, prefilter=True)
MISSSEG_0 = shift(1.0*MISSSEG, pix_shift_diff_0, output=None, order=1, mode='constant', cval=0.0, prefilter=True)
#MISSSEG_0 = shift(1.0*MISSSEG, pix_shift_diff_0, output=None, order=1, mode='constant', cval=0.0, prefilter=True)
PUPILLE_0 = shift(1.0*np.transpose(P_M4), pix_shift_diff_0, output=None, order=1, mode='constant', cval=0.0, prefilter=True)
log.info('Computing the wavefront correction by M4...')
......@@ -667,7 +680,7 @@ for i in range(len(HA_vect)):
WF_CP_0 = np.squeeze(WF_CP_0)
WF_NCPA_0 = np.squeeze(WF_NCPA_0)
WF_0=(WF_CP_0-WF_corr_0+EELT_phase_0+WF_NCPA_0)
WF_0 = (WF_CP_0-WF_corr_0+EELT_phase_0+WF_NCPA_0)
DSP_V, DSP_I = DSP(WF_0, BigD/D, np.transpose(ORIGINAL_PUPIL), 0, 1000)
log.info('HA={0}: Aberration level (0-1000 lambda/D) at {1} nm: {2} nm'.format(HA_0, lambda_vect[k]*1e9, 1e9*DSP_V))
......@@ -680,16 +693,18 @@ for i in range(len(HA_vect)):
OWA = MAS2LD(FOV, 38.542, lambda_vect[k])/2
if ADC_flag == 1:
#alpha_disp_0 = MAS2LD(1000*DISPER_ADC(1.45, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0), z_min, z_max), 38.542, lambda_vect[k])-MAS2LD(1000*DISPER_ADC(1.45, lambda_vect[-1]*1e6, 90-ELEVATION(DEC, HA_0), z_min, z_max), 38.542, lambda_vect[k])
alpha_disp_0 = MAS2LD(1000*DISPER_ADC(lambda_vect[0]*1e6, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0), z_min, z_max), 38.542, lambda_vect[k])
#alpha_disp_0 = MAS2LD(1000*DISPER_ADC(1.45,lambda_vect[k]*1e6,90-ELEVATION(DEC,HA_0),z_min,z_max),38.542,lambda_vect[k])-MAS2LD(1000*DISPER_ADC(1.45,lambda_vect[-1]*1e6,90-ELEVATION(DEC,HA_0),z_min,z_max),38.542,lambda_vect[k])
alpha_disp_0 = MAS2LD(1000*DISPER_ADC(lambda_vect[0]*1e6, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0), z_min, z_max),
38.542, lambda_vect[k])
else:
#alpha_disp_0 = MAS2LD(1000*DISPER(1.45, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0)), 38.542, lambda_vect[k])-MAS2LD(1000*DISPER(1.45, lambda_vect[-1]*1e6, 90-ELEVATION(DEC, HA_0)), 38.542, lambda_vect[k])
alpha_disp_0 = MAS2LD(1000*DISPER(lambda_vect[0]*1e6, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0)), 38.542, lambda_vect[k])
#alpha_disp_0 = MAS2LD(1000*DISPER(1.45,lambda_vect[k]*1e6,90-ELEVATION(DEC,HA_0)),38.542,lambda_vect[k])-MAS2LD(1000*DISPER(1.45,lambda_vect[-1]*1e6,90-ELEVATION(DEC,HA_0)),38.542,lambda_vect[k])
alpha_disp_0 = MAS2LD(1000*DISPER(lambda_vect[0]*1e6, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0)),
38.542, lambda_vect[k])
#log.info('Differential dispersion angle with 2.45um: {0}'.format(alpha_disp_0))
x, X, Y, R, T = VECT(len(SP), 1132/1024)
E_0 = ft(np.transpose(SP)*(1-MISSSEG)*np.exp(2*1j*pi*WF_0/lambda_vect[k])*np.exp(-2*1j*pi*alpha_disp_0*Y), 1, BigD/D, BigD/D, 2*OWA, 2*OWA, 1, N_im, N_im)
E_0 = ft(np.transpose(SP)*MISSSEG*np.exp(2*1j*pi*WF_0/lambda_vect[k])*np.exp(-2*1j*pi*alpha_disp_0*Y), 1, BigD/D, BigD/D, 2*OWA, 2*OWA, 1, N_im, N_im)
#Commented to save time ; halo only
I_0 = np.abs(E_0)**2
......@@ -716,7 +731,7 @@ for i in range(len(HA_vect)):
t_iter = 0
t_left = (N_LD*len(HA_vect)-(i*N_LD + k))*t_iter
I_s_0 = np.abs(ft(np.transpose(SP)*(1-MISSSEG)*np.exp(2*1j*pi*WF_0/lambda_vect[k])*np.exp(2*1j*pi*alpha_disp_0*Y), 1, BigD/D, BigD/D, 2*OWA, 2*OWA, 1, len(dsp), len(dsp)))**2
I_s_0 = np.abs(ft(np.transpose(SP)*MISSSEG*np.exp(2*1j*pi*WF_0/lambda_vect[k])*np.exp(2*1j*pi*alpha_disp_0*Y), 1, BigD/D, BigD/D, 2*OWA, 2*OWA, 1, len(dsp), len(dsp)))**2
FTO_tel_0 = ft(I_s_0, 1, 2*OWA, 2*OWA, DiamFTO, DiamFTO, 1, len(dsp), len(dsp))
I_s_post_0 = np.abs(ft(FTO_tel_0*FTO_atm, 1, DiamFTO, DiamFTO, 2*OWA, 2*OWA, 1, N_im, N_im))
......@@ -751,8 +766,8 @@ for i in range(len(HA_vect)):
# alpha_shift = -sum(I1D*V1D)
# shift_value[k] = alpha_shift/(x_mask[1]-x_mask[0])
I_temp[k, :, :] = I_s_post_0
I_temp_nomask[k, :, :] = I_s_post_0
I_temp[k] = I_s_post_0
I_temp_nomask[k] = I_s_post_0
# if exhaustive_writing_flag==1:
# fits.writeto(path_directory + 'PSF_HALO_OFF_Nexp{0}_Nlbd{1}.fits'.format(i, k), I_0)
......@@ -785,8 +800,9 @@ for i in range(len(HA_vect)):
#print('FPM offset: {:f}'.format(shift_pix_FPM))
#MASK_temp = MASK
MASK_temp = shift(MASK, [-shift_pix_FPM, 0], output=None, order=1, mode='constant', cval=0.0, prefilter=True)
for k in range(N_LD):
MASK_temp = shift(MASK, [-shift_pix_FPM, 0], output=None, order=1, mode='constant', cval=0.0, prefilter=True)
for k in range(N_LD):
if ADC_flag == 1:
shift_value = 1000*DISPER_ADC(lambda_vect[0]*1e6, lambda_vect[k]*1e6, 90-ELEVATION(DEC, HA_0), z_min, z_max)
shift_value /= MASperPIXEL
......@@ -795,9 +811,10 @@ for i in range(len(HA_vect)):
shift_value /= MASperPIXEL
#print(shift_value*MASperPIXEL)
SHIFT_PSF[i, k] = shift_value
SHIFT_MASK[i, k] = -shift_pix_FPM
SHIFT_PSF[i, k] = shift_value
I_temp[k] = I_temp[k, :, :]*np.flipud(MASK_temp)
I_temp[k] = shift(I_temp[k, :, :], [shift_value, 0], output=None, order=1, mode='constant', cval=0.0, prefilter=True)
......@@ -813,7 +830,7 @@ for i in range(len(HA_vect)):
fits.setval(image_filename, 'APODIZER', value=APODIZER)
fits.setval(image_filename, 'FPM', value=FPM)
image_filename_nomask = path_directory + 'PSF_HALO_ON_notmasked_notcentered_Nexp{0:04d}.fits'.format(i)
image_filename_nomask = path_directory + 'PSF_HALO_ON_notmasked_centered_Nexp{0:04d}.fits'.format(i)
fits.writeto(image_filename_nomask, I_temp_nomask)
fits.setval(image_filename_nomask, 'ORIGIN', value='ESO-ARMAZONES')
fits.setval(image_filename_nomask, 'TELESCOP', value='ESO-ELT')
......@@ -828,9 +845,12 @@ for i in range(len(HA_vect)):
shift_filename = path_directory + 'SHIFT_PSF.fits'
fits.writeto(shift_filename, SHIFT_PSF)
shift_filename = path_directory + 'SHIFT_PSF.fits'
fits.writeto(shift_filename, SHIFT_PSF)
shift_filename = path_directory + 'SHIFT_MASK.fits'
fits.writeto(shift_filename, SHIFT_MASK)
SR_filename = path_directory + 'SR.fits'
fits.writeto(SR_filename, SR)
......
......@@ -716,6 +716,8 @@ def AZAV_STAT(I,OWA,PhotAp,fraction):
def MAKE_ELT(WORKPATH,N,D,n_miss,ref_err):
#Problem of coherence between ESO pupil and this one
#D = D *1.021
C = fits.getdata(WORKPATH + 'Coord_ELT.fits')
#
N=N+N%2
......@@ -748,7 +750,7 @@ def MAKE_ELT(WORKPATH,N,D,n_miss,ref_err):
hexa = referr * hexa
#
return (hexa,color,MS)
return (hexa,color,MS,referr)
def EELTNLS(N,a1,a2,a3):
D=1
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment