Submit a Story  :  IRAF Links  :  Past Polls  :  Calendar  :  Advanced Search  
     iraf.net
FAQ
 Forum FAQForum FAQ   Forum SearchForum Search   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Gmos reduction

 
Post new topic   Reply to topic    iraf.net Forum Index -> Applications
View previous topic :: View next topic  
Author Message
donzelli
Active IRAF User


Joined: 14 Apr 2010
Posts: 58
Location: IATE - Observatorio Astronomico Cordoba - Argentina

PostPosted: Fri Jul 29, 2011 12:08 pm    Post subject: Gmos reduction Reply with quote

Hi,
I reduced gmos (mos mode) data following the example included in the Gemini package and I have some questions about the results I get.
After gsextract one could expect to get 1-d spectra in the resulting image.
In other words, if you do imhead image.fits[SCI,1] you would expect to get something like:
image.fits[SCI,1][3108,1][real]
that is a 1-d spectrum for each science object.

However, I get:
image.fits[SCI,2][3108,1,3][real]: 1032
which means 3 1-d spectra!

Moreover, if I splot image.fits[SCI,1], the routine asks the image band to plot,
and I see different scales (on Y) depending the band I choose.

Can anybody tell me what are these 3 spectra?
thanks
charly
Back to top
View user's profile Send private message Send e-mail Visit poster's website
emma
Active IRAF User


Joined: 23 Jan 2006
Posts: 98
Location: Chile

PostPosted: Wed Aug 03, 2011 7:44 pm    Post subject: Reply with quote

Hello Charly,

The output from gsextract usually contains a one dimensional spectrum for each slit provided to the task:

Code:

cl> imhead image.fits[SCI,1]
image.fits[SCI,1][3108][real]


Just in case you were unaware, the fxheader task in the fitsutil package is useful for looking at MEF files:

Code:

cl> fxhead image.fits
EXT#  EXTTYPE             EXTNAME       EXTVE DIMENS     BITPI INH OBJECT       
0     image.fits                                         16        OBJECT     
1      BINTABLE           MDF           1     64x3       8                     
2      IMAGE              SCI           1     3108       -32   F   OBJECT     


Can you provide the parameters that you used when running gsextract and also provide an fxhead of the input image to gsextract, please?

Many thanks,

Emma Smile
Back to top
View user's profile Send private message
donzelli
Active IRAF User


Joined: 14 Apr 2010
Posts: 58
Location: IATE - Observatorio Astronomico Cordoba - Argentina

PostPosted: Thu Aug 04, 2011 1:32 pm    Post subject: Reply with quote

Hi Emma,

thanks for your answer once again.

Please see below parameters used for gsextract and the result of fxhead
for one of the gsextracted images.
Let me know if you need any other information.

regards
charly

inimages = "stgsS0069.fits" Input images
(outimages = " ") Output images
(outprefix = "e") Output prefix
(refimages = "") Reference images for tracing apertures
(apwidth = 2.) Extraction aperture in arcsec (diameter)
(fl_inter = yes) Run interactively?
(find = yes) Define apertures automatically?
(recenter = yes) Recenter apertures?
(trace = yes) Trace apertures?
(tfunction = "chebyshev") Trace fitting function
(torder = 3) Trace fitting function order
(tnsum = 20) Number of dispersion lines to sum for trace
(tstep = 20) Tracing step
(weights = "variance") Extraction weights (none|variance)\n
(clean = yes) Detect and replace bad pixels?
(lsigma = 3.) Lower rejection threshold for cleaning
(usigma = 3.) Upper rejection threshold for cleaning\n
(background = "none") Background subtraction method
(bfunction = "chebyshev") Background function
(border = 1) Order of background fit
(long_bsample = "-200:-100, 100:200") LONGSLIT: backgr sample regions, WRT aperture
(mos_bsample = 0.5) MOS: fraction of slit length to use (bkg+obj)
(bnaverage = -10) Number of samples to average over
(bniterate = 2) Number of rejection iterations
(blow_reject = 2.5) Background lower rejection sigma
(bhigh_reject = 2.5) Background upper rejection sigma
(bgrow = 0.) Background rejection growing radius (pix)\n
(fl_vardq = no) Propagate VAR/DQ planes? (if yes, must use variance weighting)
(sci_ext = "SCI") Name of science extension
(var_ext = "VAR") Name of variance extension
(dq_ext = "DQ") Name of data quality extension
(key_ron = "RDNOISE") Keyword for readout noise in e-
(key_gain = "GAIN") Keyword for gain in electrons/ADU
(ron = 3.5) Default readout noise rms in electrons
(gain = 2.2) Default gain in e-/ADU
(logfile = "") Logfile
(verbose = yes) Verbose?
(status = 0) Exit status (0=good)
(scanfile = "") Internal use
(mode = "ql")


