Skip to content

Commit bfec575

Browse files
Docstring of expand_dims to reflect that axis can be a tuple
1 parent 13f4443 commit bfec575

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

dpctl/tensor/_manipulation_functions.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,10 @@ def expand_dims(X, axis):
127127
of size one at the position specified by axis.
128128
129129
Args:
130-
x (usm_ndarray): input array
131-
axis (int): axis position (zero-based). If `x` has rank
130+
x (usm_ndarray):
131+
input array
132+
axis (Union[int, Tuple[int]]):
133+
axis position in the expanded axes (zero-based). If `x` has rank
132134
(i.e, number of dimensions) `N`, a valid `axis` must reside
133135
in the closed-interval `[-N-1, N]`. If provided a negative
134136
`axis`, the `axis` position at which to insert a singleton

0 commit comments

Comments
 (0)