Project: datamanagement
Issue DM-1246: add per-exposure callbacks for measurement plugins
We should give measurement plugins an opportunity to do some work whenever we start processing a new Exposure. This give them a good time to throw exceptions when there's something obviously wrong with the exposure (e.g. it's missing a Psf). It also gives them an opportunity to do work that could be used to speed up per-source processing. One specific case I have in mind is in shapelet PSF approximation for galaxy fitting, where it could be very valuable to use an initial fit to an average PSF to initialize (and speed up) the first to per-source PSFs. One question here is how to to allow information to be passed from the per-Exposure method to the per-Source methods - we should not do that via plugin instance attributes, which means we probably want to have the per-Exposure method return an arbitrary object that would be passed to the per-Source methods. Unfortunately, I don't see a way to avoid having that change the signature for those methods for all existing plugins, so this should be done relatively early, before we have too many user-contributed plugins.
Story points: 3