__init__.pyi 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. __all__: list[str] = []
  2. import cv2.gapi.onnx.ep
  3. import cv2.typing
  4. import typing as _typing
  5. from cv2.gapi.onnx import ep as ep
  6. # Enumerations
  7. TraitAs_TENSOR: int
  8. TRAIT_AS_TENSOR: int
  9. TraitAs_IMAGE: int
  10. TRAIT_AS_IMAGE: int
  11. TraitAs = int
  12. """One of [TraitAs_TENSOR, TRAIT_AS_TENSOR, TraitAs_IMAGE, TRAIT_AS_IMAGE]"""
  13. # Classes
  14. class PyParams:
  15. # Functions
  16. @_typing.overload
  17. def __init__(self) -> None: ...
  18. @_typing.overload
  19. def __init__(self, tag: str, model_path: str) -> None: ...
  20. def cfgMeanStd(self, layer_name: str, m: cv2.typing.Scalar, s: cv2.typing.Scalar) -> PyParams: ...
  21. def cfgNormalize(self, layer_name: str, flag: bool) -> PyParams: ...
  22. @_typing.overload
  23. def cfgAddExecutionProvider(self, ep: cv2.gapi.onnx.ep.OpenVINO) -> PyParams: ...
  24. @_typing.overload
  25. def cfgAddExecutionProvider(self, ep: cv2.gapi.onnx.ep.DirectML) -> PyParams: ...
  26. @_typing.overload
  27. def cfgAddExecutionProvider(self, ep: cv2.gapi.onnx.ep.CoreML) -> PyParams: ...
  28. @_typing.overload
  29. def cfgAddExecutionProvider(self, ep: cv2.gapi.onnx.ep.CUDA) -> PyParams: ...
  30. @_typing.overload
  31. def cfgAddExecutionProvider(self, ep: cv2.gapi.onnx.ep.TensorRT) -> PyParams: ...
  32. def cfgDisableMemPattern(self) -> PyParams: ...
  33. def cfgSessionOptions(self, options: cv2.typing.map_string_and_string) -> PyParams: ...
  34. def cfgOptLevel(self, opt_level: int) -> PyParams: ...
  35. # Functions
  36. def params(tag: str, model_path: str) -> PyParams: ...