Open pgierz opened 2 weeks ago
This pull request introduces several changes to integrate FESOM (Finite-Element/volumetric Sea-Ice Ocean Model) functionality into the project. The key changes include updates to CI workflows, new dependencies, and the addition of FESOM-specific regridding functionality. Additionally, there are several updates to the testing framework to accommodate the new features.
.github/workflows/CI-test.yaml
).fesom
extra dependencies (.github/workflows/CI-test.yaml
)..gitmodules
.pyfesom2
as a dependency under the fesom
extra in setup.py
.fesom.py
with functions for regridding FESOM data and a new pipeline class FESOMRegridPipeline
(src/pymorize/fesom.py
).FrozenPipeline
class to support named pipelines and steps (src/pymorize/pipeline.py
). [1] [2] [3] [4]tests/configs/fesom_pi_mesh_run.yaml
, tests/fixtures/config_files.py
, tests/fixtures/configs.py
, tests/fixtures/datasets.py
). [1] [2] [3] [4] [5]tests/externals/test_pyfesom2.py
, tests/unit/test_fesom.py
). [1] [2]Documentation Preview: https://pymorize.readthedocs.io/en/feat-fesom-regridding/pymorize_fesom.html
Summary
@chrisdane wanted FESOM regridding to a regular grid. This PR incorporates
pyfesom2
and uses it's internal tools to convert to a regular grid via nearest neighbor interpolation. You should specify the grid description (probably best to do this in theinherit
section of the config), and add the pipeline to the steps you want to take. Provides both a step to include in custom pipelines as well as a pre-built pipeline that performs the regridding stepTODO:
Commits:
Copilot Summary
This pull request introduces several significant changes to the codebase, including enhancements to the CI testing workflow, the addition of new submodules and dependencies, and the implementation of new functionalities for FESOM data processing. Below is a summary of the most important changes:
CI Workflow Enhancements:
CI-test.yaml
to include verbose output and coverage options forpytest
and added doctest modules for thesrc
directory.Submodules and Dependencies:
tests/data/test_experiments/piControl_on_PI/mesh/pi
in.gitmodules
.pyfesom2
under thefesom
extra insetup.py
.FESOM Data Processing:
regrid_to_regular
function andFESOMRegridPipeline
class insrc/pymorize/fesom.py
for regridding FESOM data to a regular grid.FrozenPipeline
and its subclasses insrc/pymorize/pipeline.py
to use class-level attributes forNAME
andSTEPS
, and refactored the initialization method accordingly. [1] [2] [3] [4]Test Configuration and Fixtures:
tests/configs/fesom_pi_mesh_run.yaml
for FESOM mesh run tests.tests/conftest.py
and added new fixtures intests/fixtures
to support FESOM data tests. [1] [2] [3] [4] [5]regrid_to_regular
function intests/unit/test_fesom.py
.