Does anyone know how I get a zeropoint for a particular sensor from the butler?
This seems to work fine:
lsst.afw.image.Calib(butler.get("calexp_md", ...)).getFluxMag0()
In addition, @rhl has pointed out that extracting the zeropoint is often unnecessary, and
calib.getMagnitude(flux, fluxErr)
should be used instead.
1 Like
I.e.
calib = lsst.afw.image.Calib(butler.get("calexp_md", ...))
calib.getFluxMag0()
Iām not all that happy requiring users to ask the butler for the metadata then contructing the Calib by hand ā that seems like an implementation detail. Will the nbutler allow
calib = butler.get("calib", ...)
?
The Old Butler can do that; it just requires more code embedded in a poor place. The New Butler should make it easier to have plugins that can do this without dependency issues.