Jointcal is now available for beta testing.
Jointcal is a package for performing simultaneous astrometric and photometric fitting of multiple visits of the same field to determine the optical distortions and photometric calibration of the system as a whole. I have run it on a variety of test data, but it’s time to start poking at it in other ways, hence this beta test announcement.
Requirements
You can install jointcal in the usual manner (e.g., rebuild jointcal
in lsstsw).
- LSST stack v13.0 or higher.
- jointcal_cholmod (a linear algebra package)
- optional dependency on testdata_jointcal (a little over 1 GB of pre-processed catalogs from multiple instruments) in order to run the included unittests.
- a butler repository processed with stack v13.0 or higher (jointcal requires processed catalogs with a fully-populated VisitInfo).
Usage
Jointcal can be executed as a CmdlineTask in the usual manner, specifying an input butler repository, output directory, and data ids. See examples/jointcal_validation_data_hsc.sh
for an example of how to run jointcal as a CmdlineTask on the validation_data_hsc
dataset (Note: that product is ~400GB git lfs; you’ll have to reprocess it to v13.0 or wait for it to be updated to that level, in order to use that script).
Configurables of interest include astrometryRefObjLoader
(defaults to Astrometry.net, but can be retargetted to LoadIndexedReferenceObjectsTask
) and doPhotometry
(given caveat 2. below, you may want to set this to “False”).
The fitted model is written to a butler “wcs” Exposure object, containing the fitted Wcs
and Calib
, but no pixels or other metata. One can use lsst.afw.table.utils.updateSourceCoords(wcs.getWcs(), cat)
to update in-place the Coords in a Catalog, given that new wcs
. Jointcal also includes bin/plot_jointcal_results.py
, to help evaluate the results of the fit.
Caveats:
- The default astrometric fitter does not include the full-focal plane term (see DM-9506 for the plan to make that configurable). Even with that, the astrometric fit should be noticeably better than single frame processing, and will improve with more visits of a field being available.
- The photometric fitter will do no better than single frame processing (see DM-9184 for progress on the next step).
- The fitting step is very fast, but a fair bit of the time is taken up reading the calexps (which should improve drastically once DM-9153 is completed).
Once points 1. and 2. are dealt with, jointcal will be RFC’d to become part of lsst_distrib. For the HSC folks out there, that’s also the point at which I’d say we could probably replace meas_mosaic with jointcal (possibly after some head-to-head comparisons).
Thanks to @boutigny and @PierreAstier for their initial work on meas_simastrom, on which jointcal is based.