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

Trimming grid halo as part of the preprocessing #266

Open
jbusecke opened this issue Oct 4, 2022 · 1 comment
Open

Trimming grid halo as part of the preprocessing #266

jbusecke opened this issue Oct 4, 2022 · 1 comment

Comments

@jbusecke
Copy link
Owner

jbusecke commented Oct 4, 2022

I just learned that some models for CMIP6 include the 'halo' cells (to e.g. accomodate the periodic boundary condition along the x axis) in the output, potentially causing issues with analysis and e.g. remapping to different coordinates.

If there is a quick automatic way to identify which cells (e.g. which end and how much) to trim, this would be a good thing to include in xMIP IMO.

@jbusecke
Copy link
Owner Author

I did some more digging here. I concluded from this that we really only need to remove two latitude/y columns at each side, IF they are all nans. But doing that naively might lead to trouble with e.g. datasets that have x and y swapped (#311).

Leaving this to simmer a bit, but if somebody needs a fix for now it could look like this:

  • For both dimensions (x/y) Check if both ends have an all nan column, but not more than one row! This is to avoid clipping the y/latitude dimension, which most of the time has a bunch of nan rows over antarctica.

Still might need some more research on this, particularly with other output (e.g. land, atmos).

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

No branches or pull requests

1 participant