我想用aplpy绘制一个拟合文件,但是我收到以下错误:
INFO: The WCS transformation has more axes (3) than the image it is associated with (2) [astropy.wcs.wcs]
ERROR: IndexError: list index out of range [aplpy.wcs_util]
如果我删除标题关键字CTYPE3,CD3_3,WAT3_001,那么我就不会再得到错误了,但是当绘制拟合文件时,我看到WCS转换没有正确完成RA和DEC坐标全部在这个地方。
这是标题:
HCG89_halpha_plot.fits[2929,2881][real]: HCG89-SII
No bad pixels, min=0., max=0. (old)
Line storage mode, physdim [2929,2881], length of user area 5144 s.u.
Created Tue 15:40:54 28-Jan-2014, Last modified Thu 22:20:03 30-Jan-2014
Pixel file "HCG89_halpha_plot.fits" [ok]
ORIGIN = 'NOAO-IRAF FITS Image Kernel July 2003' / FITS file originator
IRAF-TLM= '2014-01-30T19:20:03' / Time of last modification
OBJECT = 'HCG89-SII' / Name of the object observed
DATE-OBS= '2013-10-11T00:14:11.700' / Date of observation
DATE = '2014-01-28T12:40:54' / Date Format is YYYY-MM-DD
TIME = '00:14:11.07 to 00:19:11.40' / ~ Start & Stop of Exposure
N_PARAM = 80 / Number of Parameters
TELESCOP= 'SOAR 4.1m'
INSTRUME= 'Goodman Spectrograph'
NOTES = ' '
RA = '21:20:09.042' / right ascension [hh:mm:ss.sss]
DEC = '-3:55:23.160' / declination [dd:mm:ss.sss]
AIRMASS = 1.13 / airmass at approx. start of exposure
UT = '00:14:10.9' / time at approx. start of exposure [UTC]
FOCUS = -1021.0 / SOAR telescope focus
MOUNT_AZ= 17.1482 / SOAR mount azimuth
MOUNT_EL= 62.2622 / SOAR mount elevation
ROTATOR = 228.003 / Nasymth cage rotator angle [deg]
POSANGLE= 360.0 / position angle [deg. E of N]
SEEING = -1.0 / DIMM seeing [arcsec]
LST = '20:50:17.4' / Local Sidereal Time [hh:mm:ss.sss]
OBSRA = '21:20:09.946' / target right ascension [hh:mm:ss.sss]
OBSDEC = '-3:55:32.480' / target declination [hh:mm:ss.sss]
CAM_ANG = 0.014461 / camera angle [deg]
GRT_ANG = 0.661 / grating angle [deg]
CAM_TARG= 0.0 / camera target [deg]
GRT_TARG= 0.661 / grating target [deg]
CAM_FOC = 660 / camera focus
COLL_FOC= 1002 / collimator focus
FILTER = 'SII ' / primary filter wheel
FILTER2 = '<NO FILTER>' / secondary filter wheel
GRATING = '<NO GRATING>' / VPH grating [1/mm]
SLIT = '<NO MASK>' / slit [arcsec]
COL_TEMP= 10.421875 / coll ext temp (deg C)
CAM_TEMP= 14.234375 / cam ext temp (deg C)
EXPTIME = 300.0 / integration time
RDNOISE = 4.74 / CCD readnoise [e-]
GAIN = 1.4 / CCD gain [e-/ADU]
OBSTYPE = 'OBJECT ' / observation type
OBSERVER= ' '
PROPOSAL= ' '
EQUINOX = 2000.0 / equinox of coordinates
CRPIX1 = 1477.39599990845 / Reference pixel on axis 1
CRPIX2 = 1488.23082170899 / Reference pixel on axis 2
CRVAL1 = 320.041401353 / Value at ref. pixel on axis 1
CRVAL2 = -3.91652009277 / Value at ref. pixel on axis 2
CTYPE1 = 'RA---TAN' / Type of co-ordinate on axis 1
CTYPE2 = 'DEC--TAN' / Type of co-ordinate on axis 2
PC1_1 = 0.999884048946387 / Transformation matrix element
PC1_2 = 0.0152278909432213 / Transformation matrix element
PC2_1 = -0.0140395410920601 / Transformation matrix element
PC2_2 = 1.0 / Transformation matrix element
MJD-OBS = 56576.0098576389 / Modified Julian Date of observation
RADESYS = 'FK5 ' / Reference frame for RA/DEC values
DISPAXIS= 1
DETSIZE = '[1:4096,1:4096]'
TRIMSEC = '[1:3096,1:3096]'
CCDSIZE = '[1:4096,1:4096]'
CCDSUM = '1 1 '
OPENTIME= '00:14:11.611' / GPS-Synched Time for Shutter Open (UT)
INSTRUME= 'Goodman Spectrograph'
COMMENT Triggered Acquisition, Exp Time= 05:00
WCSDIM = 3
LTM1_1 = 1.0
LTM2_2 = 1.0
LTM3_3 = 1.0
WAXMAP01= '1 0 2 0 0 0 '
WAT0_001= 'system=physical'
WAT1_001= 'wtype=linear axtype=ra'
WAT2_001= 'wtype=linear axtype=dec'
WAT3_001= 'wtype=linear'
LTV1 = -159.604000091553
LTV2 = -134.766998291016
IMCMB001= '0073.HCG89-SII_scaled.fits'
IMCMB002= '0074.HCG89-SII_scaled.fits'
IMCMB003= '0079.HCG89-SII_scaled.fits'
IMCMB004= '0080.HCG89-SII_scaled.fits'
IMCMB005= '0083.HCG89-SII_scaled.fits'
IMCMB006= '0084.HCG89-SII_scaled.fits'
NCOMBINE= 6
CTYPE3 = 'LINEAR '
CD1_1 = 4.03250815042544E-5
CD2_2 = 4.04084336509694E-5
CD3_3 = 1.
答案 0 :(得分:0)
我不确定,因为我无法访问您的图片,但您有多扩展FITS文件吗?如果你这样做,你可能会遇到同样的错误(Find physical coordinates of a pixel in a fits file with python)。
检查以确保使用连接到科学数据的HDU和标题。