Skip to content

Commit b58ff34

Browse files
committed
Merge branch 'main' into update-faq-documentation
2 parents f0525d3 + e9a1de4 commit b58ff34

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+12692
-2347
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,12 @@ asv_bench/pkgs
7070
# xarray specific
7171
doc/_build
7272
doc/generated/
73+
doc/api/generated/
7374
xarray/tests/data/*.grib.*.idx
7475

76+
# Claude Code
77+
.claude/
78+
7579
# Sync tools
7680
Icon*
7781

.pre-commit-config.yaml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,7 @@ repos:
7373
hooks:
7474
- id: validate-pyproject
7575
additional_dependencies: ["validate-pyproject-schema-store[all]"]
76-
- repo: https://github.com/crate-ci/typos
77-
rev: v1
76+
- repo: https://github.com/adhtruong/mirrors-typos
77+
rev: v1.34.0
7878
hooks:
7979
- id: typos
80-
# https://github.com/crate-ci/typos/issues/347
81-
pass_filenames: false

asv_bench/benchmarks/interp.py

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,23 +25,37 @@ def setup(self, *args, **kwargs):
2525
"var1": (("x", "y"), randn_xy),
2626
"var2": (("x", "t"), randn_xt),
2727
"var3": (("t",), randn_t),
28+
"var4": (("z",), np.array(["text"])),
29+
"var5": (("k",), np.array(["a", "b", "c"])),
2830
},
2931
coords={
3032
"x": np.arange(nx),
3133
"y": np.linspace(0, 1, ny),
3234
"t": pd.date_range("1970-01-01", periods=nt, freq="D"),
3335
"x_coords": ("x", np.linspace(1.1, 2.1, nx)),
36+
"z": np.array([1]),
37+
"k": np.linspace(0, nx, 3),
3438
},
3539
)
3640

3741
@parameterized(["method", "is_short"], (["linear", "cubic"], [True, False]))
38-
def time_interpolation(self, method, is_short):
42+
def time_interpolation_numeric_1d(self, method, is_short):
3943
new_x = new_x_short if is_short else new_x_long
40-
self.ds.interp(x=new_x, method=method).load()
44+
self.ds.interp(x=new_x, method=method).compute()
4145

4246
@parameterized(["method"], (["linear", "nearest"]))
43-
def time_interpolation_2d(self, method):
44-
self.ds.interp(x=new_x_long, y=new_y_long, method=method).load()
47+
def time_interpolation_numeric_2d(self, method):
48+
self.ds.interp(x=new_x_long, y=new_y_long, method=method).compute()
49+
50+
@parameterized(["is_short"], ([True, False]))
51+
def time_interpolation_string_scalar(self, is_short):
52+
new_z = new_x_short if is_short else new_x_long
53+
self.ds.interp(z=new_z).compute()
54+
55+
@parameterized(["is_short"], ([True, False]))
56+
def time_interpolation_string_1d(self, is_short):
57+
new_k = new_x_short if is_short else new_x_long
58+
self.ds.interp(k=new_k).compute()
4559

4660

4761
class InterpolationDask(Interpolation):

ci/install-upstream-wheels.sh

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,7 @@ python -m pip install \
3535
numpy \
3636
scipy \
3737
matplotlib \
38-
pandas
39-
# for some reason pandas depends on pyarrow already.
40-
# Remove once a `pyarrow` version compiled with `numpy>=2.0` is on `conda-forge`
41-
python -m pip install \
42-
-i https://pypi.fury.io/arrow-nightlies/ \
43-
--prefer-binary \
44-
--no-deps \
45-
--pre \
46-
--upgrade \
38+
pandas \
4739
pyarrow
4840
# manually install `pint`, `donfig`, and `crc32c` to pull in new dependencies
4941
python -m pip install --upgrade pint donfig crc32c

0 commit comments

Comments
 (0)