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

Two different definitions of saxis #112

Closed rjs3273 closed 1 year ago

rjs3273 commented 1 year ago

I think this may just be a typo in the docs or else I am not understanding something.

    class ImageReduction:

    def set_saxis(self, saxis=None):
        """
        Set the orientation of the image.

        Parameters
        ----------
        saxis: 0, 1 or None
            0 for a spectrum going left-right, 1 for top-down.

        """

But in TwoDSpec.set_properties you have

        +--------+--------+-------+-------+
        |  blue  |   red  | saxis |  flip |
        +========+========+=======+=======+
        |  left  |  right |   1   | False |
        +--------+--------+-------+-------+
        |  right |  left  |   1   |  True |
        +--------+--------+-------+-------+
        |  top   | bottom |   0   | False |
        +--------+--------+-------+-------+
        | bottom |  top   |   0   |  True |
        +--------+--------+-------+-------+

If I am using it correctly, the definition of saxis is right in TwoDSpec. Certainly using that definition works on my data. Is the definition wrong in ImageReduction.set_saxis() or is that saxis something different?

cylammarco commented 1 year ago

Yes you're right, in the ImageReduction, the document should read

0 for a spectrum going horizontally, 1 for vertically.

as the ImageReduction shouldn't care about the spectral information.

Fixed in 9103a77 and c4ca0bb.