I'm having trouble getting a script to specify the fits extension for apall within a huge ECHELLE reduction package. Below is the error I keep getting.
***************************************************************
Resampling the spectrum by a factor of 4 in the y direction...
DQTaue.0128.fits
Magnify image DQTaue.0128.fits to image DQTaue.0128.fits.
Interpolation is spline3.
Boundary extension is nearest.
Output coordinates in terms of input coordinates:
x1 = 1., x2 = 2048., dx = 1.
y1 = 1., y2 = 2048., dy = 0.25
Removing scattered inter-order light from the spectrum...
Extracting the spectrum to one dimension...
QTaue.0128.fits[0]:
Warning: FXF: must specify which FITS extension (DQTaue.0128)
Resampling the spectrum by a factor of 4 in the y direction...
**************************************************************
Below is the portion of the script that is calling that apall that seems to not be able to find the extension. Note that I have added the line
s1=s1//"[0]" to try to specify the extension. While that definitely adds the [0] to the .fits file from the output included above, it still doesn't seem to solve my problem. I'm at a loss as to how to proceed. Everything else in the procedure seems to working just fine.
Thanks,
Jeff
*************************************************************
PHP Formatted Code
list = "all.list"
while (fscan
(list,s1
) !=EOF
) {
print "Resampling the spectrum by a factor of 4 in the y direction..."
magnify
(input
=s1
,output
=s1
,xmag
=1.,ymag
=4.,x1
=INDEF
,x2
=INDEF
,dx
=INDEF
,y1
=INDEF
,y2
=INDEF
,dy
=INDEF
,interpolatio
="spline3",boundary
="nearest",constant=0.,fluxconserve
=yes
,logfile
="STDOUT",mode
="ql")
print "Removing scattered inter-order light from the spectrum..."
s2
="noscat"//s1
imcopy
(input
=s1
,output
=s2
,verbose
=no
,mode
="ql")
#imdelete(images=s1,verify=no,default_acti=yes,mode="ql")
apscatter input
=(s2
) output
=(s1
) apertures
="" scatter
="" references
=magnified_flat interactive
=no find
=no recent
=yes resize
=yes edit
=no trace
=no fittrace
=no subtract
=yes smooth
=yes fitscatter
=yes fitsmooth
=yes line
=INDEF nsum
=-10
imdelete
(images
=s2
,verify
=no
,default_acti
=yes
,mode
="ql")
s1
=s1
//"[0]"
print "Extracting the spectrum to one dimension..."
print (":"//s1//":")
apall input
=(s1
) nfind
=1 output
="" apertures
="" format
="echelle" references
=magnified_flat profiles
="" interac
=no find
=no recenter
=yes resize
=yes edit
=no trace
=no fittrace
=no
extract=yes extras
=no review
=yes line
=INDEF nsum
=10 lower
=-2. upper
=2. apidtable
="" b_funct
="chebyshev" b_order
=1 b_sample
="-6:-3,3:6" b_naverage
=1 b_niterate
=0 b_low_reject
=3. b_high_rejec
=3. b_grow
=0. width
=12 radius
=16 threshold
=0. minsep
=5. maxsep
=1000. order
="increasing" aprecenter
="" npeaks
=INDEF shift
=no llimit
=INDEF ulimit
=INDEF ylevel
=0.05 peak
=yes bkg
=yes r_grow
=0. avglimits
=no t_nsum
=10 t_step
=10 t_nlost
=3 t_function
="legendre" t_order
=5 t_sample
="200:1850,*" t_naverage
=3 t_niterate
=3 t_low_reject
=3. t_high_reject
=3. t_grow
=0. background
="none" skybox
=1 weights
="none" pfit
="fit1d" clean
=no saturation
=INDEF readnoise
="0." gain
="1." lsigma
=4. usigma
=4. nsubaps
=1 mode
="ql"
}
***************************************************************************************