OceanTools are a set of useful functions that are necessary for OceanBench.
An agnostic suite of geoprocessing tools for xarray datasets that were aggregated from different sources
It is lightweight in terms of the core functionality. We keep the code base simple and focus more on how the user can combine each piece. We adopt a strict functional style because it is easier to maintain and combine sequential transformations.
We use conda/mamba as our package manager. To install from the provided environment files run the following command.
git clone https://github.com/jejjohnson/oceanbench.git
cd oceanbench
mamba env create -n environments/linux.yaml
if you want to add the oceanbench conda environment as a jupyter kernel, you need to set the ESMF environment variable:
conda activate oceanbench
mamba install ipykernel -y
python -m ipykernel install --user --name=oceanbench --env ESMFMKFILE "$ESMFMKFILE"
We can directly install it via pip from the.
conda create -n ocntools
cd ocntools
mamba install xesmf -c conda-forge
pip install "git+https://github.com/jejjohnson/ocn-tools.git"
Note: There are some known dependency issues related to pyinterp
and xesmf
.
You will need to manually install some of the dependencies before installing oceanbench via pip.
See the pyinterp and xesmf packages for more information.
For developers who want all of the dependencies via pip, we can use poetry to install the package.
git clone https://github.com/jejjohnson/ocn-tools.git
cd ocntools
conda create -n ocntools python=3.11 poetry
poetry install
We would like to acknowledge the Ocean-Data-Challenge Group for all of their work for providing open source data and a tutorial of metrics for SSH interpolation.