Aperture photometry
Photutils is an
affiliated package
of
Astropy
to provide tools for detecting and performing photometry of astronomical sources.
Example of star identification using a sourced image: JC:
- hdu_list = fits.open('filename')
- imgdata = hdu_list[0].data #if extracting data
- image = hdu.data[500:700, 500:700].astype(float) #select image subset copying array as a float
- image -= np.median(image) #subtract estimate of background using image median. Is this ok?
- bkg_sigma = mad_std(image) #background sigma estimated using median abs deviation of image
- daofind = DAOStarFinder(fwhm=4., threshold=3.*bkg_sigma) #Find stars: set detection threshold at 3 sigma
- parameters of detected sources returned in astropy table:
- positions = (sources['xcentroid'], sources['ycentroid']) #accessing position related columns
- apertures = CircularAperture(positions, r=4.) #circular aperture radius = 4 pixels
- phot_table = aperture_photometry(image, apertures) #input 2D array (bk subtracted) output QTable

- plt.imshow()
- apertures.plot
plot of mean vs exposure time taking the log of the x axis:
Found an aperture photometry sofware that would allow us to prefectly select the area in which we are interested.
Aperture Photometry Tool (APT) is software for astronomical research, as well as for learning, visualizing and refining aperture-photometry analyses. Image overlays, graphical representations, statistics, models, options and controls for aperture-photometry calculations are brought together into a single package. Professional astronomers appreciate APT’s rich set of features and functions, and you will, too. APT is free of charge under a license that limits its use to astronomical research and education. It is perfect for the science center, observatory, and classroom. Also, it is quite simply the best FITS-image viewer you will find. Click
here for a tutorial on Aperture Photometry Tool.
The software produces histograms, background analysis and so much more. We can estimate the brithness of each star in a image.
Website:
http://www.aperturephotometry.org
Features and functions:
http://www.aperturephotometry.org/aptool/documentation/features-and-functions/#aps
A paper about the software, describing what the software can be used for and some instruction on performing certain data analyses:
http://iopscience.iop.org/article/10.1086/666883/pdf