Skip to content

Commit 51ee64c

Browse files
committed
Update readme, add demo notebook for most_common
1 parent 7d43594 commit 51ee64c

File tree

4 files changed

+370
-10
lines changed

4 files changed

+370
-10
lines changed

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
1-
# xarray-regrid
2-
Regridding utilities for xarray.
1+
# xarray-regrid: Regridding utilities for xarray.
32

4-
Note: currently only rectilinear grids are supported.
3+
<img align="right" width="100" alt="Logo" src="./docs/assets/logo.png">
54

6-
For now xarray-regrid is mostly a wrapper around `ds.interp`, however, conservative regridding is not possible with `interp`, and will need a custom solution.
5+
With xarray-regrid it is possible to regrid between two rectilinear grids. The following methods are supported:
6+
- Linear
7+
- Nearest-neighbor
8+
- Conservative
9+
- Cubic
10+
- "Most common value"
711

812
## Installation
913

@@ -19,11 +23,10 @@ import xarray_regrid
1923
ds = xr.open_dataset("input_data.nc")
2024
ds_grid = xr.open_dataset("target_grid.nc")
2125

22-
ds.regrid.regrid(ds_grid, method="linear")
26+
ds.regrid.linear(ds_grid)
2327
```
24-
Currently implemented are the methods linear, nearest and cubic.
2528

26-
For examples, see the benchmark notebooks.
29+
For examples, see the benchmark notebooks and the demo notebooks.
2730

2831
## Benchmarks
2932
The benchmark notebooks contain comparisons to more standard methods (CDO, xESMF).
@@ -35,6 +38,3 @@ You can install this environment using the `environment.yml` file in this reposi
3538
```sh
3639
micromamba create -n environment_name -f environment.yml
3740
```
38-
39-
## Planned features
40-
- Support conservative regridding

demo/demo_most_common.ipynb

Lines changed: 162 additions & 0 deletions
Large diffs are not rendered by default.

docs/assets/logo.png

14.8 KB
Loading

docs/assets/logo.svg

Lines changed: 198 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)