kevin218 / Eureka

Eureka! is a data reduction and analysis pipeline intended for time-series observations with JWST.
https://eurekadocs.readthedocs.io/
MIT License
58 stars 45 forks source link

[Bug]: x-axes inconsistent on Stage 3 output plots #570

Closed arikaegan closed 6 months ago

arikaegan commented 10 months ago

FAQ check

Instrument

MIRI (Stages 1-3)

What happened?

The x-axes are inconsistent between the 2D Background Subtracted Frame( e.g. fig3301_file0_int00000_ImageAndBackground.png) plots and the 1D Spectrum plots (e.g. fig3302_file0_int00000_Spectrum.png). It seems like the 1D spectrum plots have the Detector Pixel Position flipped.

Error traceback output

No response

What operating system are you using?

No response

What version of Python are you running?

No response

What Python packages do you have installed?

No response

Code of Conduct

taylorbell57 commented 10 months ago

Ah indeed, the x-axis for Fig 3301 is labelled backwards for MIRI observations only, and for Fig 3302 it would probably be best to invert the x-axis so that short wavelengths are on the left. I'll aim to fix this minor bug in a week or so

taylorbell57 commented 9 months ago

Alright, looking more carefully it looks like even more plots are messed up for MIRI. Specifically, figs 3301, 3303?, 3308, and 3506 have the detector pixels labelled backwards, and fig 3302 should be flipped so that wavelength increases toward the right and not pixel position. It's also not immediately clear to me if the column numbering in figs 3501 are in the correct for MIRI. While I'm at it, fig 3304 appears not to be using bbox_inches='tight' or something since parts of the plot are getting cut off in the saved image.

I'll work on this today and hopefully submit a PR.

taylorbell57 commented 6 months ago

PR #600 resolved the issues with figures 3301, 3302, 3308, and the bug with 3304 doesn't seem to occur anymore. That only leaves figs 3303 and 3506 which aren't wrong but just use different units (relative pixel position rather than detector pixel position). This seems fine to me, so I'm going to close this issue now