Skip to content

1154 energy balance for understory vegetation#1183

Merged
vgro merged 24 commits intodevelopfrom
1154-energy-balance-for-understory-vegetation
Dec 8, 2025
Merged

1154 energy balance for understory vegetation#1183
vgro merged 24 commits intodevelopfrom
1154-energy-balance-for-understory-vegetation

Conversation

@vgro
Copy link
Copy Markdown
Collaborator

@vgro vgro commented Dec 8, 2025

This PR adds the energy balance for the understorey vegetation following the idea of the forest floor litter model by J. Ogee and Y. Brunet (2002).

The main step is to solve the energy balance for the understorey, similar to the canopy, and add a conductive flux towards the soil. The updated docs are here.

I also fixed the vertical mixing which caused the model to crash and added some functions to make things a bit tidies, like update_profile_from_reference.

This step revealed a whole bunch of gaps and problems which should be addressed separately to stop this PR from getting more complicated (and clarified some of the older issues, should be doable now):

Fixes #1154

Type of change

  • New feature (non-breaking change which adds functionality)
  • Optimization (back-end change that speeds up the code)
  • Bug fix (non-breaking change which fixes an issue)

Key checklist

  • Make sure you've run the pre-commit checks: $ pre-commit run -a
  • All tests pass: $ poetry run pytest

Further checks

  • Code is commented, particularly in hard-to-understand areas
  • Tests added that prove fix is effective or that feature works
  • Relevant documentation reviewed and updated

@vgro vgro linked an issue Dec 8, 2025 that may be closed by this pull request
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Dec 8, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.43%. Comparing base (d9a335b) to head (5353e9a).

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1183      +/-   ##
===========================================
+ Coverage    94.39%   94.43%   +0.04%     
===========================================
  Files           71       71              
  Lines         7169     7229      +60     
===========================================
+ Hits          6767     6827      +60     
  Misses         402      402              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Collaborator

@jacobcook1995 jacobcook1995 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't follow all of the science, but it looks good to me in general, only had a few minor comments

Copy link
Copy Markdown
Collaborator

@davidorme davidorme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All looks good to me - well documented too!

@vgro vgro merged commit 6064e80 into develop Dec 8, 2025
13 checks passed
@vgro vgro deleted the 1154-energy-balance-for-understory-vegetation branch December 8, 2025 15:50
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.

Energy balance for understory vegetation

4 participants