Remove astropy warning, catch and fix overflow and division error

This commit is contained in:
Thibault Barnouin
2022-02-07 17:50:18 +01:00
parent c0d7ba2f97
commit 4b26d2c320
11 changed files with 51 additions and 29 deletions

View File

@@ -39,7 +39,7 @@ def get_obs_data(infiles, data_folder="", compute_flux=False):
with fits.open(data_folder+infiles[i]) as f:
headers.append(f[0].header)
data_array.append(f[0].data)
data_array = np.array(data_array)
data_array = np.array(data_array,dtype=np.double)
# Prevent negative count value in imported data
for i in range(len(data_array)):