fxhead estgsS0063.fits
EXT# EXTTYPE EXTNAME EXTVE DIMENS BITPI INH OBJECT

0 estgsS0063.fits 16 BH 176
1 BINTABLE MDF 1 126x44 8
2 IMAGE SCI 1 3108x1x3 -32 F 1031
3 IMAGE SCI 2 3108x1x3 -32 F 1032
4 IMAGE SCI 3 3108x1x3 -32 F 1015
5 IMAGE SCI 4 3108x1x3 -32 F 1030
6 IMAGE SCI 5 3108x1x3 -32 F 612
7 IMAGE SCI 6 3108x1x3 -32 F 3911
8 IMAGE SCI 7 3019x1x3 -32 F 1018
9 IMAGE SCI 8 3108x1x3 -32 F 567
10 IMAGE SCI 9 3108x1x3 -32 F 1026
11 IMAGE SCI 10 3108x1x3 -32 F 467
12 IMAGE SCI 11 3108x1x3 -32 F 561
13 IMAGE SCI 12 3108x1x3 -32 F 1001
14 IMAGE SCI 13 3108x1x3 -32 F 458
15 IMAGE SCI 14 3108x1x3 -32 F 557
16 IMAGE SCI 15 3108x1x3 -32 F 378
17 IMAGE SCI 16 3108x1x3 -32 F 4157
18 IMAGE SCI 17 3108x1x3 -32 F 3103
19 IMAGE SCI 18 3108x1x3 -32 F 980
20 IMAGE SCI 19 3108x1x3 -32 F 384
21 IMAGE SCI 20 3108x1x3 -32 F 489
22 IMAGE SCI 21 3108x1x3 -32 F 10
23 IMAGE SCI 22 3108x1x3 -32 F 141
24 IMAGE SCI 23 3108x1x3 -32 F 2526
25 IMAGE SCI 24 2906x1x3 -32 F 1023
26 IMAGE SCI 25 3108x1x3 -32 F 421
27 IMAGE SCI 26 3108x1x3 -32 F 1011
28 IMAGE SCI 27 3108x1x3 -32 F 407
29 IMAGE SCI 28 3108x1x3 -32 F 1024
30 IMAGE SCI 29 3108x1x3 -32 F 562
31 IMAGE SCI 30 3108x1x3 -32 F 278
32 IMAGE SCI 31 3108x1x3 -32 F 350
33 IMAGE SCI 32 3108x1x3 -32 F 551
34 IMAGE SCI 33 3108x1x3 -32 F 129
35 IMAGE SCI 34 3108x1x3 -32 F 1207
36 IMAGE SCI 35 3108x1x3 -32 F 181
37 IMAGE SCI 36 2954x1x3 -32 F 100
38 IMAGE SCI 37 3108x1x3 -32 F 252
39 IMAGE SCI 38 3108x1x3 -32 F 130
40 IMAGE SCI 39 3108x1x3 -32 F 1365
41 IMAGE SCI 40 3108x1x3 -32 F 185
42 IMAGE SCI 41 2988x1x3 -32 F 128
Back to top
View user's profile Send private message Send e-mail Visit poster's website
emma
Active IRAF User


Joined: 23 Jan 2006
Posts: 98
Location: Chile

PostPosted: Thu Aug 04, 2011 5:36 pm    Post subject: Reply with quote

Can you also provide an fxhead of the input image to gsextract, please? (i.e., stgsS0069.fits).

Many thanks,

Emma Smile
Back to top
View user's profile Send private message
donzelli
Active IRAF User


Joined: 14 Apr 2010
Posts: 58
Location: IATE - Observatorio Astronomico Cordoba - Argentina

PostPosted: Thu Aug 04, 2011 7:28 pm    Post subject: Reply with quote

Hi Emma,

here it is.

regards
charly


gmos> fxhead stgsS0063.fits
EXT# EXTTYPE EXTNAME EXTVE DIMENS BITPI INH OBJECT

