|
5 | 5 | from pydantic_numpy.helper.annotation import NpArrayPydanticAnnotation
|
6 | 6 |
|
7 | 7 | Np3DArray: TypeAlias = Annotated[
|
8 |
| - np.ndarray[tuple[int, int, int], np.dtype[Any]], |
| 8 | + np.ndarray[tuple[int, ...], np.dtype[Any]], |
9 | 9 | NpArrayPydanticAnnotation.factory(data_type=None, dimensions=3, strict_data_typing=False),
|
10 | 10 | ]
|
11 | 11 |
|
12 | 12 | Np3DArrayInt64: TypeAlias = Annotated[
|
13 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.int64]], |
| 13 | + np.ndarray[tuple[int, ...], np.dtype[np.int64]], |
14 | 14 | NpArrayPydanticAnnotation.factory(data_type=np.int64, dimensions=3, strict_data_typing=True),
|
15 | 15 | ]
|
16 | 16 |
|
17 | 17 | Np3DArrayInt32: TypeAlias = Annotated[
|
18 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.int32]], |
| 18 | + np.ndarray[tuple[int, ...], np.dtype[np.int32]], |
19 | 19 | NpArrayPydanticAnnotation.factory(data_type=np.int32, dimensions=3, strict_data_typing=True),
|
20 | 20 | ]
|
21 | 21 |
|
22 | 22 | Np3DArrayInt16: TypeAlias = Annotated[
|
23 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.int16]], |
| 23 | + np.ndarray[tuple[int, ...], np.dtype[np.int16]], |
24 | 24 | NpArrayPydanticAnnotation.factory(data_type=np.int16, dimensions=3, strict_data_typing=True),
|
25 | 25 | ]
|
26 | 26 |
|
27 | 27 | Np3DArrayInt8: TypeAlias = Annotated[
|
28 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.int8]], |
| 28 | + np.ndarray[tuple[int, ...], np.dtype[np.int8]], |
29 | 29 | NpArrayPydanticAnnotation.factory(data_type=np.int8, dimensions=3, strict_data_typing=True),
|
30 | 30 | ]
|
31 | 31 |
|
32 | 32 | Np3DArrayUint64: TypeAlias = Annotated[
|
33 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.uint64]], |
| 33 | + np.ndarray[tuple[int, ...], np.dtype[np.uint64]], |
34 | 34 | NpArrayPydanticAnnotation.factory(data_type=np.uint64, dimensions=3, strict_data_typing=True),
|
35 | 35 | ]
|
36 | 36 |
|
37 | 37 | Np3DArrayUint32: TypeAlias = Annotated[
|
38 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.uint32]], |
| 38 | + np.ndarray[tuple[int, ...], np.dtype[np.uint32]], |
39 | 39 | NpArrayPydanticAnnotation.factory(data_type=np.uint32, dimensions=3, strict_data_typing=True),
|
40 | 40 | ]
|
41 | 41 |
|
42 | 42 | Np3DArrayUint16: TypeAlias = Annotated[
|
43 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.uint16]], |
| 43 | + np.ndarray[tuple[int, ...], np.dtype[np.uint16]], |
44 | 44 | NpArrayPydanticAnnotation.factory(data_type=np.uint16, dimensions=3, strict_data_typing=True),
|
45 | 45 | ]
|
46 | 46 |
|
47 | 47 | Np3DArrayUint8: TypeAlias = Annotated[
|
48 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.uint8]], |
| 48 | + np.ndarray[tuple[int, ...], np.dtype[np.uint8]], |
49 | 49 | NpArrayPydanticAnnotation.factory(data_type=np.uint8, dimensions=3, strict_data_typing=True),
|
50 | 50 | ]
|
51 | 51 |
|
52 | 52 | Np3DArrayFpLongDouble: TypeAlias = Annotated[
|
53 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.longdouble]], |
| 53 | + np.ndarray[tuple[int, ...], np.dtype[np.longdouble]], |
54 | 54 | NpArrayPydanticAnnotation.factory(data_type=np.longdouble, dimensions=3, strict_data_typing=True),
|
55 | 55 | ]
|
56 | 56 |
|
57 | 57 | Np3DArrayFp64: TypeAlias = Annotated[
|
58 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.float64]], |
| 58 | + np.ndarray[tuple[int, ...], np.dtype[np.float64]], |
59 | 59 | NpArrayPydanticAnnotation.factory(data_type=np.float64, dimensions=3, strict_data_typing=True),
|
60 | 60 | ]
|
61 | 61 |
|
62 | 62 | Np3DArrayFp32: TypeAlias = Annotated[
|
63 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.float32]], |
| 63 | + np.ndarray[tuple[int, ...], np.dtype[np.float32]], |
64 | 64 | NpArrayPydanticAnnotation.factory(data_type=np.float32, dimensions=3, strict_data_typing=True),
|
65 | 65 | ]
|
66 | 66 |
|
67 | 67 | Np3DArrayFp16: TypeAlias = Annotated[
|
68 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.float16]], |
| 68 | + np.ndarray[tuple[int, ...], np.dtype[np.float16]], |
69 | 69 | NpArrayPydanticAnnotation.factory(data_type=np.float16, dimensions=3, strict_data_typing=True),
|
70 | 70 | ]
|
71 | 71 |
|
72 | 72 | Np3DArrayComplexLongDouble: TypeAlias = Annotated[
|
73 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.clongdouble]], |
| 73 | + np.ndarray[tuple[int, ...], np.dtype[np.clongdouble]], |
74 | 74 | NpArrayPydanticAnnotation.factory(data_type=np.clongdouble, dimensions=3, strict_data_typing=True),
|
75 | 75 | ]
|
76 | 76 |
|
77 | 77 | Np3DArrayComplex128: TypeAlias = Annotated[
|
78 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.complex128]], |
| 78 | + np.ndarray[tuple[int, ...], np.dtype[np.complex128]], |
79 | 79 | NpArrayPydanticAnnotation.factory(data_type=np.complex128, dimensions=3, strict_data_typing=True),
|
80 | 80 | ]
|
81 | 81 |
|
82 | 82 | Np3DArrayComplex64: TypeAlias = Annotated[
|
83 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.complex64]], |
| 83 | + np.ndarray[tuple[int, ...], np.dtype[np.complex64]], |
84 | 84 | NpArrayPydanticAnnotation.factory(data_type=np.complex64, dimensions=3, strict_data_typing=True),
|
85 | 85 | ]
|
86 | 86 |
|
87 | 87 | Np3DArrayBool: TypeAlias = Annotated[
|
88 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.bool_]], |
| 88 | + np.ndarray[tuple[int, ...], np.dtype[np.bool_]], |
89 | 89 | NpArrayPydanticAnnotation.factory(data_type=np.bool_, dimensions=3, strict_data_typing=True),
|
90 | 90 | ]
|
91 | 91 |
|
92 | 92 | Np3DArrayDatetime64: TypeAlias = Annotated[
|
93 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.datetime64]], |
| 93 | + np.ndarray[tuple[int, ...], np.dtype[np.datetime64]], |
94 | 94 | NpArrayPydanticAnnotation.factory(data_type=np.datetime64, dimensions=3, strict_data_typing=True),
|
95 | 95 | ]
|
96 | 96 |
|
97 | 97 | Np3DArrayTimedelta64: TypeAlias = Annotated[
|
98 |
| - np.ndarray[tuple[int, int, int], np.dtype[np.timedelta64]], |
| 98 | + np.ndarray[tuple[int, ...], np.dtype[np.timedelta64]], |
99 | 99 | NpArrayPydanticAnnotation.factory(data_type=np.timedelta64, dimensions=3, strict_data_typing=True),
|
100 | 100 | ]
|
101 | 101 |
|
|
0 commit comments