photutils icon indicating copy to clipboard operation
photutils copied to clipboard

Add option to set the method for aperture photometry measurements in the PSF photometry loop

Open eteq opened this issue 8 years ago • 2 comments

Right now the PSF photometry machinery depends on doing CircularAperture photometry to make initial flux estimates. That makes sense for many use cases, but there are some situations where you don't want to do that. E.g., if your model is highly elliptical, or you know the image is very crowded, or you just don't like the default aperture sizes.

So I'd suggest taking the code that currently does it (For example https://github.com/astropy/photutils/blob/97e38c3e507871af5d18219012b345c15509b9ce/photutils/psf/photometry.py#L256 , although it also appears 2 other places), and replacing it with a new attribute aperture_photometry, a la the finder and group_maker attributes. The current situation could be left as the default (It could just be a function given that it's really quite simple), but then the user has the option to swap in there own way of doing it.

Does this make sense to you @mirca ? (I can try to implement it myself if you don't think you'll have time, but either way it'd be good to get your opinion...)

eteq avatar Jan 26 '17 23:01 eteq

I really like this idea, and if @mirca thinks it makes sense, then I'll make sure it gets into 0.4 (either by bugging the two of you with it or try to implement it myself :))

bsipocz avatar Jan 26 '17 23:01 bsipocz

@eteq @bsipocz It absolutely makes sense! Let the user customize it as much as possible :) I will prioritize #471, and then I can come to this :)

mirca avatar Jan 27 '17 13:01 mirca