Skip to content

Commit 37ca2f5

Browse files
committed
Fix incorrect array dimensions in docstrings
1 parent 1cff4d0 commit 37ca2f5

File tree

4 files changed

+14
-12
lines changed

4 files changed

+14
-12
lines changed

pysteps/cascade/bandpass_filters.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,23 @@
33
44
The methods in this module implement the following interface:
55
6-
filter_xxx(L, n, optional arguments)
6+
filter_xxx(shape, n, optional arguments)
77
8-
where L is size of the input field, respectively, and n is the number of
9-
frequency bands to use.
8+
where shape is the shape of the input field, respectively, and n is the number
9+
of frequency bands to use.
1010
1111
The output of each filter function is a dictionary containing the following
1212
key-value pairs:
1313
14-
weights_1d 2d array of shape (n, L/2) containing 1d filter weights
14+
weights_1d 2d array of shape (n, r) containing 1d filter weights
1515
for each frequency band k=1,2,...,n
16-
weights_2d 3d array of shape (n, L, L) containing the 2d filter
16+
weights_2d 3d array of shape (n, M, N) containing the 2d filter
1717
weights for each frequency band k=1,2,...,n
1818
central_freqs 1d array of shape n containing the central frequencies of
1919
the filters
2020
21+
where r = int(max(N, M)/2)+1
22+
2123
The filter weights are assumed to be normalized so that for any Fourier
2224
wavenumber they sum to one.
2325
"""

pysteps/cascade/decomposition.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
+-------------------+----------------------------------------------------------+
1313
| Key | Value |
1414
+===================+==========================================================+
15-
| cascade_levels | three-dimensional array of shape (n,L,L), where n is the |
16-
| | number of cascade levels and L is the size of the input |
17-
| | field |
15+
| cascade_levels | three-dimensional array of shape (k,m,n), where k is the |
16+
| | number of cascade levels and the input fields have shape |
17+
| | (m,n) |
1818
+-------------------+----------------------------------------------------------+
1919
| means | list of mean values for each cascade level |
2020
+-------------------+----------------------------------------------------------+

pysteps/nowcasts/steps.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ def forecast(R, V, n_timesteps, n_ens_members, n_cascade_levels,
225225
R_d.append(R_)
226226

227227
# normalize the cascades and rearrange them into a four-dimensional array
228-
# of shape (n_cascade_levels,ar_order+1,L,L) for the autoregressive model
228+
# of shape (n_cascade_levels,ar_order+1,m,n) for the autoregressive model
229229
R_c,mu,sigma = _stack_cascades(R_d, n_cascade_levels)
230230
R_d = None
231231

pysteps/optflow/darts.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ def DARTS(Z, **kwargs):
2828
Parameters
2929
----------
3030
Z : array-like
31-
Array of shape (T,L,L) containing a sequence of T two-dimensional input
32-
images of shape (L,L).
31+
Array of shape (T,m,n) containing a sequence of T two-dimensional input
32+
images of shape (m,n).
3333
3434
Other Parameters
3535
----------------
@@ -57,7 +57,7 @@ def DARTS(Z, **kwargs):
5757
Returns
5858
-------
5959
out : ndarray
60-
Three-dimensional array (2,L,L) containing the dense x- and y-components
60+
Three-dimensional array (2,H,W) containing the dense x- and y-components
6161
of the motion field.
6262
6363
References

0 commit comments

Comments
 (0)