Skip to content

Commit 12d4bc3

Browse files
committed
fix doc string
1 parent f718f2b commit 12d4bc3

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

dpnp/dpnp_iface_linearalgebra.py

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -169,8 +169,7 @@ def dot(a, b, out=None):
169169

170170
def einsum(*operands, out=None, optimize=False, **kwargs):
171171
"""
172-
einsum(subscripts, *operands, out=None, dtype=None, order="K",
173-
casting="safe", optimize=False)
172+
einsum(subscripts, *operands, out=None, dtype=None, order="K", casting="safe", optimize=False)
174173
175174
Evaluates the Einstein summation convention on the operands.
176175
@@ -199,10 +198,10 @@ def einsum(*operands, out=None, optimize=False, **kwargs):
199198
Default is ``"K"``.
200199
casting : {"no", "equiv", "safe", "same_kind", "unsafe"}, optional
201200
Controls what kind of data casting may occur. Setting this to
202-
"unsafe" is not recommended, as it can adversely affect accumulations.
201+
`"unsafe"` is not recommended, as it can adversely affect accumulations.
203202
204-
* "no" means the data types should not be cast at all.
205-
* "equiv" means only byte-order changes are allowed.
203+
* ``"no"`` means the data types should not be cast at all.
204+
* 'equiv' means only byte-order changes are allowed.
206205
* "safe" means only casts which can preserve values are allowed.
207206
* "same_kind" means only safe casts or casts within a kind,
208207
like float64 to float32, are allowed.
@@ -382,9 +381,9 @@ def einsum(*operands, out=None, optimize=False, **kwargs):
382381
larger arrays:
383382
384383
>>> a = np.ones(64000).reshape(20, 40, 80)
385-
386-
(benchmarked on 12th Gen Intel(R) Core(TM) i7-1265U.)
387-
Basic `einsum`: 146 ms ± 23.5 ms per loop
384+
385+
Basic `einsum`: 146 ms ± 23.5 ms per loop (benchmarked on 12th
386+
Gen Intel® Core™ i7-1265U)
388387
389388
>>> %timeit -r 10 -n 50 np.einsum("ijk,ilm,njm,nlk,abc->",a,a,a,a,a)
390389

0 commit comments

Comments
 (0)