__init__.pyi 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627
  1. __all__: list[str] = []
  2. import cv2
  3. import cv2.gapi
  4. import cv2.gapi.ie
  5. import cv2.gapi.onnx
  6. import cv2.gapi.ov
  7. import cv2.typing
  8. import numpy
  9. import typing as _typing
  10. # Enumerations
  11. TEST_CUSTOM: int
  12. TEST_EQ: int
  13. TEST_NE: int
  14. TEST_LE: int
  15. TEST_LT: int
  16. TEST_GE: int
  17. TEST_GT: int
  18. TestOp = int
  19. """One of [TEST_CUSTOM, TEST_EQ, TEST_NE, TEST_LE, TEST_LT, TEST_GE, TEST_GT]"""
  20. OpaqueKind_CV_UNKNOWN: int
  21. OPAQUE_KIND_CV_UNKNOWN: int
  22. OpaqueKind_CV_BOOL: int
  23. OPAQUE_KIND_CV_BOOL: int
  24. OpaqueKind_CV_INT: int
  25. OPAQUE_KIND_CV_INT: int
  26. OpaqueKind_CV_INT64: int
  27. OPAQUE_KIND_CV_INT64: int
  28. OpaqueKind_CV_DOUBLE: int
  29. OPAQUE_KIND_CV_DOUBLE: int
  30. OpaqueKind_CV_FLOAT: int
  31. OPAQUE_KIND_CV_FLOAT: int
  32. OpaqueKind_CV_UINT64: int
  33. OPAQUE_KIND_CV_UINT64: int
  34. OpaqueKind_CV_STRING: int
  35. OPAQUE_KIND_CV_STRING: int
  36. OpaqueKind_CV_POINT: int
  37. OPAQUE_KIND_CV_POINT: int
  38. OpaqueKind_CV_POINT2F: int
  39. OPAQUE_KIND_CV_POINT2F: int
  40. OpaqueKind_CV_POINT3F: int
  41. OPAQUE_KIND_CV_POINT3F: int
  42. OpaqueKind_CV_SIZE: int
  43. OPAQUE_KIND_CV_SIZE: int
  44. OpaqueKind_CV_RECT: int
  45. OPAQUE_KIND_CV_RECT: int
  46. OpaqueKind_CV_SCALAR: int
  47. OPAQUE_KIND_CV_SCALAR: int
  48. OpaqueKind_CV_MAT: int
  49. OPAQUE_KIND_CV_MAT: int
  50. OpaqueKind_CV_DRAW_PRIM: int
  51. OPAQUE_KIND_CV_DRAW_PRIM: int
  52. OpaqueKind = int
  53. """One of [OpaqueKind_CV_UNKNOWN, OPAQUE_KIND_CV_UNKNOWN, OpaqueKind_CV_BOOL, OPAQUE_KIND_CV_BOOL, OpaqueKind_CV_INT, OPAQUE_KIND_CV_INT, OpaqueKind_CV_INT64, OPAQUE_KIND_CV_INT64, OpaqueKind_CV_DOUBLE, OPAQUE_KIND_CV_DOUBLE, OpaqueKind_CV_FLOAT, OPAQUE_KIND_CV_FLOAT, OpaqueKind_CV_UINT64, OPAQUE_KIND_CV_UINT64, OpaqueKind_CV_STRING, OPAQUE_KIND_CV_STRING, OpaqueKind_CV_POINT, OPAQUE_KIND_CV_POINT, OpaqueKind_CV_POINT2F, OPAQUE_KIND_CV_POINT2F, OpaqueKind_CV_POINT3F, OPAQUE_KIND_CV_POINT3F, OpaqueKind_CV_SIZE, OPAQUE_KIND_CV_SIZE, OpaqueKind_CV_RECT, OPAQUE_KIND_CV_RECT, OpaqueKind_CV_SCALAR, OPAQUE_KIND_CV_SCALAR, OpaqueKind_CV_MAT, OPAQUE_KIND_CV_MAT, OpaqueKind_CV_DRAW_PRIM, OPAQUE_KIND_CV_DRAW_PRIM]"""
  54. ArgKind_OPAQUE_VAL: int
  55. ARG_KIND_OPAQUE_VAL: int
  56. ArgKind_OPAQUE: int
  57. ARG_KIND_OPAQUE: int
  58. ArgKind_GOBJREF: int
  59. ARG_KIND_GOBJREF: int
  60. ArgKind_GMAT: int
  61. ARG_KIND_GMAT: int
  62. ArgKind_GMATP: int
  63. ARG_KIND_GMATP: int
  64. ArgKind_GFRAME: int
  65. ARG_KIND_GFRAME: int
  66. ArgKind_GSCALAR: int
  67. ARG_KIND_GSCALAR: int
  68. ArgKind_GARRAY: int
  69. ARG_KIND_GARRAY: int
  70. ArgKind_GOPAQUE: int
  71. ARG_KIND_GOPAQUE: int
  72. ArgKind = int
  73. """One of [ArgKind_OPAQUE_VAL, ARG_KIND_OPAQUE_VAL, ArgKind_OPAQUE, ARG_KIND_OPAQUE, ArgKind_GOBJREF, ARG_KIND_GOBJREF, ArgKind_GMAT, ARG_KIND_GMAT, ArgKind_GMATP, ARG_KIND_GMATP, ArgKind_GFRAME, ARG_KIND_GFRAME, ArgKind_GSCALAR, ARG_KIND_GSCALAR, ArgKind_GARRAY, ARG_KIND_GARRAY, ArgKind_GOPAQUE, ARG_KIND_GOPAQUE]"""
  74. WAVE_CORRECT_HORIZ: int
  75. WAVE_CORRECT_VERT: int
  76. WAVE_CORRECT_AUTO: int
  77. WaveCorrectKind = int
  78. """One of [WAVE_CORRECT_HORIZ, WAVE_CORRECT_VERT, WAVE_CORRECT_AUTO]"""
  79. Blender_NO: int
  80. BLENDER_NO: int
  81. Blender_FEATHER: int
  82. BLENDER_FEATHER: int
  83. Blender_MULTI_BAND: int
  84. BLENDER_MULTI_BAND: int
  85. ExposureCompensator_NO: int
  86. EXPOSURE_COMPENSATOR_NO: int
  87. ExposureCompensator_GAIN: int
  88. EXPOSURE_COMPENSATOR_GAIN: int
  89. ExposureCompensator_GAIN_BLOCKS: int
  90. EXPOSURE_COMPENSATOR_GAIN_BLOCKS: int
  91. ExposureCompensator_CHANNELS: int
  92. EXPOSURE_COMPENSATOR_CHANNELS: int
  93. ExposureCompensator_CHANNELS_BLOCKS: int
  94. EXPOSURE_COMPENSATOR_CHANNELS_BLOCKS: int
  95. SeamFinder_NO: int
  96. SEAM_FINDER_NO: int
  97. SeamFinder_VORONOI_SEAM: int
  98. SEAM_FINDER_VORONOI_SEAM: int
  99. SeamFinder_DP_SEAM: int
  100. SEAM_FINDER_DP_SEAM: int
  101. DpSeamFinder_COLOR: int
  102. DP_SEAM_FINDER_COLOR: int
  103. DpSeamFinder_COLOR_GRAD: int
  104. DP_SEAM_FINDER_COLOR_GRAD: int
  105. DpSeamFinder_CostFunction = int
  106. """One of [DpSeamFinder_COLOR, DP_SEAM_FINDER_COLOR, DpSeamFinder_COLOR_GRAD, DP_SEAM_FINDER_COLOR_GRAD]"""
  107. Timelapser_AS_IS: int
  108. TIMELAPSER_AS_IS: int
  109. Timelapser_CROP: int
  110. TIMELAPSER_CROP: int
  111. TrackerSamplerCSC_MODE_INIT_POS: int
  112. TRACKER_SAMPLER_CSC_MODE_INIT_POS: int
  113. TrackerSamplerCSC_MODE_INIT_NEG: int
  114. TRACKER_SAMPLER_CSC_MODE_INIT_NEG: int
  115. TrackerSamplerCSC_MODE_TRACK_POS: int
  116. TRACKER_SAMPLER_CSC_MODE_TRACK_POS: int
  117. TrackerSamplerCSC_MODE_TRACK_NEG: int
  118. TRACKER_SAMPLER_CSC_MODE_TRACK_NEG: int
  119. TrackerSamplerCSC_MODE_DETECT: int
  120. TRACKER_SAMPLER_CSC_MODE_DETECT: int
  121. TrackerSamplerCSC_MODE = int
  122. """One of [TrackerSamplerCSC_MODE_INIT_POS, TRACKER_SAMPLER_CSC_MODE_INIT_POS, TrackerSamplerCSC_MODE_INIT_NEG, TRACKER_SAMPLER_CSC_MODE_INIT_NEG, TrackerSamplerCSC_MODE_TRACK_POS, TRACKER_SAMPLER_CSC_MODE_TRACK_POS, TrackerSamplerCSC_MODE_TRACK_NEG, TRACKER_SAMPLER_CSC_MODE_TRACK_NEG, TrackerSamplerCSC_MODE_DETECT, TRACKER_SAMPLER_CSC_MODE_DETECT]"""
  123. GraphCutSeamFinderBase_COST_COLOR: int
  124. GRAPH_CUT_SEAM_FINDER_BASE_COST_COLOR: int
  125. GraphCutSeamFinderBase_COST_COLOR_GRAD: int
  126. GRAPH_CUT_SEAM_FINDER_BASE_COST_COLOR_GRAD: int
  127. GraphCutSeamFinderBase_CostType = int
  128. """One of [GraphCutSeamFinderBase_COST_COLOR, GRAPH_CUT_SEAM_FINDER_BASE_COST_COLOR, GraphCutSeamFinderBase_COST_COLOR_GRAD, GRAPH_CUT_SEAM_FINDER_BASE_COST_COLOR_GRAD]"""
  129. CvFeatureParams_HAAR: int
  130. CV_FEATURE_PARAMS_HAAR: int
  131. CvFeatureParams_LBP: int
  132. CV_FEATURE_PARAMS_LBP: int
  133. CvFeatureParams_HOG: int
  134. CV_FEATURE_PARAMS_HOG: int
  135. CvFeatureParams_FeatureType = int
  136. """One of [CvFeatureParams_HAAR, CV_FEATURE_PARAMS_HAAR, CvFeatureParams_LBP, CV_FEATURE_PARAMS_LBP, CvFeatureParams_HOG, CV_FEATURE_PARAMS_HOG]"""
  137. TrackerContribSamplerCSC_MODE_INIT_POS: int
  138. TRACKER_CONTRIB_SAMPLER_CSC_MODE_INIT_POS: int
  139. TrackerContribSamplerCSC_MODE_INIT_NEG: int
  140. TRACKER_CONTRIB_SAMPLER_CSC_MODE_INIT_NEG: int
  141. TrackerContribSamplerCSC_MODE_TRACK_POS: int
  142. TRACKER_CONTRIB_SAMPLER_CSC_MODE_TRACK_POS: int
  143. TrackerContribSamplerCSC_MODE_TRACK_NEG: int
  144. TRACKER_CONTRIB_SAMPLER_CSC_MODE_TRACK_NEG: int
  145. TrackerContribSamplerCSC_MODE_DETECT: int
  146. TRACKER_CONTRIB_SAMPLER_CSC_MODE_DETECT: int
  147. TrackerSamplerCS_MODE_POSITIVE: int
  148. TRACKER_SAMPLER_CS_MODE_POSITIVE: int
  149. TrackerSamplerCS_MODE_NEGATIVE: int
  150. TRACKER_SAMPLER_CS_MODE_NEGATIVE: int
  151. TrackerSamplerCS_MODE_CLASSIFY: int
  152. TRACKER_SAMPLER_CS_MODE_CLASSIFY: int
  153. # Classes
  154. class Blender:
  155. # Functions
  156. @classmethod
  157. def createDefault(cls, type: int, try_gpu: bool = ...) -> Blender: ...
  158. @_typing.overload
  159. def prepare(self, corners: _typing.Sequence[cv2.typing.Point], sizes: _typing.Sequence[cv2.typing.Size]) -> None: ...
  160. @_typing.overload
  161. def prepare(self, dst_roi: cv2.typing.Rect) -> None: ...
  162. @_typing.overload
  163. def feed(self, img: cv2.typing.MatLike, mask: cv2.typing.MatLike, tl: cv2.typing.Point) -> None: ...
  164. @_typing.overload
  165. def feed(self, img: cv2.UMat, mask: cv2.UMat, tl: cv2.typing.Point) -> None: ...
  166. @_typing.overload
  167. def blend(self, dst: cv2.typing.MatLike, dst_mask: cv2.typing.MatLike) -> tuple[cv2.typing.MatLike, cv2.typing.MatLike]: ...
  168. @_typing.overload
  169. def blend(self, dst: cv2.UMat, dst_mask: cv2.UMat) -> tuple[cv2.UMat, cv2.UMat]: ...
  170. class FeatherBlender(Blender):
  171. # Functions
  172. def __init__(self, sharpness: float = ...) -> None: ...
  173. def sharpness(self) -> float: ...
  174. def setSharpness(self, val: float) -> None: ...
  175. def prepare(self, dst_roi: cv2.typing.Rect) -> None: ...
  176. @_typing.overload
  177. def feed(self, img: cv2.typing.MatLike, mask: cv2.typing.MatLike, tl: cv2.typing.Point) -> None: ...
  178. @_typing.overload
  179. def feed(self, img: cv2.UMat, mask: cv2.UMat, tl: cv2.typing.Point) -> None: ...
  180. @_typing.overload
  181. def blend(self, dst: cv2.typing.MatLike, dst_mask: cv2.typing.MatLike) -> tuple[cv2.typing.MatLike, cv2.typing.MatLike]: ...
  182. @_typing.overload
  183. def blend(self, dst: cv2.UMat, dst_mask: cv2.UMat) -> tuple[cv2.UMat, cv2.UMat]: ...
  184. def createWeightMaps(self, masks: _typing.Sequence[cv2.UMat], corners: _typing.Sequence[cv2.typing.Point], weight_maps: _typing.Sequence[cv2.UMat]) -> tuple[cv2.typing.Rect, _typing.Sequence[cv2.UMat]]: ...
  185. class MultiBandBlender(Blender):
  186. # Functions
  187. def __init__(self, try_gpu: int = ..., num_bands: int = ..., weight_type: int = ...) -> None: ...
  188. def numBands(self) -> int: ...
  189. def setNumBands(self, val: int) -> None: ...
  190. def prepare(self, dst_roi: cv2.typing.Rect) -> None: ...
  191. @_typing.overload
  192. def feed(self, img: cv2.typing.MatLike, mask: cv2.typing.MatLike, tl: cv2.typing.Point) -> None: ...
  193. @_typing.overload
  194. def feed(self, img: cv2.UMat, mask: cv2.UMat, tl: cv2.typing.Point) -> None: ...
  195. @_typing.overload
  196. def blend(self, dst: cv2.typing.MatLike, dst_mask: cv2.typing.MatLike) -> tuple[cv2.typing.MatLike, cv2.typing.MatLike]: ...
  197. @_typing.overload
  198. def blend(self, dst: cv2.UMat, dst_mask: cv2.UMat) -> tuple[cv2.UMat, cv2.UMat]: ...
  199. class CameraParams:
  200. focal: float
  201. aspect: float
  202. ppx: float
  203. ppy: float
  204. R: cv2.typing.MatLike
  205. t: cv2.typing.MatLike
  206. # Functions
  207. def K(self) -> cv2.typing.MatLike: ...
  208. class ExposureCompensator:
  209. # Functions
  210. @classmethod
  211. def createDefault(cls, type: int) -> ExposureCompensator: ...
  212. def feed(self, corners: _typing.Sequence[cv2.typing.Point], images: _typing.Sequence[cv2.UMat], masks: _typing.Sequence[cv2.UMat]) -> None: ...
  213. @_typing.overload
  214. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.typing.MatLike, mask: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  215. @_typing.overload
  216. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.UMat, mask: cv2.UMat) -> cv2.UMat: ...
  217. def getMatGains(self, arg1: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[cv2.typing.MatLike]: ...
  218. def setMatGains(self, arg1: _typing.Sequence[cv2.typing.MatLike]) -> None: ...
  219. def setUpdateGain(self, b: bool) -> None: ...
  220. def getUpdateGain(self) -> bool: ...
  221. class NoExposureCompensator(ExposureCompensator):
  222. # Functions
  223. @_typing.overload
  224. def apply(self, arg1: int, arg2: cv2.typing.Point, arg3: cv2.typing.MatLike, arg4: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  225. @_typing.overload
  226. def apply(self, arg1: int, arg2: cv2.typing.Point, arg3: cv2.UMat, arg4: cv2.UMat) -> cv2.UMat: ...
  227. def getMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[cv2.typing.MatLike]: ...
  228. def setMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike]) -> None: ...
  229. class GainCompensator(ExposureCompensator):
  230. # Functions
  231. @_typing.overload
  232. def __init__(self) -> None: ...
  233. @_typing.overload
  234. def __init__(self, nr_feeds: int) -> None: ...
  235. @_typing.overload
  236. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.typing.MatLike, mask: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  237. @_typing.overload
  238. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.UMat, mask: cv2.UMat) -> cv2.UMat: ...
  239. def getMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[cv2.typing.MatLike]: ...
  240. def setMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike]) -> None: ...
  241. def setNrFeeds(self, nr_feeds: int) -> None: ...
  242. def getNrFeeds(self) -> int: ...
  243. def setSimilarityThreshold(self, similarity_threshold: float) -> None: ...
  244. def getSimilarityThreshold(self) -> float: ...
  245. class ChannelsCompensator(ExposureCompensator):
  246. # Functions
  247. def __init__(self, nr_feeds: int = ...) -> None: ...
  248. @_typing.overload
  249. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.typing.MatLike, mask: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  250. @_typing.overload
  251. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.UMat, mask: cv2.UMat) -> cv2.UMat: ...
  252. def getMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[cv2.typing.MatLike]: ...
  253. def setMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike]) -> None: ...
  254. def setNrFeeds(self, nr_feeds: int) -> None: ...
  255. def getNrFeeds(self) -> int: ...
  256. def setSimilarityThreshold(self, similarity_threshold: float) -> None: ...
  257. def getSimilarityThreshold(self) -> float: ...
  258. class BlocksCompensator(ExposureCompensator):
  259. # Functions
  260. @_typing.overload
  261. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.typing.MatLike, mask: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  262. @_typing.overload
  263. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.UMat, mask: cv2.UMat) -> cv2.UMat: ...
  264. def getMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[cv2.typing.MatLike]: ...
  265. def setMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike]) -> None: ...
  266. def setNrFeeds(self, nr_feeds: int) -> None: ...
  267. def getNrFeeds(self) -> int: ...
  268. def setSimilarityThreshold(self, similarity_threshold: float) -> None: ...
  269. def getSimilarityThreshold(self) -> float: ...
  270. @_typing.overload
  271. def setBlockSize(self, width: int, height: int) -> None: ...
  272. @_typing.overload
  273. def setBlockSize(self, size: cv2.typing.Size) -> None: ...
  274. def getBlockSize(self) -> cv2.typing.Size: ...
  275. def setNrGainsFilteringIterations(self, nr_iterations: int) -> None: ...
  276. def getNrGainsFilteringIterations(self) -> int: ...
  277. class BlocksGainCompensator(BlocksCompensator):
  278. # Functions
  279. @_typing.overload
  280. def __init__(self, bl_width: int = ..., bl_height: int = ...) -> None: ...
  281. @_typing.overload
  282. def __init__(self, bl_width: int, bl_height: int, nr_feeds: int) -> None: ...
  283. @_typing.overload
  284. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.typing.MatLike, mask: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  285. @_typing.overload
  286. def apply(self, index: int, corner: cv2.typing.Point, image: cv2.UMat, mask: cv2.UMat) -> cv2.UMat: ...
  287. def getMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[cv2.typing.MatLike]: ...
  288. def setMatGains(self, umv: _typing.Sequence[cv2.typing.MatLike]) -> None: ...
  289. class BlocksChannelsCompensator(BlocksCompensator):
  290. # Functions
  291. def __init__(self, bl_width: int = ..., bl_height: int = ..., nr_feeds: int = ...) -> None: ...
  292. class ImageFeatures:
  293. img_idx: int
  294. img_size: cv2.typing.Size
  295. keypoints: _typing.Sequence[cv2.KeyPoint]
  296. descriptors: cv2.UMat
  297. # Functions
  298. def getKeypoints(self) -> _typing.Sequence[cv2.KeyPoint]: ...
  299. class MatchesInfo:
  300. src_img_idx: int
  301. dst_img_idx: int
  302. matches: _typing.Sequence[cv2.DMatch]
  303. inliers_mask: numpy.ndarray[_typing.Any, numpy.dtype[numpy.uint8]]
  304. num_inliers: int
  305. H: cv2.typing.MatLike
  306. confidence: float
  307. # Functions
  308. def getMatches(self) -> _typing.Sequence[cv2.DMatch]: ...
  309. def getInliers(self) -> numpy.ndarray[_typing.Any, numpy.dtype[numpy.uint8]]: ...
  310. class FeaturesMatcher:
  311. # Functions
  312. def apply(self, features1: ImageFeatures, features2: ImageFeatures) -> MatchesInfo: ...
  313. def apply2(self, features: _typing.Sequence[ImageFeatures], mask: cv2.UMat | None = ...) -> _typing.Sequence[MatchesInfo]: ...
  314. def isThreadSafe(self) -> bool: ...
  315. def collectGarbage(self) -> None: ...
  316. class BestOf2NearestMatcher(FeaturesMatcher):
  317. # Functions
  318. def __init__(self, try_use_gpu: bool = ..., match_conf: float = ..., num_matches_thresh1: int = ..., num_matches_thresh2: int = ..., matches_confindece_thresh: float = ...) -> None: ...
  319. def collectGarbage(self) -> None: ...
  320. @classmethod
  321. def create(cls, try_use_gpu: bool = ..., match_conf: float = ..., num_matches_thresh1: int = ..., num_matches_thresh2: int = ..., matches_confindece_thresh: float = ...) -> BestOf2NearestMatcher: ...
  322. class BestOf2NearestRangeMatcher(BestOf2NearestMatcher):
  323. # Functions
  324. def __init__(self, range_width: int = ..., try_use_gpu: bool = ..., match_conf: float = ..., num_matches_thresh1: int = ..., num_matches_thresh2: int = ...) -> None: ...
  325. class AffineBestOf2NearestMatcher(BestOf2NearestMatcher):
  326. # Functions
  327. def __init__(self, full_affine: bool = ..., try_use_gpu: bool = ..., match_conf: float = ..., num_matches_thresh1: int = ...) -> None: ...
  328. class Estimator:
  329. # Functions
  330. def apply(self, features: _typing.Sequence[ImageFeatures], pairwise_matches: _typing.Sequence[MatchesInfo], cameras: _typing.Sequence[CameraParams]) -> tuple[bool, _typing.Sequence[CameraParams]]: ...
  331. class HomographyBasedEstimator(Estimator):
  332. # Functions
  333. def __init__(self, is_focals_estimated: bool = ...) -> None: ...
  334. class AffineBasedEstimator(Estimator):
  335. # Functions
  336. def __init__(self) -> None: ...
  337. class BundleAdjusterBase(Estimator):
  338. # Functions
  339. def refinementMask(self) -> cv2.typing.MatLike: ...
  340. def setRefinementMask(self, mask: cv2.typing.MatLike) -> None: ...
  341. def confThresh(self) -> float: ...
  342. def setConfThresh(self, conf_thresh: float) -> None: ...
  343. def termCriteria(self) -> cv2.typing.TermCriteria: ...
  344. def setTermCriteria(self, term_criteria: cv2.typing.TermCriteria) -> None: ...
  345. class NoBundleAdjuster(BundleAdjusterBase):
  346. # Functions
  347. def __init__(self) -> None: ...
  348. class BundleAdjusterReproj(BundleAdjusterBase):
  349. # Functions
  350. def __init__(self) -> None: ...
  351. class BundleAdjusterRay(BundleAdjusterBase):
  352. # Functions
  353. def __init__(self) -> None: ...
  354. class BundleAdjusterAffine(BundleAdjusterBase):
  355. # Functions
  356. def __init__(self) -> None: ...
  357. class BundleAdjusterAffinePartial(BundleAdjusterBase):
  358. # Functions
  359. def __init__(self) -> None: ...
  360. class SeamFinder:
  361. # Functions
  362. def find(self, src: _typing.Sequence[cv2.UMat], corners: _typing.Sequence[cv2.typing.Point], masks: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  363. @classmethod
  364. def createDefault(cls, type: int) -> SeamFinder: ...
  365. class NoSeamFinder(SeamFinder):
  366. # Functions
  367. def find(self, arg1: _typing.Sequence[cv2.UMat], arg2: _typing.Sequence[cv2.typing.Point], arg3: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  368. class PairwiseSeamFinder(SeamFinder):
  369. # Functions
  370. def find(self, src: _typing.Sequence[cv2.UMat], corners: _typing.Sequence[cv2.typing.Point], masks: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  371. class VoronoiSeamFinder(PairwiseSeamFinder):
  372. # Functions
  373. def find(self, src: _typing.Sequence[cv2.UMat], corners: _typing.Sequence[cv2.typing.Point], masks: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  374. class DpSeamFinder(SeamFinder):
  375. # Functions
  376. def __init__(self, costFunc: str) -> None: ...
  377. def setCostFunction(self, val: str) -> None: ...
  378. class GraphCutSeamFinder:
  379. # Functions
  380. def __init__(self, cost_type: str, terminal_cost: float = ..., bad_region_penalty: float = ...) -> None: ...
  381. def find(self, src: _typing.Sequence[cv2.UMat], corners: _typing.Sequence[cv2.typing.Point], masks: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  382. class Timelapser:
  383. # Functions
  384. @classmethod
  385. def createDefault(cls, type: int) -> Timelapser: ...
  386. def initialize(self, corners: _typing.Sequence[cv2.typing.Point], sizes: _typing.Sequence[cv2.typing.Size]) -> None: ...
  387. @_typing.overload
  388. def process(self, img: cv2.typing.MatLike, mask: cv2.typing.MatLike, tl: cv2.typing.Point) -> None: ...
  389. @_typing.overload
  390. def process(self, img: cv2.UMat, mask: cv2.UMat, tl: cv2.typing.Point) -> None: ...
  391. def getDst(self) -> cv2.UMat: ...
  392. class TimelapserCrop(Timelapser):
  393. ...
  394. class ProjectorBase:
  395. ...
  396. class SphericalProjector(ProjectorBase):
  397. # Functions
  398. def mapForward(self, x: float, y: float, u: float, v: float) -> None: ...
  399. def mapBackward(self, u: float, v: float, x: float, y: float) -> None: ...
  400. # Functions
  401. def calibrateRotatingCamera(Hs: _typing.Sequence[cv2.typing.MatLike], K: cv2.typing.MatLike | None = ...) -> tuple[bool, cv2.typing.MatLike]: ...
  402. @_typing.overload
  403. def computeImageFeatures(featuresFinder: cv2.Feature2D, images: _typing.Sequence[cv2.typing.MatLike], masks: _typing.Sequence[cv2.typing.MatLike] | None = ...) -> _typing.Sequence[ImageFeatures]: ...
  404. @_typing.overload
  405. def computeImageFeatures(featuresFinder: cv2.Feature2D, images: _typing.Sequence[cv2.UMat], masks: _typing.Sequence[cv2.UMat] | None = ...) -> _typing.Sequence[ImageFeatures]: ...
  406. @_typing.overload
  407. def computeImageFeatures2(featuresFinder: cv2.Feature2D, image: cv2.typing.MatLike, mask: cv2.typing.MatLike | None = ...) -> ImageFeatures: ...
  408. @_typing.overload
  409. def computeImageFeatures2(featuresFinder: cv2.Feature2D, image: cv2.UMat, mask: cv2.UMat | None = ...) -> ImageFeatures: ...
  410. @_typing.overload
  411. def createLaplacePyr(img: cv2.typing.MatLike, num_levels: int, pyr: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  412. @_typing.overload
  413. def createLaplacePyr(img: cv2.UMat, num_levels: int, pyr: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  414. @_typing.overload
  415. def createLaplacePyrGpu(img: cv2.typing.MatLike, num_levels: int, pyr: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  416. @_typing.overload
  417. def createLaplacePyrGpu(img: cv2.UMat, num_levels: int, pyr: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  418. @_typing.overload
  419. def createWeightMap(mask: cv2.typing.MatLike, sharpness: float, weight: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  420. @_typing.overload
  421. def createWeightMap(mask: cv2.UMat, sharpness: float, weight: cv2.UMat) -> cv2.UMat: ...
  422. def focalsFromHomography(H: cv2.typing.MatLike, f0: float, f1: float, f0_ok: bool, f1_ok: bool) -> None: ...
  423. def leaveBiggestComponent(features: _typing.Sequence[ImageFeatures], pairwise_matches: _typing.Sequence[MatchesInfo], conf_threshold: float) -> _typing.Sequence[int]: ...
  424. def matchesGraphAsString(paths: _typing.Sequence[str], pairwise_matches: _typing.Sequence[MatchesInfo], conf_threshold: float) -> str: ...
  425. @_typing.overload
  426. def normalizeUsingWeightMap(weight: cv2.typing.MatLike, src: cv2.typing.MatLike) -> cv2.typing.MatLike: ...
  427. @_typing.overload
  428. def normalizeUsingWeightMap(weight: cv2.UMat, src: cv2.UMat) -> cv2.UMat: ...
  429. def overlapRoi(tl1: cv2.typing.Point, tl2: cv2.typing.Point, sz1: cv2.typing.Size, sz2: cv2.typing.Size, roi: cv2.typing.Rect) -> bool: ...
  430. def restoreImageFromLaplacePyr(pyr: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  431. def restoreImageFromLaplacePyrGpu(pyr: _typing.Sequence[cv2.UMat]) -> _typing.Sequence[cv2.UMat]: ...
  432. @_typing.overload
  433. def resultRoi(corners: _typing.Sequence[cv2.typing.Point], images: _typing.Sequence[cv2.UMat]) -> cv2.typing.Rect: ...
  434. @_typing.overload
  435. def resultRoi(corners: _typing.Sequence[cv2.typing.Point], sizes: _typing.Sequence[cv2.typing.Size]) -> cv2.typing.Rect: ...
  436. def resultRoiIntersection(corners: _typing.Sequence[cv2.typing.Point], sizes: _typing.Sequence[cv2.typing.Size]) -> cv2.typing.Rect: ...
  437. def resultTl(corners: _typing.Sequence[cv2.typing.Point]) -> cv2.typing.Point: ...
  438. def selectRandomSubset(count: int, size: int, subset: _typing.Sequence[int]) -> None: ...
  439. def stitchingLogLevel() -> int: ...
  440. @_typing.overload
  441. def strip(params: cv2.gapi.ie.PyParams) -> cv2.gapi.GNetParam: ...
  442. @_typing.overload
  443. def strip(params: cv2.gapi.onnx.PyParams) -> cv2.gapi.GNetParam: ...
  444. @_typing.overload
  445. def strip(params: cv2.gapi.ov.PyParams) -> cv2.gapi.GNetParam: ...
  446. def waveCorrect(rmats: _typing.Sequence[cv2.typing.MatLike], kind: WaveCorrectKind) -> _typing.Sequence[cv2.typing.MatLike]: ...