forked from COSIMA/regional-mom6
-
Notifications
You must be signed in to change notification settings - Fork 2
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
MOM6 Angle Calculation #34
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ds are in segment right now. Something to discuss and then add
3 tasks
alperaltuntas
approved these changes
Dec 19, 2024
Checks passed, so I'm merging. If there's any last comments on this, they can be addressed in #33 |
2 tasks
manishvenu
added a commit
that referenced
this pull request
Jan 17, 2025
… tracers, add proper body tide parameters, add MOM6's angle calculation. (#33) * Add GFDL Rotation Code and minor tides debugging in setup_run_directory The GFDL rotation code was commented out🙈 * Black * Actual Angle Change * Minor Clean * Add First Regridding Option * More tidal changes * Change default tides to use all constituents in TPXO allowed in MOM6 * Fix Tests * Start of Angle Calc * Blacl * Rand * Clean up testing (#37) * Remove extra directories created * Black * Clean up created dirs * Rand * Keith Method Step 1, add t-point boundaries to coords() * Start implementing alternative angles approaches... * Set up rotational method framework * Add h, t, and change default mom6_angle_calc to regional * black * Fred Angle Calc * Black * Black 2 * Keith Method * Tidal Rotational Methods Completed * Finish rotational methods for velocity_tracers * Combine the grid_rotation_calc for fred_pseudo and mom6 general (keiths) * Move rotation/angle functions to a different file * Doesn't make sense to use rot method in expt because the regrid methods are in segment right now. Something to discuss and then add * Clean up the keith method to use the regridding func add_secondary_dimension * Add angle_calc to docs * Main Page Link for now... * Start testing setup * Change func name for consistency * Minor Commenting * Minor Commenting * Black * Redo Auto Docs * Start of testing * Test until curved grid generation comes in * Bug * Test_Rotation Changes * Adjust Docker Path * Testing Framework Trial 1 * Docker Docs * Test Cleaning * Change name of docker docs * Adjust docker image to crocodile one * Step 1: Setup Framework Tidal Regridding Nans/LandMask BugFix * Finish setting up masking framework * Clean up process of masking * Regridding Testing except for the mask functions * First round testing w/o mask tests * First Round Testing Completed * Minor Clean * MOM6 Angle Calculation (#34) * Start of Angle Calc * Blacl * Rand * Rand * Keith Method Step 1, add t-point boundaries to coords() * Start implementing alternative angles approaches... * Set up rotational method framework * Add h, t, and change default mom6_angle_calc to regional * black * Fred Angle Calc * Black * Black 2 * Keith Method * Tidal Rotational Methods Completed * Finish rotational methods for velocity_tracers * Combine the grid_rotation_calc for fred_pseudo and mom6 general (keiths) * Move rotation/angle functions to a different file * Doesn't make sense to use rot method in expt because the regrid methods are in segment right now. Something to discuss and then add * Clean up the keith method to use the regridding func add_secondary_dimension * Add angle_calc to docs * Main Page Link for now... * Start testing setup * Change func name for consistency * Minor Commenting * Minor Commenting * Black * Redo Auto Docs * Start of testing * Test until curved grid generation comes in * Bug * Test_Rotation Changes * Adjust Docker Path * Testing Framework Trial 1 * Docker Docs * Test Cleaning * Change name of docker docs * Adjust docker image to crocodile one * Step 1: Setup Framework Tidal Regridding Nans/LandMask BugFix * Finish setting up masking framework * Revert "Finish setting up masking framework" This reverts commit 9287030. * Revert "Step 1: Setup Framework Tidal Regridding Nans/LandMask BugFix" This reverts commit a2b961a. * respond to alper comments * Docs changes * Seg Fault Issue Pt1 * Disable threading * Just single threading * Clean up testing * Remove Single Threading * Add back single threading * Spelling Mistake * Zero Out Attempt * Black + Add Mask to Regrid_vt * Zero Out Corner + 3 Cell * Update Land Mask Tests * Fix Bathy NTiles Issue * Minor Cleaning + Variable Renaming * minor changes ahead of visualCaseGen integration in CrocoDash: - correct the first arg of a classmethod (from self to cls). - introduce optional write_to_file arg in setup_bathymetry. - introduce optional bathymetry obj arg in tidy_bathymetry. * Mirro GFDL NWA12-Cobalt a bit more and add diag table date adjustment * Black * Add aiohttp and copernicusmarine dependencies * add hgrid_path and vgrid_path args to __init__ to allow non-standard filenames. Similarly, add thickesses arg to _make_vgrid. * black reformatting * Update Initial Condition + Alternate Rotation Function * Rename get_glorys_rect to get_glorys * Move RM6 to logging over print statements, but still report regional_mom6 to stdout * Formatting * Fix logging bug * Revert RM6 Logging * Formatting * Alper Review Comments Pt1 * Relative Imports * Revert "Relative Imports" This reverts commit 15d8d36. * Check if the ESMF warning is the issue in the tests failure * Add Rotational Methods function * Small Adj to Docs' --------- Co-authored-by: alperaltuntas <alperaltuntas@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #31
Implement the MOM6 Angle Calculation in Regional MOM6. Add functions, classes to RM6 and adjust the regridding functions to accommodate these new angles.
Explanation/Visualization of the changes.
Major Notes & Changes:
Please see the document
angle_calc.md
for a more complete explanationrotation.py
) to implement MOM6 angle calculation & Fred, Keiths methods:modulo_around_point
: Implement MOM6 modulo_around_point.mom6_angle_calculation_method
: Implement MOM6 intialize_grid_rotation_angle function logic. Only the new version from MOM6 is includedinitialize_grid_rotation_angle
: This calculates t-point angle, which is what MOM6 does using the mom6_angle_calculation_methodinitialize_grid_rotation_angles_using_pseudo_hgrid
: Using Fred's pseudo hgrid that has an extra boundary row & col, calculate angle at every point in the original hgridcreate_pseudo_hgrid
: Fred calculation creating an extra boundary row & col on hgridRotationMethod
Enum Class: This class is to determine by which method we rotate the boundary conditions.regridding.py
:get_hgrid_arakawa_c_points
: Work from Fred splitting hgrid into the t, u, v, & q points converted to a RM6 functioncoords
changes: A change to thecoords
function to get the boundary t-points for Keith's method.regrid_tides
®rid_velocity_tracers
:test_rotation.py
: New test file for the rotationtest_rotation.py
, that is a crocodile image until someone with permissions updates the RM6 docker image, maybe we should have a CROCODILE one to? But probably notconftest.py
: Adds a fixture to skip a test if the files on the docker image don't exist on the computer (this is good for local testing)angle_calc.md
explaining this angle issue, anddocker_image_dev.md
for changing the docker image in the future./glade/u/home/manishrv/documents/nwa12_0.1/tides_dev/test_rotational_methods.ipynb
)