|
10 | 10 |
|
11 | 11 | from __future__ import annotations
|
12 | 12 |
|
| 13 | +from ._types import Literal, Optional, Tuple, Union, array |
| 14 | +from .constants import inf |
13 | 15 |
|
14 |
| -def cholesky(x, /, *, upper=False): |
| 16 | +def cholesky(x: array, /, *, upper: bool = False) -> array: |
15 | 17 | pass
|
16 | 18 |
|
17 |
| -def cross(x1, x2, /, *, axis=-1): |
| 19 | +def cross(x1: array, x2: array, /, *, axis: int = -1) -> array: |
18 | 20 | pass
|
19 | 21 |
|
20 |
| -def det(x, /): |
| 22 | +def det(x: array, /) -> array: |
21 | 23 | pass
|
22 | 24 |
|
23 |
| -def diagonal(x, /, *, axis1=0, axis2=1, offset=0): |
| 25 | +def diagonal(x: array, /, *, axis1: int = 0, axis2: int = 1, offset: int = 0) -> array: |
24 | 26 | pass
|
25 | 27 |
|
26 | 28 | def eig():
|
27 | 29 | pass
|
28 | 30 |
|
29 |
| -def eigh(x, /, *, upper=False): |
| 31 | +def eigh(x: array, /, *, upper: bool = False) -> Tuple[array]: |
30 | 32 | pass
|
31 | 33 |
|
32 | 34 | def eigvals():
|
33 | 35 | pass
|
34 | 36 |
|
35 |
| -def eigvalsh(x, /, *, upper=False): |
| 37 | +def eigvalsh(x: array, /, *, upper: bool = False) -> array: |
36 | 38 | pass
|
37 | 39 |
|
38 | 40 | def einsum():
|
39 | 41 | pass
|
40 | 42 |
|
41 |
| -def inv(x, /): |
| 43 | +def inv(x: array, /) -> array: |
42 | 44 | pass
|
43 | 45 |
|
44 |
| -def lstsq(x1, x2, /, *, rtol=None): |
| 46 | +def lstsq(x1: array, x2: array, /, *, rtol: Optional[Union[float, array]] = None) -> Tuple[array, array, array, array]: |
45 | 47 | pass
|
46 | 48 |
|
47 | 49 | def matmul(x1, x2, /):
|
48 | 50 | pass
|
49 | 51 |
|
50 |
| -def matrix_power(x, n, /): |
| 52 | +def matrix_power(x: array, n: int, /) -> array: |
51 | 53 | pass
|
52 | 54 |
|
53 |
| -def matrix_rank(x, /, *, rtol=None): |
| 55 | +def matrix_rank(x: array, /, *, rtol: Optional[Union[float, array]] = None) -> array: |
54 | 56 | pass
|
55 | 57 |
|
56 |
| -def norm(x, /, *, axis=None, keepdims=False, ord=None): |
| 58 | +def norm(x: array, /, *, axis: Optional[Union[int, Tuple[int, int]]] = None, keepdims: bool = False, ord: Optional[Union[int, float, Literal[inf, -inf, 'fro', 'nuc']]] = None) -> array: |
57 | 59 | pass
|
58 | 60 |
|
59 |
| -def outer(x1, x2, /): |
| 61 | +def outer(x1: array, x2: array, /) -> array: |
60 | 62 | pass
|
61 | 63 |
|
62 |
| -def pinv(x, /, *, rtol=None): |
| 64 | +def pinv(x: array, /, *, rtol: Optional[Union[float, array]] = None) -> array: |
63 | 65 | pass
|
64 | 66 |
|
65 |
| -def qr(x, /, *, mode='reduced'): |
| 67 | +def qr(x: array, /, *, mode: str = 'reduced') -> Tuple[array, array]: |
66 | 68 | pass
|
67 | 69 |
|
68 |
| -def slogdet(x, /): |
| 70 | +def slogdet(x: array, /) -> Tuple[array, array]: |
69 | 71 | pass
|
70 | 72 |
|
71 |
| -def solve(x1, x2, /): |
| 73 | +def solve(x1: array, x2: array, /) -> array: |
72 | 74 | pass
|
73 | 75 |
|
74 |
| -def svd(x, /, *, full_matrices=True): |
| 76 | +def svd(x: array, /, *, full_matrices: bool = True) -> Union[array, Tuple[array, ...]]: |
75 | 77 | pass
|
76 | 78 |
|
77 | 79 | def tensordot(x1, x2, /, *, axes=2):
|
78 | 80 | pass
|
79 | 81 |
|
80 |
| -def svdvals(x, /): |
| 82 | +def svdvals(x: array, /) -> Union[array, Tuple[array, ...]]: |
81 | 83 | pass
|
82 | 84 |
|
83 |
| -def trace(x, /, *, axis1=0, axis2=1, offset=0): |
| 85 | +def trace(x: array, /, *, axis1: int = 0, axis2: int = 1, offset: int = 0) -> array: |
84 | 86 | pass
|
85 | 87 |
|
86 | 88 | def transpose(x, /, *, axes=None):
|
|
0 commit comments