cylammarco / ASPIRED

Automated SpectroPhotometric Image REDuction (ASPIRED)
https://aspired.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
30 stars 4 forks source link

Optimal extraction for curved spectra #44

Closed cylammarco closed 3 years ago

cylammarco commented 3 years ago

See Marsh 1989.

cylammarco commented 3 years ago

Marsh algorithm only works on highly tilted spectra, not curved spectra.

See Nicolai et al. 2020 for an algorithm that can cope with highly curved Echelle spectra.

https://github.com/AWehrhahn/PyReduce/

rjs3273 commented 3 years ago

That's interesting. You are just going to tell me to read the paper, but what's the problem with the Marsh algorithm? Without having tried it, in my mind I imagined that because the Marsh algorithm works across the chip pixel by pixel, locally, at the pixel being processed, a curved or tilted spectrum were the same thing. As long as the radius of curvature is very much more than one pixel, why are tilted and curved different? I guess I can see the sky getting more complicated.

cylammarco commented 3 years ago

Precisely, the sky modelling is getting complicated. A highly-tilted spectrum is only distorted in one axis direction, while in practice, spectra are usually distorted in both axis directions. Without considering the distortion in the other direction, the uncorrected curvature can lead to bad sky subtraction. All these are obvious but difficult to quantify... so I tried it with a FLOYDS spectrum, and it doesn't work well..: image

This figure illustrates how the subsmapling has to handle both x and y direction simultaneously in order to perform extraction properly without resampling:

image (from https://www.aanda.org/articles/aa/full_html/2021/02/aa38293-20/F7.html)

cylammarco commented 3 years ago

Including the PyPI latest version of pyreduce-astro as a dependency (see also https://github.com/AWehrhahn/PyReduce). This is the official software developed by the authors in that paper. This will be available in the next release.

cylammarco commented 3 years ago

The dependence on PyReduce is removed due to the requirement of an indepedent sky spectrum for sky subtraction. An image rectification process is added instead.