Skip to content

Added coupled transm to heurstic atmosphere#686

Merged
unbohn merged 1 commit into
isofit:devfrom
evan-greenbrg:bugs/h2o_init
May 9, 2025
Merged

Added coupled transm to heurstic atmosphere#686
unbohn merged 1 commit into
isofit:devfrom
evan-greenbrg:bugs/h2o_init

Conversation

@evan-greenbrg

Copy link
Copy Markdown
Collaborator

There is a potential bug in the heursitic_atmosphere function when using the full 4c radiance model.

Currently, the transm variable in the function is initialized only with the downwards components:

transm = instrument.sample(
    x_instrument, RT.wl, rhi["transm_down_dir"] + rhi["transm_down_dif"]
) 

Regardless if this is the behavior we want, it is inconsistent with the 1c implementation where the populated transm LUT variable contains the full coupled transmittance spectrum. To make this consistent:

transm = instrument.sample(
    x_instrument,
    RT.wl,
    (rhi["transm_down_dir"] + rhi["transm_down_dif"]) * (rhi["transm_up_dir"] + rhi["transm_up_dif"])
)

First pass tests show that this fixes the initial issue of poor water vapor retrievals with the 4c model:

Screenshot 2025-05-09 at 9 15 02 AM

@evan-greenbrg evan-greenbrg requested a review from unbohn May 9, 2025 16:28
@unbohn

unbohn commented May 9, 2025

Copy link
Copy Markdown
Collaborator

Thanks for this catch, @evan-greenbrg! It's an important fix. File changes are reasonable and clear, tests have passed, so I'll merge right away.

@unbohn unbohn merged commit 55161ed into isofit:dev May 9, 2025
17 checks passed
@evan-greenbrg evan-greenbrg deleted the bugs/h2o_init branch May 22, 2026 15:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants