opencv-python 5.1.0.95__cp37-abi3-win_arm64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- cv2/Error/__init__.pyi +118 -0
- cv2/LICENSE-3RD-PARTY.txt +3645 -0
- cv2/LICENSE.txt +21 -0
- cv2/__init__.py +189 -0
- cv2/__init__.pyi +7168 -0
- cv2/aruco/__init__.pyi +331 -0
- cv2/barcode/__init__.pyi +40 -0
- cv2/ccm/__init__.pyi +165 -0
- cv2/config-3.py +24 -0
- cv2/config.py +5 -0
- cv2/cuda/__init__.pyi +513 -0
- cv2/cv2.pyd +4 -0
- cv2/data/__init__.py +3 -0
- cv2/detail/__init__.pyi +543 -0
- cv2/dnn/__init__.pyi +690 -0
- cv2/fisheye/__init__.pyi +88 -0
- cv2/flann/__init__.pyi +65 -0
- cv2/instr/__init__.pyi +24 -0
- cv2/ipp/__init__.pyi +14 -0
- cv2/load_config_py2.py +6 -0
- cv2/load_config_py3.py +9 -0
- cv2/mat_wrapper/__init__.py +40 -0
- cv2/mcc/__init__.pyi +118 -0
- cv2/misc/__init__.py +1 -0
- cv2/misc/version.py +5 -0
- cv2/ocl/__init__.pyi +252 -0
- cv2/ogl/__init__.pyi +119 -0
- cv2/parallel/__init__.pyi +6 -0
- cv2/py.typed +0 -0
- cv2/samples/__init__.pyi +12 -0
- cv2/segmentation/__init__.pyi +39 -0
- cv2/slam/__init__.pyi +80 -0
- cv2/typing/__init__.py +159 -0
- cv2/utils/__init__.py +14 -0
- cv2/utils/__init__.pyi +110 -0
- cv2/utils/fs/__init__.pyi +6 -0
- cv2/utils/logging/__init__.pyi +22 -0
- cv2/utils/nested/__init__.pyi +31 -0
- cv2/version.py +5 -0
- cv2/videoio_registry/__init__.pyi +34 -0
- cv2/viz3d/__init__.pyi +63 -0
- opencv_python-5.1.0.95.dist-info/LICENSE-3RD-PARTY.txt +3645 -0
- opencv_python-5.1.0.95.dist-info/LICENSE.txt +21 -0
- opencv_python-5.1.0.95.dist-info/METADATA +333 -0
- opencv_python-5.1.0.95.dist-info/RECORD +47 -0
- opencv_python-5.1.0.95.dist-info/WHEEL +5 -0
- opencv_python-5.1.0.95.dist-info/top_level.txt +1 -0
cv2/aruco/__init__.pyi
ADDED
|
@@ -0,0 +1,331 @@
|
|
|
1
|
+
__all__: list[str] = []
|
|
2
|
+
|
|
3
|
+
import cv2
|
|
4
|
+
import cv2.typing
|
|
5
|
+
import typing as _typing
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# Enumerations
|
|
9
|
+
CORNER_REFINE_NONE: int
|
|
10
|
+
CORNER_REFINE_SUBPIX: int
|
|
11
|
+
CORNER_REFINE_CONTOUR: int
|
|
12
|
+
CORNER_REFINE_APRILTAG: int
|
|
13
|
+
CornerRefineMethod = int
|
|
14
|
+
"""One of [CORNER_REFINE_NONE, CORNER_REFINE_SUBPIX, CORNER_REFINE_CONTOUR, CORNER_REFINE_APRILTAG]"""
|
|
15
|
+
|
|
16
|
+
DICT_4X4_50: int
|
|
17
|
+
DICT_4X4_100: int
|
|
18
|
+
DICT_4X4_250: int
|
|
19
|
+
DICT_4X4_1000: int
|
|
20
|
+
DICT_5X5_50: int
|
|
21
|
+
DICT_5X5_100: int
|
|
22
|
+
DICT_5X5_250: int
|
|
23
|
+
DICT_5X5_1000: int
|
|
24
|
+
DICT_6X6_50: int
|
|
25
|
+
DICT_6X6_100: int
|
|
26
|
+
DICT_6X6_250: int
|
|
27
|
+
DICT_6X6_1000: int
|
|
28
|
+
DICT_7X7_50: int
|
|
29
|
+
DICT_7X7_100: int
|
|
30
|
+
DICT_7X7_250: int
|
|
31
|
+
DICT_7X7_1000: int
|
|
32
|
+
DICT_ARUCO_ORIGINAL: int
|
|
33
|
+
DICT_APRILTAG_16h5: int
|
|
34
|
+
DICT_APRILTAG_16H5: int
|
|
35
|
+
DICT_APRILTAG_25h9: int
|
|
36
|
+
DICT_APRILTAG_25H9: int
|
|
37
|
+
DICT_APRILTAG_36h10: int
|
|
38
|
+
DICT_APRILTAG_36H10: int
|
|
39
|
+
DICT_APRILTAG_36h11: int
|
|
40
|
+
DICT_APRILTAG_36H11: int
|
|
41
|
+
DICT_ARUCO_MIP_36h12: int
|
|
42
|
+
DICT_ARUCO_MIP_36H12: int
|
|
43
|
+
PredefinedDictionaryType = int
|
|
44
|
+
"""One of [DICT_4X4_50, DICT_4X4_100, DICT_4X4_250, DICT_4X4_1000, DICT_5X5_50, DICT_5X5_100, DICT_5X5_250, DICT_5X5_1000, DICT_6X6_50, DICT_6X6_100, DICT_6X6_250, DICT_6X6_1000, DICT_7X7_50, DICT_7X7_100, DICT_7X7_250, DICT_7X7_1000, DICT_ARUCO_ORIGINAL, DICT_APRILTAG_16h5, DICT_APRILTAG_16H5, DICT_APRILTAG_25h9, DICT_APRILTAG_25H9, DICT_APRILTAG_36h10, DICT_APRILTAG_36H10, DICT_APRILTAG_36h11, DICT_APRILTAG_36H11, DICT_ARUCO_MIP_36h12, DICT_ARUCO_MIP_36H12]"""
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
# Classes
|
|
49
|
+
class Board:
|
|
50
|
+
# Functions
|
|
51
|
+
@_typing.overload
|
|
52
|
+
def __init__(self, objPoints: _typing.Sequence[cv2.typing.MatLike], dictionary: Dictionary, ids: cv2.typing.MatLike) -> None: ...
|
|
53
|
+
@_typing.overload
|
|
54
|
+
def __init__(self, objPoints: _typing.Sequence[cv2.UMat], dictionary: Dictionary, ids: cv2.UMat) -> None: ...
|
|
55
|
+
|
|
56
|
+
def getDictionary(self) -> Dictionary: ...
|
|
57
|
+
|
|
58
|
+
def getObjPoints(self) -> _typing.Sequence[_typing.Sequence[cv2.typing.Point3f]]: ...
|
|
59
|
+
|
|
60
|
+
def getIds(self) -> _typing.Sequence[int]: ...
|
|
61
|
+
|
|
62
|
+
def getRightBottomCorner(self) -> cv2.typing.Point3f: ...
|
|
63
|
+
|
|
64
|
+
@_typing.overload
|
|
65
|
+
def matchImagePoints(self, detectedCorners: _typing.Sequence[cv2.typing.MatLike], detectedIds: cv2.typing.MatLike, objPoints: cv2.typing.MatLike | None = ..., imgPoints: cv2.typing.MatLike | None = ...) -> tuple[cv2.typing.MatLike, cv2.typing.MatLike]: ...
|
|
66
|
+
@_typing.overload
|
|
67
|
+
def matchImagePoints(self, detectedCorners: _typing.Sequence[cv2.UMat], detectedIds: cv2.UMat, objPoints: cv2.UMat | None = ..., imgPoints: cv2.UMat | None = ...) -> tuple[cv2.UMat, cv2.UMat]: ...
|
|
68
|
+
|
|
69
|
+
@_typing.overload
|
|
70
|
+
def generateImage(self, outSize: cv2.typing.Size, img: cv2.typing.MatLike | None = ..., marginSize: int = ..., borderBits: int = ...) -> cv2.typing.MatLike: ...
|
|
71
|
+
@_typing.overload
|
|
72
|
+
def generateImage(self, outSize: cv2.typing.Size, img: cv2.UMat | None = ..., marginSize: int = ..., borderBits: int = ...) -> cv2.UMat: ...
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
class GridBoard(Board):
|
|
76
|
+
# Functions
|
|
77
|
+
@_typing.overload
|
|
78
|
+
def __init__(self, size: cv2.typing.Size, markerLength: float, markerSeparation: float, dictionary: Dictionary, ids: cv2.typing.MatLike | None = ...) -> None: ...
|
|
79
|
+
@_typing.overload
|
|
80
|
+
def __init__(self, size: cv2.typing.Size, markerLength: float, markerSeparation: float, dictionary: Dictionary, ids: cv2.UMat | None = ...) -> None: ...
|
|
81
|
+
|
|
82
|
+
def getGridSize(self) -> cv2.typing.Size: ...
|
|
83
|
+
|
|
84
|
+
def getMarkerLength(self) -> float: ...
|
|
85
|
+
|
|
86
|
+
def getMarkerSeparation(self) -> float: ...
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
class CharucoBoard(Board):
|
|
90
|
+
# Functions
|
|
91
|
+
@_typing.overload
|
|
92
|
+
def __init__(self, size: cv2.typing.Size, squareLength: float, markerLength: float, dictionary: Dictionary, ids: cv2.typing.MatLike | None = ...) -> None: ...
|
|
93
|
+
@_typing.overload
|
|
94
|
+
def __init__(self, size: cv2.typing.Size, squareLength: float, markerLength: float, dictionary: Dictionary, ids: cv2.UMat | None = ...) -> None: ...
|
|
95
|
+
|
|
96
|
+
def setLegacyPattern(self, legacyPattern: bool) -> None: ...
|
|
97
|
+
|
|
98
|
+
def getLegacyPattern(self) -> bool: ...
|
|
99
|
+
|
|
100
|
+
def getChessboardSize(self) -> cv2.typing.Size: ...
|
|
101
|
+
|
|
102
|
+
def getSquareLength(self) -> float: ...
|
|
103
|
+
|
|
104
|
+
def getMarkerLength(self) -> float: ...
|
|
105
|
+
|
|
106
|
+
def getChessboardCorners(self) -> _typing.Sequence[cv2.typing.Point3f]: ...
|
|
107
|
+
|
|
108
|
+
@_typing.overload
|
|
109
|
+
def checkCharucoCornersCollinear(self, charucoIds: cv2.typing.MatLike) -> bool: ...
|
|
110
|
+
@_typing.overload
|
|
111
|
+
def checkCharucoCornersCollinear(self, charucoIds: cv2.UMat) -> bool: ...
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
class DetectorParameters:
|
|
115
|
+
adaptiveThreshWinSizeMin: int
|
|
116
|
+
adaptiveThreshWinSizeMax: int
|
|
117
|
+
adaptiveThreshWinSizeStep: int
|
|
118
|
+
adaptiveThreshConstant: float
|
|
119
|
+
minMarkerPerimeterRate: float
|
|
120
|
+
maxMarkerPerimeterRate: float
|
|
121
|
+
polygonalApproxAccuracyRate: float
|
|
122
|
+
minCornerDistanceRate: float
|
|
123
|
+
minDistanceToBorder: int
|
|
124
|
+
minMarkerDistanceRate: float
|
|
125
|
+
minGroupDistance: float
|
|
126
|
+
cornerRefinementMethod: int
|
|
127
|
+
cornerRefinementWinSize: int
|
|
128
|
+
relativeCornerRefinmentWinSize: float
|
|
129
|
+
cornerRefinementMaxIterations: int
|
|
130
|
+
cornerRefinementMinAccuracy: float
|
|
131
|
+
markerBorderBits: int
|
|
132
|
+
perspectiveRemovePixelPerCell: int
|
|
133
|
+
perspectiveRemoveIgnoredMarginPerCell: float
|
|
134
|
+
maxErroneousBitsInBorderRate: float
|
|
135
|
+
minOtsuStdDev: float
|
|
136
|
+
errorCorrectionRate: float
|
|
137
|
+
aprilTagQuadDecimate: float
|
|
138
|
+
aprilTagQuadSigma: float
|
|
139
|
+
aprilTagMinClusterPixels: int
|
|
140
|
+
aprilTagMaxNmaxima: int
|
|
141
|
+
aprilTagCriticalRad: float
|
|
142
|
+
aprilTagMaxLineFitMse: float
|
|
143
|
+
aprilTagMinWhiteBlackDiff: int
|
|
144
|
+
aprilTagDeglitch: int
|
|
145
|
+
detectInvertedMarker: bool
|
|
146
|
+
useAruco3Detection: bool
|
|
147
|
+
minSideLengthCanonicalImg: int
|
|
148
|
+
minMarkerLengthRatioOriginalImg: float
|
|
149
|
+
validBitIdThreshold: float
|
|
150
|
+
|
|
151
|
+
# Functions
|
|
152
|
+
def __init__(self) -> None: ...
|
|
153
|
+
|
|
154
|
+
def readDetectorParameters(self, fn: cv2.FileNode) -> bool: ...
|
|
155
|
+
|
|
156
|
+
def writeDetectorParameters(self, fs: cv2.FileStorage, name: str = ...) -> bool: ...
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
class RefineParameters:
|
|
160
|
+
minRepDistance: float
|
|
161
|
+
errorCorrectionRate: float
|
|
162
|
+
checkAllOrders: bool
|
|
163
|
+
|
|
164
|
+
# Functions
|
|
165
|
+
def __init__(self, minRepDistance: float = ..., errorCorrectionRate: float = ..., checkAllOrders: bool = ...) -> None: ...
|
|
166
|
+
|
|
167
|
+
def readRefineParameters(self, fn: cv2.FileNode) -> bool: ...
|
|
168
|
+
|
|
169
|
+
def writeRefineParameters(self, fs: cv2.FileStorage, name: str = ...) -> bool: ...
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
class ArucoDetector(cv2.Algorithm):
|
|
173
|
+
# Functions
|
|
174
|
+
@_typing.overload
|
|
175
|
+
def __init__(self, dictionary: Dictionary = ..., detectorParams: DetectorParameters = ..., refineParams: RefineParameters = ...) -> None: ...
|
|
176
|
+
@_typing.overload
|
|
177
|
+
def __init__(self, dictionaries: _typing.Sequence[Dictionary], detectorParams: DetectorParameters = ..., refineParams: RefineParameters = ...) -> None: ...
|
|
178
|
+
|
|
179
|
+
@_typing.overload
|
|
180
|
+
def detectMarkers(self, image: cv2.typing.MatLike, corners: _typing.Sequence[cv2.typing.MatLike] | None = ..., ids: cv2.typing.MatLike | None = ..., rejectedImgPoints: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> tuple[_typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike, _typing.Sequence[cv2.typing.MatLike]]: ...
|
|
181
|
+
@_typing.overload
|
|
182
|
+
def detectMarkers(self, image: cv2.UMat, corners: _typing.Sequence[cv2.UMat] | None = ..., ids: cv2.UMat | None = ..., rejectedImgPoints: _typing.Sequence[cv2.UMat] | None = ...) -> tuple[_typing.Sequence[cv2.UMat], cv2.UMat, _typing.Sequence[cv2.UMat]]: ...
|
|
183
|
+
|
|
184
|
+
@_typing.overload
|
|
185
|
+
def detectMarkersWithConfidence(self, image: cv2.typing.MatLike, corners: _typing.Sequence[cv2.typing.MatLike] | None = ..., ids: cv2.typing.MatLike | None = ..., markersConfidence: cv2.typing.MatLike | None = ..., rejectedImgPoints: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> tuple[_typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike, cv2.typing.MatLike, _typing.Sequence[cv2.typing.MatLike]]: ...
|
|
186
|
+
@_typing.overload
|
|
187
|
+
def detectMarkersWithConfidence(self, image: cv2.UMat, corners: _typing.Sequence[cv2.UMat] | None = ..., ids: cv2.UMat | None = ..., markersConfidence: cv2.UMat | None = ..., rejectedImgPoints: _typing.Sequence[cv2.UMat] | None = ...) -> tuple[_typing.Sequence[cv2.UMat], cv2.UMat, cv2.UMat, _typing.Sequence[cv2.UMat]]: ...
|
|
188
|
+
|
|
189
|
+
@_typing.overload
|
|
190
|
+
def refineDetectedMarkers(self, image: cv2.typing.MatLike, board: Board, detectedCorners: _typing.Sequence[cv2.typing.MatLike], detectedIds: cv2.typing.MatLike, rejectedCorners: _typing.Sequence[cv2.typing.MatLike], cameraMatrix: cv2.typing.MatLike | None = ..., distCoeffs: cv2.typing.MatLike | None = ..., recoveredIdxs: cv2.typing.MatLike | None = ...) -> tuple[_typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike, _typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike]: ...
|
|
191
|
+
@_typing.overload
|
|
192
|
+
def refineDetectedMarkers(self, image: cv2.UMat, board: Board, detectedCorners: _typing.Sequence[cv2.UMat], detectedIds: cv2.UMat, rejectedCorners: _typing.Sequence[cv2.UMat], cameraMatrix: cv2.UMat | None = ..., distCoeffs: cv2.UMat | None = ..., recoveredIdxs: cv2.UMat | None = ...) -> tuple[_typing.Sequence[cv2.UMat], cv2.UMat, _typing.Sequence[cv2.UMat], cv2.UMat]: ...
|
|
193
|
+
|
|
194
|
+
@_typing.overload
|
|
195
|
+
def detectMarkersMultiDict(self, image: cv2.typing.MatLike, corners: _typing.Sequence[cv2.typing.MatLike] | None = ..., ids: cv2.typing.MatLike | None = ..., rejectedImgPoints: _typing.Sequence[cv2.typing.MatLike] | None = ..., dictIndices: cv2.typing.MatLike | None = ...) -> tuple[_typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike, _typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike]: ...
|
|
196
|
+
@_typing.overload
|
|
197
|
+
def detectMarkersMultiDict(self, image: cv2.UMat, corners: _typing.Sequence[cv2.UMat] | None = ..., ids: cv2.UMat | None = ..., rejectedImgPoints: _typing.Sequence[cv2.UMat] | None = ..., dictIndices: cv2.UMat | None = ...) -> tuple[_typing.Sequence[cv2.UMat], cv2.UMat, _typing.Sequence[cv2.UMat], cv2.UMat]: ...
|
|
198
|
+
|
|
199
|
+
def getDictionary(self) -> Dictionary: ...
|
|
200
|
+
|
|
201
|
+
def setDictionary(self, dictionary: Dictionary) -> None: ...
|
|
202
|
+
|
|
203
|
+
def getDictionaries(self) -> _typing.Sequence[Dictionary]: ...
|
|
204
|
+
|
|
205
|
+
def setDictionaries(self, dictionaries: _typing.Sequence[Dictionary]) -> None: ...
|
|
206
|
+
|
|
207
|
+
def getDetectorParameters(self) -> DetectorParameters: ...
|
|
208
|
+
|
|
209
|
+
def setDetectorParameters(self, detectorParameters: DetectorParameters) -> None: ...
|
|
210
|
+
|
|
211
|
+
def getRefineParameters(self) -> RefineParameters: ...
|
|
212
|
+
|
|
213
|
+
def setRefineParameters(self, refineParameters: RefineParameters) -> None: ...
|
|
214
|
+
|
|
215
|
+
def write(self, fs: cv2.FileStorage, name: str) -> None: ...
|
|
216
|
+
|
|
217
|
+
def read(self, fn: cv2.FileNode) -> None: ...
|
|
218
|
+
|
|
219
|
+
|
|
220
|
+
class Dictionary:
|
|
221
|
+
bytesList: cv2.typing.MatLike
|
|
222
|
+
markerSize: int
|
|
223
|
+
maxCorrectionBits: int
|
|
224
|
+
|
|
225
|
+
# Functions
|
|
226
|
+
@_typing.overload
|
|
227
|
+
def __init__(self) -> None: ...
|
|
228
|
+
@_typing.overload
|
|
229
|
+
def __init__(self, bytesList: cv2.typing.MatLike, _markerSize: int, maxcorr: int = ...) -> None: ...
|
|
230
|
+
|
|
231
|
+
def readDictionary(self, fn: cv2.FileNode) -> bool: ...
|
|
232
|
+
|
|
233
|
+
def writeDictionary(self, fs: cv2.FileStorage, name: str = ...) -> None: ...
|
|
234
|
+
|
|
235
|
+
@_typing.overload
|
|
236
|
+
def identify(self, onlyBits: cv2.typing.MatLike, maxCorrectionRate: float) -> tuple[bool, int, int]: ...
|
|
237
|
+
@_typing.overload
|
|
238
|
+
def identify(self, onlyCellPixelRatio: cv2.typing.MatLike, maxCorrectionRate: float, validBitIdThreshold: float) -> tuple[bool, int, int]: ...
|
|
239
|
+
|
|
240
|
+
@_typing.overload
|
|
241
|
+
def getDistanceToId(self, bits: cv2.typing.MatLike, id: int, allRotations: bool = ...) -> int: ...
|
|
242
|
+
@_typing.overload
|
|
243
|
+
def getDistanceToId(self, bits: cv2.UMat, id: int, allRotations: bool = ...) -> int: ...
|
|
244
|
+
@_typing.overload
|
|
245
|
+
def getDistanceToId(self, onlyCellPixelRatio: cv2.typing.MatLike, id: int, allRotations: bool, validBitIdThreshold: float) -> int: ...
|
|
246
|
+
@_typing.overload
|
|
247
|
+
def getDistanceToId(self, onlyCellPixelRatio: cv2.UMat, id: int, allRotations: bool, validBitIdThreshold: float) -> int: ...
|
|
248
|
+
|
|
249
|
+
@_typing.overload
|
|
250
|
+
def generateImageMarker(self, id: int, sidePixels: int, _img: cv2.typing.MatLike | None = ..., borderBits: int = ...) -> cv2.typing.MatLike: ...
|
|
251
|
+
@_typing.overload
|
|
252
|
+
def generateImageMarker(self, id: int, sidePixels: int, _img: cv2.UMat | None = ..., borderBits: int = ...) -> cv2.UMat: ...
|
|
253
|
+
|
|
254
|
+
@staticmethod
|
|
255
|
+
def getByteListFromBits(bits: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
|
|
256
|
+
|
|
257
|
+
@staticmethod
|
|
258
|
+
def getBitsFromByteList(byteList: cv2.typing.MatLike, markerSize: int, rotationId: int = ...) -> cv2.typing.MatLike: ...
|
|
259
|
+
|
|
260
|
+
def getMarkerBits(self, markerId: int, rotationId: int = ...) -> cv2.typing.MatLike: ...
|
|
261
|
+
|
|
262
|
+
|
|
263
|
+
class CharucoParameters:
|
|
264
|
+
cameraMatrix: cv2.typing.MatLike
|
|
265
|
+
distCoeffs: cv2.typing.MatLike
|
|
266
|
+
minMarkers: int
|
|
267
|
+
tryRefineMarkers: bool
|
|
268
|
+
checkMarkers: bool
|
|
269
|
+
|
|
270
|
+
# Functions
|
|
271
|
+
def __init__(self) -> None: ...
|
|
272
|
+
|
|
273
|
+
|
|
274
|
+
class CharucoDetector(cv2.Algorithm):
|
|
275
|
+
# Functions
|
|
276
|
+
def __init__(self, board: CharucoBoard, charucoParams: CharucoParameters = ..., detectorParams: DetectorParameters = ..., refineParams: RefineParameters = ...) -> None: ...
|
|
277
|
+
|
|
278
|
+
def getBoard(self) -> CharucoBoard: ...
|
|
279
|
+
|
|
280
|
+
def setBoard(self, board: CharucoBoard) -> None: ...
|
|
281
|
+
|
|
282
|
+
def getCharucoParameters(self) -> CharucoParameters: ...
|
|
283
|
+
|
|
284
|
+
def setCharucoParameters(self, charucoParameters: CharucoParameters) -> None: ...
|
|
285
|
+
|
|
286
|
+
def getDetectorParameters(self) -> DetectorParameters: ...
|
|
287
|
+
|
|
288
|
+
def setDetectorParameters(self, detectorParameters: DetectorParameters) -> None: ...
|
|
289
|
+
|
|
290
|
+
def getRefineParameters(self) -> RefineParameters: ...
|
|
291
|
+
|
|
292
|
+
def setRefineParameters(self, refineParameters: RefineParameters) -> None: ...
|
|
293
|
+
|
|
294
|
+
@_typing.overload
|
|
295
|
+
def detectBoard(self, image: cv2.typing.MatLike, charucoCorners: cv2.typing.MatLike | None = ..., charucoIds: cv2.typing.MatLike | None = ..., markerCorners: _typing.Sequence[cv2.typing.MatLike] | None = ..., markerIds: cv2.typing.MatLike | None = ...) -> tuple[cv2.typing.MatLike, cv2.typing.MatLike, _typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike]: ...
|
|
296
|
+
@_typing.overload
|
|
297
|
+
def detectBoard(self, image: cv2.UMat, charucoCorners: cv2.UMat | None = ..., charucoIds: cv2.UMat | None = ..., markerCorners: _typing.Sequence[cv2.UMat] | None = ..., markerIds: cv2.UMat | None = ...) -> tuple[cv2.UMat, cv2.UMat, _typing.Sequence[cv2.UMat], cv2.UMat]: ...
|
|
298
|
+
|
|
299
|
+
@_typing.overload
|
|
300
|
+
def detectDiamonds(self, image: cv2.typing.MatLike, diamondCorners: _typing.Sequence[cv2.typing.MatLike] | None = ..., diamondIds: cv2.typing.MatLike | None = ..., markerCorners: _typing.Sequence[cv2.typing.MatLike] | None = ..., markerIds: cv2.typing.MatLike | None = ...) -> tuple[_typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike, _typing.Sequence[cv2.typing.MatLike], cv2.typing.MatLike]: ...
|
|
301
|
+
@_typing.overload
|
|
302
|
+
def detectDiamonds(self, image: cv2.UMat, diamondCorners: _typing.Sequence[cv2.UMat] | None = ..., diamondIds: cv2.UMat | None = ..., markerCorners: _typing.Sequence[cv2.UMat] | None = ..., markerIds: cv2.UMat | None = ...) -> tuple[_typing.Sequence[cv2.UMat], cv2.UMat, _typing.Sequence[cv2.UMat], cv2.UMat]: ...
|
|
303
|
+
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
# Functions
|
|
307
|
+
@_typing.overload
|
|
308
|
+
def drawDetectedCornersCharuco(image: cv2.typing.MatLike, charucoCorners: cv2.typing.MatLike, charucoIds: cv2.typing.MatLike | None = ..., cornerColor: cv2.typing.Scalar = ...) -> cv2.typing.MatLike: ...
|
|
309
|
+
@_typing.overload
|
|
310
|
+
def drawDetectedCornersCharuco(image: cv2.UMat, charucoCorners: cv2.UMat, charucoIds: cv2.UMat | None = ..., cornerColor: cv2.typing.Scalar = ...) -> cv2.UMat: ...
|
|
311
|
+
|
|
312
|
+
@_typing.overload
|
|
313
|
+
def drawDetectedDiamonds(image: cv2.typing.MatLike, diamondCorners: _typing.Sequence[cv2.typing.MatLike], diamondIds: cv2.typing.MatLike | None = ..., borderColor: cv2.typing.Scalar = ...) -> cv2.typing.MatLike: ...
|
|
314
|
+
@_typing.overload
|
|
315
|
+
def drawDetectedDiamonds(image: cv2.UMat, diamondCorners: _typing.Sequence[cv2.UMat], diamondIds: cv2.UMat | None = ..., borderColor: cv2.typing.Scalar = ...) -> cv2.UMat: ...
|
|
316
|
+
|
|
317
|
+
@_typing.overload
|
|
318
|
+
def drawDetectedMarkers(image: cv2.typing.MatLike, corners: _typing.Sequence[cv2.typing.MatLike], ids: cv2.typing.MatLike | None = ..., borderColor: cv2.typing.Scalar = ...) -> cv2.typing.MatLike: ...
|
|
319
|
+
@_typing.overload
|
|
320
|
+
def drawDetectedMarkers(image: cv2.UMat, corners: _typing.Sequence[cv2.UMat], ids: cv2.UMat | None = ..., borderColor: cv2.typing.Scalar = ...) -> cv2.UMat: ...
|
|
321
|
+
|
|
322
|
+
def extendDictionary(nMarkers: int, markerSize: int, baseDictionary: Dictionary = ..., randomSeed: int = ...) -> Dictionary: ...
|
|
323
|
+
|
|
324
|
+
@_typing.overload
|
|
325
|
+
def generateImageMarker(dictionary: Dictionary, id: int, sidePixels: int, img: cv2.typing.MatLike | None = ..., borderBits: int = ...) -> cv2.typing.MatLike: ...
|
|
326
|
+
@_typing.overload
|
|
327
|
+
def generateImageMarker(dictionary: Dictionary, id: int, sidePixels: int, img: cv2.UMat | None = ..., borderBits: int = ...) -> cv2.UMat: ...
|
|
328
|
+
|
|
329
|
+
def getPredefinedDictionary(dict: int) -> Dictionary: ...
|
|
330
|
+
|
|
331
|
+
|
cv2/barcode/__init__.pyi
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
__all__: list[str] = []
|
|
2
|
+
|
|
3
|
+
import cv2
|
|
4
|
+
import cv2.typing
|
|
5
|
+
import os
|
|
6
|
+
import typing as _typing
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
# Classes
|
|
10
|
+
class BarcodeDetector(cv2.GraphicalCodeDetector):
|
|
11
|
+
# Functions
|
|
12
|
+
@_typing.overload
|
|
13
|
+
def __init__(self) -> None: ...
|
|
14
|
+
@_typing.overload
|
|
15
|
+
def __init__(self, super_resolution_model_path: str | os.PathLike[str]) -> None: ...
|
|
16
|
+
|
|
17
|
+
@_typing.overload
|
|
18
|
+
def decodeWithType(self, img: cv2.typing.MatLike, points: cv2.typing.MatLike) -> tuple[bool, _typing.Sequence[str], _typing.Sequence[str]]: ...
|
|
19
|
+
@_typing.overload
|
|
20
|
+
def decodeWithType(self, img: cv2.UMat, points: cv2.UMat) -> tuple[bool, _typing.Sequence[str], _typing.Sequence[str]]: ...
|
|
21
|
+
|
|
22
|
+
@_typing.overload
|
|
23
|
+
def detectAndDecodeWithType(self, img: cv2.typing.MatLike, points: cv2.typing.MatLike | None = ...) -> tuple[bool, _typing.Sequence[str], _typing.Sequence[str], cv2.typing.MatLike]: ...
|
|
24
|
+
@_typing.overload
|
|
25
|
+
def detectAndDecodeWithType(self, img: cv2.UMat, points: cv2.UMat | None = ...) -> tuple[bool, _typing.Sequence[str], _typing.Sequence[str], cv2.UMat]: ...
|
|
26
|
+
|
|
27
|
+
def getDownsamplingThreshold(self) -> float: ...
|
|
28
|
+
|
|
29
|
+
def setDownsamplingThreshold(self, thresh: float) -> BarcodeDetector: ...
|
|
30
|
+
|
|
31
|
+
def getDetectorScales(self) -> _typing.Sequence[float]: ...
|
|
32
|
+
|
|
33
|
+
def setDetectorScales(self, sizes: _typing.Sequence[float]) -> BarcodeDetector: ...
|
|
34
|
+
|
|
35
|
+
def getGradientThreshold(self) -> float: ...
|
|
36
|
+
|
|
37
|
+
def setGradientThreshold(self, thresh: float) -> BarcodeDetector: ...
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
|
cv2/ccm/__init__.pyi
ADDED
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
__all__: list[str] = []
|
|
2
|
+
|
|
3
|
+
import cv2
|
|
4
|
+
import cv2.typing
|
|
5
|
+
import typing as _typing
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# Enumerations
|
|
9
|
+
CCM_LINEAR: int
|
|
10
|
+
CCM_AFFINE: int
|
|
11
|
+
CcmType = int
|
|
12
|
+
"""One of [CCM_LINEAR, CCM_AFFINE]"""
|
|
13
|
+
|
|
14
|
+
INITIAL_METHOD_WHITE_BALANCE: int
|
|
15
|
+
INITIAL_METHOD_LEAST_SQUARE: int
|
|
16
|
+
InitialMethodType = int
|
|
17
|
+
"""One of [INITIAL_METHOD_WHITE_BALANCE, INITIAL_METHOD_LEAST_SQUARE]"""
|
|
18
|
+
|
|
19
|
+
COLORCHECKER_MACBETH: int
|
|
20
|
+
COLORCHECKER_VINYL: int
|
|
21
|
+
COLORCHECKER_DIGITAL_SG: int
|
|
22
|
+
ColorCheckerType = int
|
|
23
|
+
"""One of [COLORCHECKER_MACBETH, COLORCHECKER_VINYL, COLORCHECKER_DIGITAL_SG]"""
|
|
24
|
+
|
|
25
|
+
COLOR_SPACE_SRGB: int
|
|
26
|
+
COLOR_SPACE_SRGBL: int
|
|
27
|
+
COLOR_SPACE_ADOBE_RGB: int
|
|
28
|
+
COLOR_SPACE_ADOBE_RGBL: int
|
|
29
|
+
COLOR_SPACE_WIDE_GAMUT_RGB: int
|
|
30
|
+
COLOR_SPACE_WIDE_GAMUT_RGBL: int
|
|
31
|
+
COLOR_SPACE_PRO_PHOTO_RGB: int
|
|
32
|
+
COLOR_SPACE_PRO_PHOTO_RGBL: int
|
|
33
|
+
COLOR_SPACE_DCI_P3_RGB: int
|
|
34
|
+
COLOR_SPACE_DCI_P3_RGBL: int
|
|
35
|
+
COLOR_SPACE_APPLE_RGB: int
|
|
36
|
+
COLOR_SPACE_APPLE_RGBL: int
|
|
37
|
+
COLOR_SPACE_REC_709_RGB: int
|
|
38
|
+
COLOR_SPACE_REC_709_RGBL: int
|
|
39
|
+
COLOR_SPACE_REC_2020_RGB: int
|
|
40
|
+
COLOR_SPACE_REC_2020_RGBL: int
|
|
41
|
+
COLOR_SPACE_XYZ_D65_2: int
|
|
42
|
+
COLOR_SPACE_XYZ_D50_2: int
|
|
43
|
+
COLOR_SPACE_XYZ_D65_10: int
|
|
44
|
+
COLOR_SPACE_XYZ_D50_10: int
|
|
45
|
+
COLOR_SPACE_XYZ_A_2: int
|
|
46
|
+
COLOR_SPACE_XYZ_A_10: int
|
|
47
|
+
COLOR_SPACE_XYZ_D55_2: int
|
|
48
|
+
COLOR_SPACE_XYZ_D55_10: int
|
|
49
|
+
COLOR_SPACE_XYZ_D75_2: int
|
|
50
|
+
COLOR_SPACE_XYZ_D75_10: int
|
|
51
|
+
COLOR_SPACE_XYZ_E_2: int
|
|
52
|
+
COLOR_SPACE_XYZ_E_10: int
|
|
53
|
+
COLOR_SPACE_LAB_D65_2: int
|
|
54
|
+
COLOR_SPACE_LAB_D50_2: int
|
|
55
|
+
COLOR_SPACE_LAB_D65_10: int
|
|
56
|
+
COLOR_SPACE_LAB_D50_10: int
|
|
57
|
+
COLOR_SPACE_LAB_A_2: int
|
|
58
|
+
COLOR_SPACE_LAB_A_10: int
|
|
59
|
+
COLOR_SPACE_LAB_D55_2: int
|
|
60
|
+
COLOR_SPACE_LAB_D55_10: int
|
|
61
|
+
COLOR_SPACE_LAB_D75_2: int
|
|
62
|
+
COLOR_SPACE_LAB_D75_10: int
|
|
63
|
+
COLOR_SPACE_LAB_E_2: int
|
|
64
|
+
COLOR_SPACE_LAB_E_10: int
|
|
65
|
+
ColorSpace = int
|
|
66
|
+
"""One of [COLOR_SPACE_SRGB, COLOR_SPACE_SRGBL, COLOR_SPACE_ADOBE_RGB, COLOR_SPACE_ADOBE_RGBL, COLOR_SPACE_WIDE_GAMUT_RGB, COLOR_SPACE_WIDE_GAMUT_RGBL, COLOR_SPACE_PRO_PHOTO_RGB, COLOR_SPACE_PRO_PHOTO_RGBL, COLOR_SPACE_DCI_P3_RGB, COLOR_SPACE_DCI_P3_RGBL, COLOR_SPACE_APPLE_RGB, COLOR_SPACE_APPLE_RGBL, COLOR_SPACE_REC_709_RGB, COLOR_SPACE_REC_709_RGBL, COLOR_SPACE_REC_2020_RGB, COLOR_SPACE_REC_2020_RGBL, COLOR_SPACE_XYZ_D65_2, COLOR_SPACE_XYZ_D50_2, COLOR_SPACE_XYZ_D65_10, COLOR_SPACE_XYZ_D50_10, COLOR_SPACE_XYZ_A_2, COLOR_SPACE_XYZ_A_10, COLOR_SPACE_XYZ_D55_2, COLOR_SPACE_XYZ_D55_10, COLOR_SPACE_XYZ_D75_2, COLOR_SPACE_XYZ_D75_10, COLOR_SPACE_XYZ_E_2, COLOR_SPACE_XYZ_E_10, COLOR_SPACE_LAB_D65_2, COLOR_SPACE_LAB_D50_2, COLOR_SPACE_LAB_D65_10, COLOR_SPACE_LAB_D50_10, COLOR_SPACE_LAB_A_2, COLOR_SPACE_LAB_A_10, COLOR_SPACE_LAB_D55_2, COLOR_SPACE_LAB_D55_10, COLOR_SPACE_LAB_D75_2, COLOR_SPACE_LAB_D75_10, COLOR_SPACE_LAB_E_2, COLOR_SPACE_LAB_E_10]"""
|
|
67
|
+
|
|
68
|
+
LINEARIZATION_IDENTITY: int
|
|
69
|
+
LINEARIZATION_GAMMA: int
|
|
70
|
+
LINEARIZATION_COLORPOLYFIT: int
|
|
71
|
+
LINEARIZATION_COLORLOGPOLYFIT: int
|
|
72
|
+
LINEARIZATION_GRAYPOLYFIT: int
|
|
73
|
+
LINEARIZATION_GRAYLOGPOLYFIT: int
|
|
74
|
+
LinearizationType = int
|
|
75
|
+
"""One of [LINEARIZATION_IDENTITY, LINEARIZATION_GAMMA, LINEARIZATION_COLORPOLYFIT, LINEARIZATION_COLORLOGPOLYFIT, LINEARIZATION_GRAYPOLYFIT, LINEARIZATION_GRAYLOGPOLYFIT]"""
|
|
76
|
+
|
|
77
|
+
DISTANCE_CIE76: int
|
|
78
|
+
DISTANCE_CIE94_GRAPHIC_ARTS: int
|
|
79
|
+
DISTANCE_CIE94_TEXTILES: int
|
|
80
|
+
DISTANCE_CIE2000: int
|
|
81
|
+
DISTANCE_CMC_1TO1: int
|
|
82
|
+
DISTANCE_CMC_2TO1: int
|
|
83
|
+
DISTANCE_RGB: int
|
|
84
|
+
DISTANCE_RGBL: int
|
|
85
|
+
DistanceType = int
|
|
86
|
+
"""One of [DISTANCE_CIE76, DISTANCE_CIE94_GRAPHIC_ARTS, DISTANCE_CIE94_TEXTILES, DISTANCE_CIE2000, DISTANCE_CMC_1TO1, DISTANCE_CMC_2TO1, DISTANCE_RGB, DISTANCE_RGBL]"""
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
# Classes
|
|
91
|
+
class ColorCorrectionModel:
|
|
92
|
+
# Functions
|
|
93
|
+
@_typing.overload
|
|
94
|
+
def __init__(self) -> None: ...
|
|
95
|
+
@_typing.overload
|
|
96
|
+
def __init__(self, src: cv2.typing.MatLike, constColor: int) -> None: ...
|
|
97
|
+
@_typing.overload
|
|
98
|
+
def __init__(self, src: cv2.UMat, constColor: int) -> None: ...
|
|
99
|
+
@_typing.overload
|
|
100
|
+
def __init__(self, src: cv2.typing.MatLike, colors: cv2.typing.MatLike, refColorSpace: ColorSpace) -> None: ...
|
|
101
|
+
@_typing.overload
|
|
102
|
+
def __init__(self, src: cv2.UMat, colors: cv2.UMat, refColorSpace: ColorSpace) -> None: ...
|
|
103
|
+
@_typing.overload
|
|
104
|
+
def __init__(self, src: cv2.typing.MatLike, colors: cv2.typing.MatLike, refColorSpace: ColorSpace, coloredPatchesMask: cv2.typing.MatLike) -> None: ...
|
|
105
|
+
@_typing.overload
|
|
106
|
+
def __init__(self, src: cv2.UMat, colors: cv2.UMat, refColorSpace: ColorSpace, coloredPatchesMask: cv2.UMat) -> None: ...
|
|
107
|
+
|
|
108
|
+
def setColorSpace(self, cs: ColorSpace) -> None: ...
|
|
109
|
+
|
|
110
|
+
def setCcmType(self, ccmType: CcmType) -> None: ...
|
|
111
|
+
|
|
112
|
+
def setDistance(self, distance: DistanceType) -> None: ...
|
|
113
|
+
|
|
114
|
+
def setLinearization(self, linearizationType: LinearizationType) -> None: ...
|
|
115
|
+
|
|
116
|
+
def setLinearizationGamma(self, gamma: float) -> None: ...
|
|
117
|
+
|
|
118
|
+
def setLinearizationDegree(self, deg: int) -> None: ...
|
|
119
|
+
|
|
120
|
+
def setSaturatedThreshold(self, lower: float, upper: float) -> None: ...
|
|
121
|
+
|
|
122
|
+
def setWeightsList(self, weightsList: cv2.typing.MatLike) -> None: ...
|
|
123
|
+
|
|
124
|
+
def setWeightCoeff(self, weightsCoeff: float) -> None: ...
|
|
125
|
+
|
|
126
|
+
def setInitialMethod(self, initialMethodType: InitialMethodType) -> None: ...
|
|
127
|
+
|
|
128
|
+
def setMaxCount(self, maxCount: int) -> None: ...
|
|
129
|
+
|
|
130
|
+
def setEpsilon(self, epsilon: float) -> None: ...
|
|
131
|
+
|
|
132
|
+
def setRGB(self, rgb: bool) -> None: ...
|
|
133
|
+
|
|
134
|
+
def compute(self) -> cv2.typing.MatLike: ...
|
|
135
|
+
|
|
136
|
+
def getColorCorrectionMatrix(self) -> cv2.typing.MatLike: ...
|
|
137
|
+
|
|
138
|
+
def getLoss(self) -> float: ...
|
|
139
|
+
|
|
140
|
+
def getSrcLinearRGB(self) -> cv2.typing.MatLike: ...
|
|
141
|
+
|
|
142
|
+
def getRefLinearRGB(self) -> cv2.typing.MatLike: ...
|
|
143
|
+
|
|
144
|
+
def getMask(self) -> cv2.typing.MatLike: ...
|
|
145
|
+
|
|
146
|
+
def getWeights(self) -> cv2.typing.MatLike: ...
|
|
147
|
+
|
|
148
|
+
@_typing.overload
|
|
149
|
+
def correctImage(self, src: cv2.typing.MatLike, dst: cv2.typing.MatLike | None = ..., islinear: bool = ...) -> cv2.typing.MatLike: ...
|
|
150
|
+
@_typing.overload
|
|
151
|
+
def correctImage(self, src: cv2.UMat, dst: cv2.UMat | None = ..., islinear: bool = ...) -> cv2.UMat: ...
|
|
152
|
+
|
|
153
|
+
def write(self, fs: cv2.FileStorage) -> None: ...
|
|
154
|
+
|
|
155
|
+
def read(self, node: cv2.FileNode) -> None: ...
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
# Functions
|
|
160
|
+
@_typing.overload
|
|
161
|
+
def gammaCorrection(src: cv2.typing.MatLike, gamma: float, dst: cv2.typing.MatLike | None = ...) -> cv2.typing.MatLike: ...
|
|
162
|
+
@_typing.overload
|
|
163
|
+
def gammaCorrection(src: cv2.UMat, gamma: float, dst: cv2.UMat | None = ...) -> cv2.UMat: ...
|
|
164
|
+
|
|
165
|
+
|
cv2/config-3.py
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
PYTHON_EXTENSIONS_PATHS = [
|
|
2
|
+
LOADER_DIR
|
|
3
|
+
] + PYTHON_EXTENSIONS_PATHS
|
|
4
|
+
|
|
5
|
+
ci_and_not_headless = False
|
|
6
|
+
|
|
7
|
+
try:
|
|
8
|
+
from .version import ci_build, headless
|
|
9
|
+
|
|
10
|
+
ci_and_not_headless = ci_build and not headless
|
|
11
|
+
except:
|
|
12
|
+
pass
|
|
13
|
+
|
|
14
|
+
# the Qt plugin is included currently only in the pre-built wheels
|
|
15
|
+
if sys.platform.startswith("linux") and ci_and_not_headless:
|
|
16
|
+
os.environ["QT_QPA_PLATFORM_PLUGIN_PATH"] = os.path.join(
|
|
17
|
+
os.path.dirname(os.path.abspath(__file__)), "qt", "plugins"
|
|
18
|
+
)
|
|
19
|
+
|
|
20
|
+
# Qt will throw warning on Linux if fonts are not found
|
|
21
|
+
if sys.platform.startswith("linux") and ci_and_not_headless:
|
|
22
|
+
os.environ["QT_QPA_FONTDIR"] = os.path.join(
|
|
23
|
+
os.path.dirname(os.path.abspath(__file__)), "qt", "fonts"
|
|
24
|
+
)
|