codekingpro/portable-devtools
114k
1from typing import Any
2
3import numpy as np
4import numpy.typing as npt
5
6AR_f8: npt.NDArray[np.float64]
7AR_c16: npt.NDArray[np.complex128]
8AR_m: npt.NDArray[np.timedelta64]
9AR_M: npt.NDArray[np.datetime64]
10AR_O: npt.NDArray[np.object_]
11AR_b_list: list[npt.NDArray[np.bool]]
12
13def fn_none_i(a: None, /) -> npt.NDArray[Any]: ...
14def fn_ar_i(a: npt.NDArray[np.float64], posarg: int, /) -> npt.NDArray[Any]: ...
15
16np.average(AR_m) # type: ignore[type-var]
17np.select(1, [AR_f8]) # type: ignore[call-overload]
18np.angle(AR_m) # type: ignore[type-var]
19np.unwrap(AR_m) # type: ignore[type-var]
20np.unwrap(AR_c16) # type: ignore[type-var]
21np.trim_zeros(1) # type: ignore[arg-type]
22np.place(1, [True], 1.5) # type: ignore[arg-type]
23np.vectorize(1) # type: ignore[arg-type]
24np.place(AR_f8, slice(None), 5) # type: ignore[arg-type]
25
26np.piecewise(AR_f8, True, [fn_ar_i], "wrong") # type: ignore[call-overload]
27np.piecewise(AR_f8, AR_b_list, [fn_none_i]) # type: ignore[call-overload]
28np.piecewise(AR_f8, AR_b_list, [fn_ar_i]) # type: ignore[call-overload]
29np.piecewise(AR_f8, AR_b_list, [fn_ar_i], 3.14) # type: ignore[call-overload]
30np.piecewise(AR_f8, AR_b_list, [fn_ar_i], 42, None) # type: ignore[call-overload]
31np.piecewise(AR_f8, AR_b_list, [fn_ar_i], 42, _=None) # type: ignore[list-item]
32
33np.interp(AR_f8, AR_c16, AR_f8) # type: ignore[arg-type]
34np.interp(AR_c16, AR_f8, AR_f8) # type: ignore[arg-type]
35np.interp(AR_f8, AR_f8, AR_f8, period=AR_c16) # type: ignore[call-overload]
36np.interp(AR_f8, AR_f8, AR_O) # type: ignore[arg-type]
37
38np.cov(AR_m) # type: ignore[type-var]
39np.cov(AR_O) # type: ignore[type-var]
40np.corrcoef(AR_m) # type: ignore[type-var]
41np.corrcoef(AR_O) # type: ignore[type-var]
42np.corrcoef(AR_f8, bias=True) # type: ignore[call-overload]
43np.corrcoef(AR_f8, ddof=2) # type: ignore[call-overload]
44np.blackman(1j) # type: ignore[arg-type]
45np.bartlett(1j) # type: ignore[arg-type]
46np.hanning(1j) # type: ignore[arg-type]
47np.hamming(1j) # type: ignore[arg-type]
48np.hamming(AR_c16) # type: ignore[arg-type]
49np.kaiser(1j, 1) # type: ignore[arg-type]
50np.sinc(AR_O) # type: ignore[type-var]
51np.median(AR_M) # type: ignore[type-var]
52
53np.percentile(AR_f8, 50j) # type: ignore[call-overload]
54np.percentile(AR_f8, 50, interpolation="bob") # type: ignore[call-overload]
55np.quantile(AR_f8, 0.5j) # type: ignore[call-overload]
56np.quantile(AR_f8, 0.5, interpolation="bob") # type: ignore[call-overload]
57np.meshgrid(AR_f8, AR_f8, indexing="bob") # type: ignore[call-overload]
58np.delete(AR_f8, AR_f8) # type: ignore[arg-type]
59np.insert(AR_f8, AR_f8, 1.5) # type: ignore[arg-type]
60np.digitize(AR_f8, 1j) # type: ignore[call-overload]
61 