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

[F32] Divergence Damping #36

Merged

Conversation

FlorianDeconinck
Copy link
Collaborator

@FlorianDeconinck FlorianDeconinck commented Dec 11, 2024

We need to make sure scalars are properly type so 64-bit computation does not bleed into a 32-bit based computation

Also, removed an extraneous subset slicing in translate test which was a previous strategy to deal with expected NaNs in the test data

This should not change 64-bit calculations and therefore is ready for develop

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules
  • New check tests, if applicable, are included
  • Targeted model if this changed was triggered by a model need/shortcoming

Remove extraneous subset slicing in translate test
@@ -60,13 +60,3 @@ def compute_from_storage(self, inputs):
)
self.divdamp(**inputs)
return inputs

def subset_output(self, varname: str, output):
Copy link
Collaborator

Choose a reason for hiding this comment

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

Was this really only for NaNs?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's my conclusion. The damping is an all domain op, so I don't know why it would require any subseting apart from the fact that the halos carry some NaNs in the translate test

Copy link
Collaborator

@oelbert oelbert left a comment

Choose a reason for hiding this comment

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

👍

@FlorianDeconinck FlorianDeconinck merged commit a18aca8 into NOAA-GFDL:develop Dec 20, 2024
4 checks passed
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.

3 participants