NOAA-ORR-ERD / LibGOODS

Library for accessing data useful for the NOAA / GNOME model
https://libgoods.readthedocs.io/en/latest/
Other
1 stars 2 forks source link

Handling longitude coordinate system #48

Open ChrisBarker-NOAA opened 1 year ago

ChrisBarker-NOAA commented 1 year ago

Some models use -180 -> 190, and some use 0 -> 360, and which is appropriate depends on what part of the world one is interested in.

A start in this that will handle many (most>) cases was done in: #46

But we left that with a bit more that can be done -- summarized here:

So:

1) Translate the user's supplied BB into the coords the model uses 2) Do the subset 3) Translate the results back into the coords the user requested.

When in doubt, default to -180--180

Raise an error if the result is empty. (we want any anyway just to catch mistakes)

Raise an error (I think,maybe warning???) if the user asks for what would be a disjoin result, e.g.

The question is whether to raise an error or return a disjoint result, so the user can fix it themselves later.