Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NDSL] QSat port #994

Merged
merged 25 commits into from
Sep 13, 2024
Merged

[NDSL] QSat port #994

merged 25 commits into from
Sep 13, 2024

Conversation

CharlesKrop
Copy link

@CharlesKrop CharlesKrop commented Sep 10, 2024

Functional port of GEOS_QSat function (and related calls). Function currently fails at majority of points (~86%) with old metric. New metric (not currently working on my machine) should show that these errors are small enough to be considered acceptable.

Errors can be traces back to differences in saturation pressure tables generates at QSat init. It is believed that these errors pop up because these tables are generated in standard python (gt4py is missing adequate extra dimension capabilities) and therefore executed in 64 bit

FlorianDeconinck and others added 14 commits August 14, 2024 14:30
QSatIce missing before test can be done
…. Fails to verify at majority of points using original metric, has not been tested with new metrics. Error patterns of the ES tables suggest arise during math within qsat_liquid and qsat_ice. Errors are small (10^-4). Further testing using find_klcl is in process to see if these errors propogate further or are locked within QSat.
…cil to calculate QSat for entire field, or function can be called from within the stencil to calculate QSat at individual points. To use function, the QSat class must be initialized before stencil call and the tables must be passed down to the function as an input.
…nctions are a port of QSATLQU0/QSATICE0 when UTBL is false.

Notable difference from QSat_Float: QSat_Float features a smooth transition from ice to liquid water (based on the TMIX parameter) while these two functions have a hard transition at 0C (should transition from calling one to the other).

UNTESTED FOR NOW, NO EASILY ACCESSABLE TEST CASE
…und for bad interaction between dace backend and cast to int
@CharlesKrop CharlesKrop requested review from a team as code owners September 10, 2024 17:09
@FlorianDeconinck FlorianDeconinck changed the title Merge dsl/QSat into dsl/develop [NDSL] QSat port Sep 10, 2024
@FlorianDeconinck FlorianDeconinck self-requested a review September 10, 2024 17:12
@FlorianDeconinck FlorianDeconinck added the 0 diff The changes in this pull request have verified to be zero-diff with the target branch. label Sep 10, 2024
Copy link
Collaborator

@FlorianDeconinck FlorianDeconinck left a comment

Choose a reason for hiding this comment

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

  • Merge dsl/develop and resolve conflicts
  • Run lint with pre-commit run --all-files
  • Radiation coupling & Aer Activation translates have been removed from __init__.py and file deleted. Revert

CharlesKrop and others added 9 commits September 10, 2024 14:06
…state of the code). Generated tables do not yet verify.
… differences between Fortran and C interpretation of constants (see GEOS-ESM/SMT-Nebulae#88 for more information). Table values are instead read in from netCDF file as a temporary solution.
Rename formulation to types
Revert run_tests.sh to common one
@FlorianDeconinck FlorianDeconinck self-requested a review September 13, 2024 17:02
Copy link
Collaborator

@FlorianDeconinck FlorianDeconinck left a comment

Choose a reason for hiding this comment

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

LGTM - working with netcdf based table

@FlorianDeconinck FlorianDeconinck merged commit 976c583 into dsl/develop Sep 13, 2024
3 checks passed
@FlorianDeconinck FlorianDeconinck deleted the dsl/QSat branch September 13, 2024 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0 diff The changes in this pull request have verified to be zero-diff with the target branch.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants