kevin218 / Eureka

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

Fixing new POET bugs, and old bugs with multwhite fits, masked values in fits, nbin_plot in S5, and S6 model loading #631

Closed taylorbell57 closed 4 months ago

taylorbell57 commented 4 months ago

Fixing new POET bugs and old bugs

Old bugs include issues with multwhite fits, masked values, and nbin_plot dealing with nbin_plot=len(time) in the presence of masked values.

New POET bugs include improperly handling multi-channel (or multwhite) fits (because only the values for channel 0 were ever used), and a broken alias between fp and fpfs.

Also fixing a bug in S6 related to load_model function.

taylorbell57 commented 4 months ago

This PR includes patches that will be merged into PR #609, and this PR should be merged first

taylorbell57 commented 4 months ago

@kevin218 alright, I believe I've fixed the key remaining bugs. The one remaining question I have is the intended units for the cos1_amp terms. At present, a value of 0.5 gives a nightside flux (aka at mid-transit) of zero - that's how the SinusoidPhaseCurve terms work and is totally fine, but you or others may desire for a value of 1 to mean zero nightside flux (as I assume you intend based on your template EPFs). If you do want this, then you can just multiply the values by 0.5 within the POET code to allow cos1_amp to vary between zero and one.

kevin218 commented 4 months ago

@taylorbell57 I resolved the issue with the phase curve amplitude in #609. It was a little more complicated than either of us probably expected, but I'm happy with the final result.