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

[WIP] Compatibility with original TPXO data #254

Open
wants to merge 18 commits into
base: main
Choose a base branch
from

Conversation

NoraLoose
Copy link
Collaborator

Issues

This is a work-in-progress (WIP) PR addressing issues #141 and #251, both of which relate to the TidalForcing class. The current issues can be summarized as follows:

  1. Incompatibility with original TPXO data: Currently, ROMS-Tools only accepts tidal forcing files that have been post-processed by UCLA-ROMS, rather than the original TPXO data.
  2. Grid Assumptions: The current implementation incorrectly assumes that all TPXO variables share the same lat/lon grid, while zonal and meridional tidal transports actually reside on separate grids. This needs to be addressed in the implementation.
  3. Constituent Correction: The correction functions are hardcoded for 15 tidal constituents without validating their order, which can lead to incorrect corrections when reading the original TPXO data. Metadata checks should be added to ensure accuracy.

To solve 1., this PR needs to switch to a more complex user interface, namely from

tidal_forcing = TidalForcing(
    grid=grid,
    source={
        "name": "TPXO",
        "path": path,
    }
)

to

tidal_forcing = TidalForcing(
    grid=grid,
    source={
        "name": "TPXO",
        "path": {
            "grid": path_tpxo_grid,
            "h": path_tpxo_h,
            "u": path_tpxo_u,
            "sal": path_tpxo_sal,
        },
    },
)

Checklist

  • Closes #xxxx
  • Tests added
  • Passes pre-commit run --all-files
  • Changes are documented in docs/releases.md
  • New functions/methods are listed in docs/api.rst
  • New functionality has documentation

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.

1 participant