Pipeline distortion correction
About
This MR brings the ID16 flats distortion correction to the GPU pipeline.
Close #301 (closed)
To do
-
Update chunked.py
so that distortion correction can still be used -
Switch processing to GPU after flat-field -
End-to-end reconstruction tests
Notes
The ID16 flats distortion correction is done as follows:
- estimation of the flat distortion with
nabu.estimation.distortion.estimate_flat_distortion()
- correction with
nabu.preproc.distortion.correct_distortion_interpn()
The estimation step (1) is quite involved (it uses DetectorTranslationAlongBeam
, conditional median filtering, and scipy.interpolate.interp2d
with cubic interpolation.
The correction step (2) is more straightforward (scipy.interpolate.interpn
with linear mode).
Porting all steps of (1) on GPU would be time-consuming, for a relatively isolated usage.
So the implementation will do the flatfield on CPU, before switching to GPU.
Edited by Pierre Paleo