Commit 14b29027 authored by EPINAT Benoit's avatar EPINAT Benoit
Browse files

Merge branch 'master' of https://gitlab.lam.fr/bepinat/CAMEL

parents eb0e5af9 8514ef5d
......@@ -1258,6 +1258,19 @@ def buildmaps(conf, cube, hdr, var=None, plot=False, debug=False, free_ratio=Fal
del hdr['CD1_3']
if 'CDELT3' in hdr.keys():
del hdr['CDELT3']
# Added by Wilfried to deal with MXDF cubes
if 'WCSAXES' in hdr:
# If exactly 3 (cube), we change it to 2 (image)
if hdr['WCSAXES'] == 3:
hdr['WCSAXES'] = 2
# If < 2 or > 3 then that's weird and we print a warning and we put 2 instead in the images
elif hdr['WCSAXES'] < 2 or hdr['WCSAXES'] > 3:
print('WCSAXES keyword in init cu1be is %d but should be 3. Putting 2 in the images instead.' %hdr['WCSAXES'])
hdr['WCSAXES'] = 2
suff = ''
if conf['COMMW']:
......
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