0 stgsS0063.fits 16 BH 176
1 BINTABLE MDF 1 126x44 8
2 IMAGE SCI 1 3108x29 -32 F 1031
3 IMAGE SCI 2 3108x29 -32 F 1032
4 IMAGE SCI 3 3108x28 -32 F 1015
5 IMAGE SCI 4 3108x26 -32 F 1030
6 IMAGE SCI 5 3108x29 -32 F 612
7 IMAGE SCI 6 3108x27 -32 F 3911
8 IMAGE SCI 7 3019x28 -32 F 1018
9 IMAGE SCI 8 3108x28 -32 F 567
10 IMAGE SCI 9 3108x28 -32 F 1026
11 IMAGE SCI 10 3108x28 -32 F 467
12 IMAGE SCI 11 3108x28 -32 F 561
13 IMAGE SCI 12 3108x29 -32 F 1001
14 IMAGE SCI 13 3108x28 -32 F 458
15 IMAGE SCI 14 3108x29 -32 F 557
16 IMAGE SCI 15 3108x28 -32 F 378
17 IMAGE SCI 16 3108x28 -32 F 4157
18 IMAGE SCI 17 3108x28 -32 F 3103
19 IMAGE SCI 18 3108x28 -32 F 980
20 IMAGE SCI 19 3108x28 -32 F 384
21 IMAGE SCI 20 3108x28 -32 F 489
22 IMAGE SCI 21 3108x28 -32 F 10
23 IMAGE SCI 22 3108x28 -32 F 141
24 IMAGE SCI 23 3108x26 -32 F 2526
25 IMAGE SCI 24 2906x28 -32 F 1023
26 IMAGE SCI 25 3108x28 -32 F 421
27 IMAGE SCI 26 3108x28 -32 F 1011
28 IMAGE SCI 27 3108x28 -32 F 407
29 IMAGE SCI 28 3108x28 -32 F 1024
30 IMAGE SCI 29 3108x28 -32 F 562
31 IMAGE SCI 30 3108x28 -32 F 278
32 IMAGE SCI 31 3108x29 -32 F 350
33 IMAGE SCI 32 3108x28 -32 F 551
34 IMAGE SCI 33 3108x28 -32 F 129
35 IMAGE SCI 34 3108x28 -32 F 1207
36 IMAGE SCI 35 3108x28 -32 F 181
37 IMAGE SCI 36 2954x29 -32 F 100
38 IMAGE SCI 37 3108x29 -32 F 252
39 IMAGE SCI 38 3108x28 -32 F 130
40 IMAGE SCI 39 3108x28 -32 F 1365
41 IMAGE SCI 40 3108x28 -32 F 185
42 IMAGE SCI 41 2988x29 -32 F 128
Back to top
View user's profile Send private message Send e-mail Visit poster's website
emma
Active IRAF User


Joined: 23 Jan 2006
Posts: 98
Location: Chile

PostPosted: Fri Aug 05, 2011 10:57 pm    Post subject: Reply with quote

Hi Charly,

Thank you for the information. The extra planes are actually created by apall because you set the "weights" parameter to "variance". If you look in the header of the science extensions you should see some keywords like:

Code:
cl> imhead input.fits[SCI,1] l+
...
BANDID1 = 'spectrum - background none, weights variance, clean yes'
BANDID2 = 'raw - background none, weights none, clean no'
BANDID3 = 'sigma - background none, weights variance, clean yes'
...


These keywords tell you what each plane in each science extension means. So, the first plane in the first science extension [SCI,1] (i.e., 3108x1x1) contains your extracted spectrum that has been cleaned and weighted by the variance. The second plane in the first science extension (i.e., 3108x1x2) contains the raw extracted spectrum that hasn't been cleaned or weighted by the variance. The third plane in the first science extension (i.e., 3108x1x3) contains the sigma. You can view each of these spectra by using:

Code:
cl> splot input.fits[SCI,1][*,*,1]
cl> splot input.fits[SCI,1][*,*,2]
cl> splot input.fits[SCI,1][*,*,3]


You can read more about apall and weighted extractions by looking at the following help files:

Code:
cl> help apall
cl> help apsum
cl> help apvariance


If you decide that you don't want to do a weighted extraction, you will need to set the "weights" parameter to "none" and the "clean" parameter to "no" (since if the "clean" parameter is set to "yes", the "weights" parameter is set to "variance" automatically). If you do this, your output will contain a one dimensional spectrum for each slit provided to the task as expected.

I hope that helps. Please let me know if you have any more questions.

Many thanks,

Emma Smile
Back to top
View user's profile Send private message
donzelli
Active IRAF User


Joined: 14 Apr 2010
Posts: 58
Location: IATE - Observatorio Astronomico Cordoba - Argentina

PostPosted: Tue Aug 09, 2011 11:39 am    Post subject: Reply with quote

Emma,

thank you very much.
regards,
charly
Back to top
View user's profile Send private message Send e-mail Visit poster's website
emma
Active IRAF User


Joined: 23 Jan 2006
Posts: 98
Location: Chile

PostPosted: Tue Aug 09, 2011 4:39 pm    Post subject: Reply with quote

No problem Smile
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    iraf.net Forum Index -> Applications All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2009 phpBB Group
 Copyright © 2005-2011 iraf.net
 All trademarks and copyrights on this page are owned by their respective owners.
Powered By Geeklog 
Created this page in 0.13 seconds