Aperture photometry using APT

From CoolWiki
Jump to navigationJump to search

Downloading, Installing, and Starting the Software

APT = Aperture Photometry Tool. Russ Laher wrote it, and it can be downloaded here. Follow the directions there to install it. You may be interested in the Unix cheatsheet. If you're using windows, see the windows hints, tips, and tricks page. (run apt java -mx512M APT)

For a comprehensive introduction to APT, please see this page. The stuff that is here on the wiki is more skeletal, and is meant to be a quick overview with a focus on what you need as a NITARP user of APT. As of May 2010, two papers on APT have been submitted to PASP: http://spider.ipac.caltech.edu/staff/laher/apt/paper1.pdf (overview of APT) and http://spider.ipac.caltech.edu/staff/laher/apt/paper2.pdf (validation using ground-based data). You may be interested in these more detailed discussions.

Loading an image

Click on "choose FITS image" and load an image. It will come up with a default stretch. You can use the buttons and fill-in boxes to change the stretch (limits and scale) if desired. You can obtain a histogram of the values in the image by clicking on the "image histogram" button.

Picking an object, Doing the photometry, and Exploring the options

Use your mouse, scroll around in the image in the upper right, and find an object you wish to measure. Click on the object. In the lower center of the APT window, it gives you a greatly magnified version of the portion of the image you are investigating. You should use this zoom-in to try to center your object on the mouse cursor as accurately as possible - the better your initial guess, the easier it will be for the computer to correctly centroid the object.

The program did the photometry using its default values. The centroid radius (e.g., the max offset that it can calculate the centroid from your initial guess), the aperture radius, and the sky annulus parameters (inner and outer sky radius) are all set to particular values by default. They are in units of pixels. To figure out what these values are in arcseconds, look at the FITS header for your image. Click on "show FITS header" (top center), and find CDELT1 or CDELT2. These are the numbers of degrees per pixel. Convert this value to arcseconds by mulitplying by 3600 arcseconds/degree. Make sure that the aperture and annulus parameters are what you want them to be. (See this page for more discussion.)

IMPORTANT: By default, the current version of APT does NOT subtract off the background in the photometric calculation. You must enable background subtraction manually by clicking on the "More Settings" button and selecting the appropriate sky algorithm. Once background subtraction has been enabled and you have clicked on the "Recompute Photometry" button, the "Curve of Growth" plot will show the nice asymptotic behavior that you might expect.

You can use the following buttons to further explore your choice of aperture and annulus size. In each case, the aperture and annulus sizes are indicated, along with its calculated background level:

  • aperture slice - one-dimensional slice through the aperture. Allows you to investigate if the source is resolved or saturated.
  • curve of growth - how the total flux measured changes as a function of aperture
  • source scatter - range of pixel values within the aperture -- you can explore the effects of too large or small an aperture here.
  • radial profile - circularly averaged slice through the aperture. The PSF is circularly symmetric, so this allows you to explore the placement of the annulus (is it on top of the Airy ring?) and the level of the background more easily than the aperture slice option above. This also allows you to investigate whether the source is resolved or saturated.
  • sky scatter - range of pixel values within the sky annulus -- you can explore the effects of too large or small an annulus, or the influence of nearby sources or nebulosity, here.
  • sky histogram - histogram of pixel values within the sky annulus -- you can explore the effects of too large or small an annulus, or the influence of nearby sources or nebulosity, here.
  • hide/show aperture - should be obvious what this means!
  • color table toggle - changes the color table

If you change any of the values, you will need to ask it to 'recompute photometry' (button in the lower left). Changes in the requested aperture/annulus will be reflected in the display indicating the size of the annulus/aperture in the lower right, as well as in all the popup graphs you can get from clicking on the buttons described above.

The results of the photometry are reported under "RESULTS" in the lower left. Note that it recognizes the units of your input image (MJy/sr, DN, whatever) and reports the photometry in the same units. Review the information on Spitzer units, specifically as it applies to units of Spitzer images. In order to get it to report the photometry in Jy, instead of MJy/sr, you will need to derive the appropriate image data unit conversion factor, and corresponding reasonable units after conversion -- there's information on this on the Units page. Then go to "more settings" and enter those values in the corresponding boxes. If you click the "perform image data conversion" box, it will report the photometry in Jy (or whatever unit you want) on the main screen.

You can manually keep notes on the photometry you are calculating, or you can click the button that says "save results" to write the values for this object to a file. If you click on "show results", you can see the file it's accumulating. "Plot results" allows you to explore the distribution of results so far.

You should experiment enough with this tool to develop some intuition about what the various parameters do -- aperture and annulus are the two big ones to play with. How does the flux from a bright star change as you change the aperture, holding the annulus constant? A faint star? As you change the annulus (keeping the aperture constant)? Why does it do that? You can even make some plots interactively within APT -- the "curve of growth" refers to how the photometry changes as your aperture changes. For some of the other tests you might be able to devise, you might have to get into something like Excel to make some plots.

After you have settled on the aperture/annulus that works for your targets, if you have pre-assembled a list of objects whose RA/Dec or image pixel coordinates you already know, you can submit a list of targets to APT and have it do all the photometry on all the objects at once. Click on "source list" on the upper left to load a file. You have to tell the computer whether you are giving it pixel coordinates or RA/Dec. Caution -- pixel coordinates MAY NOT BE THE SAME between images, but RA and Dec (for the same objects) better be the same! Note that you will have to change the scale factor separately for each band, so you can't just load an image, load the source list, and be off and running. Think carefully about what you are doing. It's really easy to shoot yourself in the foot here. Take the photometry you get out with a grain of salt until you convince yourself it is right. Make some plots. Do they look like you expect? Do you get the same photometry as your neighbor, within errors?

Other Contributions

One of the 2010 teams developed APT Tutorial for Educational Poster, which may be helpful.