Skip to content

Commit 7939753

Browse files
author
Takaya Uchida
committed
chunk angle to reduce memory usage
1 parent e4ff884 commit 7939753

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

xwavelet/wavelet.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def _morlet(xo, ntheta, a, s, y, x, dim):
7676

7777
# compute morlet wavelet
7878
th = np.arange(int(ntheta / 2)) * 2.0 * np.pi / ntheta
79-
th = xr.DataArray(th, dims=["angle"], coords={"angle": th})
79+
th = xr.DataArray(th, dims=["angle"], coords={"angle": th}).chunk({"angle": 1})
8080

8181
# rotated positions
8282
yp = np.sin(th) * s**-1 * (y - y.mean())

0 commit comments

Comments
 (0)