photutils icon indicating copy to clipboard operation
photutils copied to clipboard

Make bkg_estimator keyword optional in BasicPSFPhotometry

Open astrofrog opened this issue 6 years ago • 1 comments

Currently in BasicPSFPhotometry the bkg_estimator argument can be None, but since it is a positional argument it has to be specified. I think it would make sense to make it (and other following arguments) keyword arguments to avoid having to set it explicitly to None?

astrofrog avatar Oct 18 '19 12:10 astrofrog

I'll leave this one to @larrybradley or @eteq for any reasoning as to why things are the way they are, but one counterargument at least could be the logic of forcing a user to specify their background subtraction explicitly, as you could end up with situations where users didn't think about the bkg_estimator keyword and did a bunch of reductions on non-background subtracted images, but this way they have to read the docstring to know what to put in.

Don't necessarily disagree that forcing a bkg_estimator=None argument is slightly odd when you put it that way so am inclined to agree, but will hold off on making any changes until I get a second opinion.

Onoddil avatar Oct 21 '19 01:10 Onoddil