Hi all!

First things first; the following links point out to the pull requests that I worked on during the course of my GSoC project:

- #367: Create PSF subpackage
- #369: Add an implementation of daophot GROUP functionality
- #376: Add a way to get params uncertainties in psf_photometry
- #379: findstars oop interface
- #385: PSF Photometry in Crowded Fields
- #404: [DOC]: Narrative docs for PSF Photometry
- #5: Notebook for psf-photometry in crowded fields

My project was entitled "Implement Point Spread Function (PSF) photometry for fitting several overlapping objects at once". The basic question is, given an astronomical image, "How to estimate the flux and the positions of each star when there exist overlap between them?".

To make our lives easier, we broke this question in smaller ones, for instance, "Which stars are overlapping?". To answer this question, we implemented (#369 ) the GROUP algorithm proposed by Stetson (1987) which is used in the IRAF/DAOPHOT software.

It is assumed that the point spread function (which is the optical system's impulsive response) has a known model with unknown parameters (and we would like to estimate them). Mathematically, assume that is the parameter space (i.e. the space of possible values that the parameters can assume).

Usually, the parameters are the center position and the flux of the star. In this case, is reduced to . As the parameters are positive real-valued numbers and if we would like to fit only one star at at time, then the optmization algorithm will search for solutions over the space.

If is the PSF model (for example a Gaussian model), , then the model for a group of stars is given as

Note that, the space of possible solutions is not the positive part of the 3D space anymore, it is the positive part of the 3nD space =o

Fortunately, Scipy scientists already implemented awesome optimization algorithms and some of then are encapsulated in astropy.modeling :)

After finding the groups of stars, the algorithm proceeds to fit the stars in each group simultaneously. Right after fitting a given group, that group is subtracted from the original image (forming a "residual image").

All these steps are enclosed in DAOPhotPSFPhotometry class, which is the main contribution of my project GSoC project.

In addition, please, see this notebook here for examples on how to use DAOPhotPSFPhotometry.