From 642d58b32cf5776a0e4c25f12ab2c53440beee34 Mon Sep 17 00:00:00 2001 From: Avasam Date: Tue, 30 Aug 2022 20:49:30 -0400 Subject: [PATCH] Unused imports --- stubs/D3DShot/d3dshot/capture_output.pyi | 15 ++++--- .../capture_outputs/numpy_capture_output.pyi | 13 +++--- .../numpy_float_capture_output.pyi | 13 +++--- .../capture_outputs/pil_capture_output.pyi | 4 +- .../pytorch_capture_output.pyi | 15 ++++--- .../pytorch_float_capture_output.pyi | 15 ++++--- .../pytorch_float_gpu_capture_output.pyi | 18 ++++---- .../pytorch_gpu_capture_output.pyi | 19 +++++---- stubs/D3DShot/d3dshot/d3dshot.pyi | 20 ++++----- stubs/D3DShot/d3dshot/display.pyi | 12 +++--- stubs/D3DShot/d3dshot/dll/d3d.pyi | 17 ++++---- stubs/D3DShot/d3dshot/dll/dxgi.pyi | 41 +++++++++---------- stubs/D3DShot/d3dshot/dll/user32.pyi | 4 +- 13 files changed, 113 insertions(+), 93 deletions(-) diff --git a/stubs/D3DShot/d3dshot/capture_output.pyi b/stubs/D3DShot/d3dshot/capture_output.pyi index e5078d83289c..d9d654d505c2 100644 --- a/stubs/D3DShot/d3dshot/capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_output.pyi @@ -1,13 +1,12 @@ import enum from _typeshed import Incomplete -from typing import Any from typing_extensions import TypeAlias from PIL.Image import Image -Frame: TypeAlias = Any -# Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | torch.Tensor -Pointer: TypeAlias = Incomplete +_Frame: TypeAlias = Incomplete +# _Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | _Tensor +_Pointer: TypeAlias = Incomplete class CaptureOutputs(enum.Enum): PIL: int @@ -24,7 +23,7 @@ class CaptureOutput: backend: CaptureOutput def __init__(self, backend: CaptureOutputs = ...) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int - ) -> Frame: ... - def to_pil(self, frame: Frame) -> Image: ... - def stack(self, frames: list[Frame], stack_dimension) -> Frame: ... + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + ) -> _Frame: ... + def to_pil(self, frame: _Frame) -> Image: ... + def stack(self, frames: list[_Frame], stack_dimension) -> _Frame: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/numpy_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/numpy_capture_output.pyi index 494591aa632f..656e69bac140 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/numpy_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/numpy_capture_output.pyi @@ -1,18 +1,21 @@ from _typeshed import Incomplete from typing_extensions import TypeAlias -import numpy as np -import numpy.typing as npt from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete -NDArray: TypeAlias = npt.NDArray[np.int32] +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# import numpy as np +# import numpy.typing as npt +# NDArray: TypeAlias = npt.NDArray[np.int32] +NDArray: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class NumpyCaptureOutput(CaptureOutput): def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int ) -> NDArray: ... def to_pil(self, frame: NDArray) -> Image: ... def stack(self, frames: list[NDArray] | NDArray, stack_dimension: int) -> NDArray: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/numpy_float_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/numpy_float_capture_output.pyi index 3202aedcbee1..734e489b29ac 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/numpy_float_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/numpy_float_capture_output.pyi @@ -1,18 +1,21 @@ from _typeshed import Incomplete from typing_extensions import TypeAlias -import numpy as np -import numpy.typing as npt from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete -NDArray: TypeAlias = npt.NDArray[np.float32] +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# import numpy as np +# import numpy.typing as npt +# NDArray: TypeAlias = npt.NDArray[np.float32] +NDArray: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class NumpyFloatCaptureOutput(CaptureOutput): def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int ) -> NDArray: ... def to_pil(self, frame: NDArray) -> Image: ... def stack(self, frames: list[NDArray] | NDArray, stack_dimension: int) -> NDArray: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/pil_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/pil_capture_output.pyi index 0b37fe111d54..8c13fa23c8f2 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/pil_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/pil_capture_output.pyi @@ -4,12 +4,12 @@ from typing_extensions import TypeAlias from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class PILCaptureOutput(CaptureOutput): def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int ) -> Image: ... def to_pil(self, frame: Image) -> Image: ... def stack(self, frames: list[Image], stack_dimension: int) -> list[Image]: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_capture_output.pyi index 405ad2f12ec9..f36166f3b871 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_capture_output.pyi @@ -1,16 +1,19 @@ from _typeshed import Incomplete from typing_extensions import TypeAlias -import torch from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# from torch import Tensor +_Tensor: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class PytorchCaptureOutput(CaptureOutput): def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int - ) -> torch.Tensor: ... - def to_pil(self, frame: torch.Tensor) -> Image: ... - def stack(self, frames: list[torch.Tensor], stack_dimension: int) -> torch.Tensor: ... + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + ) -> _Tensor: ... + def to_pil(self, frame: _Tensor) -> Image: ... + def stack(self, frames: list[_Tensor], stack_dimension: int) -> _Tensor: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_capture_output.pyi index 0a065702d9cd..ef9c93c0e005 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_capture_output.pyi @@ -1,16 +1,19 @@ from _typeshed import Incomplete from typing_extensions import TypeAlias -import torch from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# from torch import Tensor +_Tensor: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class PytorchFloatCaptureOutput(CaptureOutput): def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int - ) -> torch.Tensor: ... - def to_pil(self, frame: torch.Tensor) -> Image: ... - def stack(self, frames: list[torch.Tensor], stack_dimension: int) -> torch.Tensor: ... + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + ) -> _Tensor: ... + def to_pil(self, frame: _Tensor) -> Image: ... + def stack(self, frames: list[_Tensor], stack_dimension: int) -> _Tensor: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_gpu_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_gpu_capture_output.pyi index 8fef57d3782e..69a9eadc6641 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_gpu_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_float_gpu_capture_output.pyi @@ -1,17 +1,21 @@ from _typeshed import Incomplete from typing_extensions import TypeAlias -import torch from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# from torch import device, Tensor +_Tensor: TypeAlias = Incomplete +_device: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class PytorchFloatGPUCaptureOutput(CaptureOutput): - device: Incomplete + device: _device def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int - ) -> torch.Tensor: ... - def to_pil(self, frame: torch.Tensor) -> Image: ... - def stack(self, frames: list[torch.Tensor], stack_dimension: int) -> torch.Tensor: ... + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + ) -> _Tensor: ... + def to_pil(self, frame: _Tensor) -> Image: ... + def stack(self, frames: list[_Tensor], stack_dimension: int) -> _Tensor: ... diff --git a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_gpu_capture_output.pyi b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_gpu_capture_output.pyi index ff1d3e71ba9d..2e1f3f66eec1 100644 --- a/stubs/D3DShot/d3dshot/capture_outputs/pytorch_gpu_capture_output.pyi +++ b/stubs/D3DShot/d3dshot/capture_outputs/pytorch_gpu_capture_output.pyi @@ -1,17 +1,22 @@ from _typeshed import Incomplete from typing_extensions import TypeAlias -import torch from d3dshot.capture_output import CaptureOutput as CaptureOutput from PIL.Image import Image -Pointer: TypeAlias = Incomplete +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# from torch import device, Tensor +_Tensor: TypeAlias = Incomplete +_device: TypeAlias = Incomplete + +_Pointer: TypeAlias = Incomplete class PytorchGPUCaptureOutput(CaptureOutput): - device: torch.device + device: _device def __init__(self) -> None: ... def process( - self, pointer: Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int - ) -> torch.Tensor: ... - def to_pil(self, frame: torch.Tensor) -> Image: ... - def stack(self, frames: list[torch.Tensor], stack_dimension: int): ... + self, pointer: _Pointer, size: int, width: int, height: int, region: tuple[int, int, int, int], rotation: int + ) -> _Tensor: ... + def to_pil(self, frame: _Tensor) -> Image: ... + def stack(self, frames: list[_Tensor], stack_dimension: int): ... diff --git a/stubs/D3DShot/d3dshot/d3dshot.pyi b/stubs/D3DShot/d3dshot/d3dshot.pyi index 9bee4770ed60..6eefd855b620 100644 --- a/stubs/D3DShot/d3dshot/d3dshot.pyi +++ b/stubs/D3DShot/d3dshot/d3dshot.pyi @@ -1,20 +1,20 @@ +from _typeshed import Incomplete from collections import deque -from typing import Any from typing_extensions import TypeAlias from d3dshot.capture_output import CaptureOutput as CaptureOutput, CaptureOutputs as CaptureOutputs from d3dshot.display import Display as Display -Frame: TypeAlias = Any -# Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | torch.Tensor +_Frame: TypeAlias = Incomplete +# _Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | _Tensor class D3DShot: displays: list[Display] display: Display capture_output: CaptureOutput frame_buffer_size: int - frame_buffer: deque[Frame] - previous_screenshot: Frame | None + frame_buffer: deque[_Frame] + previous_screenshot: _Frame | None region: tuple[int, int, int, int] | None def __init__( @@ -28,11 +28,11 @@ class D3DShot: ) -> None: ... @property def is_capturing(self) -> bool: ... - def get_latest_frame(self) -> Frame | None: ... - def get_frame(self, frame_index: int) -> Frame | None: ... - def get_frames(self, frame_indices: list[int]) -> list[Frame]: ... - def get_frame_stack(self, frame_indices: list[int], stack_dimension: str | None = ...) -> Frame: ... - def screenshot(self, region: tuple[int, int, int, int] | None = ...) -> Frame | None: ... + def get_latest_frame(self) -> _Frame | None: ... + def get_frame(self, frame_index: int) -> _Frame | None: ... + def get_frames(self, frame_indices: list[int]) -> list[_Frame]: ... + def get_frame_stack(self, frame_indices: list[int], stack_dimension: str | None = ...) -> _Frame: ... + def screenshot(self, region: tuple[int, int, int, int] | None = ...) -> _Frame | None: ... def screenshot_to_disk( self, directory: str | None = ..., file_name: str | None = ..., region: tuple[int, int, int, int] | None = ... ) -> str: ... diff --git a/stubs/D3DShot/d3dshot/display.pyi b/stubs/D3DShot/d3dshot/display.pyi index f81ff3d0d4dd..a237d6fe496e 100644 --- a/stubs/D3DShot/d3dshot/display.pyi +++ b/stubs/D3DShot/d3dshot/display.pyi @@ -1,11 +1,11 @@ from _typeshed import Incomplete from collections.abc import Callable -from typing import Any, Literal +from typing import Literal from typing_extensions import TypeAlias -Frame: TypeAlias = Any -# Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | torch.Tensor -Pointer: TypeAlias = Incomplete +_Frame: TypeAlias = Incomplete +# _Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | _Tensor +_Pointer: TypeAlias = Incomplete class Display: name: str @@ -38,8 +38,8 @@ class Display: def capture( self, # Incomplete: dxgi_mapped_rect.pBits - process_func: Callable[[Pointer, int, int, int, tuple[int, int, int, int], int], Frame | None] | None, + process_func: Callable[[_Pointer, int, int, int, tuple[int, int, int, int], int], _Frame | None] | None, region: tuple[int, int, int, int] = ..., - ) -> Frame: ... + ) -> _Frame: ... @classmethod def discover_displays(cls) -> list[Display]: ... diff --git a/stubs/D3DShot/d3dshot/dll/d3d.pyi b/stubs/D3DShot/d3dshot/dll/d3d.pyi index 438e18bc677c..0ef566ff7fbe 100644 --- a/stubs/D3DShot/d3dshot/dll/d3d.pyi +++ b/stubs/D3DShot/d3dshot/dll/d3d.pyi @@ -2,19 +2,22 @@ import ctypes from _typeshed import Incomplete from typing_extensions import TypeAlias -import comtypes +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# import comtypes +_IUnknown: TypeAlias = Incomplete -Pointer: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class DXGI_SAMPLE_DESC(ctypes.Structure): ... class D3D11_BOX(ctypes.Structure): ... class D3D11_TEXTURE2D_DESC(ctypes.Structure): ... -class ID3D11DeviceChild(comtypes.IUnknown): ... +class ID3D11DeviceChild(_IUnknown): ... class ID3D11Resource(ID3D11DeviceChild): ... class ID3D11Texture2D(ID3D11Resource): ... class ID3D11DeviceContext(ID3D11DeviceChild): ... -class ID3D11Device(comtypes.IUnknown): ... +class ID3D11Device(_IUnknown): ... -def initialize_d3d_device(dxgi_adapter: Pointer) -> tuple[Pointer, Pointer]: ... -def describe_d3d11_texture_2d(d3d11_texture_2d: Pointer) -> D3D11_TEXTURE2D_DESC: ... -def prepare_d3d11_texture_2d_for_cpu(d3d11_texture_2d: Pointer, d3d_device: Pointer) -> Pointer: ... +def initialize_d3d_device(dxgi_adapter: _Pointer) -> tuple[_Pointer, _Pointer]: ... +def describe_d3d11_texture_2d(d3d11_texture_2d: _Pointer) -> D3D11_TEXTURE2D_DESC: ... +def prepare_d3d11_texture_2d_for_cpu(d3d11_texture_2d: _Pointer, d3d_device: _Pointer) -> _Pointer: ... diff --git a/stubs/D3DShot/d3dshot/dll/dxgi.pyi b/stubs/D3DShot/d3dshot/dll/dxgi.pyi index 63c235baf6be..eb7bcccc2d91 100644 --- a/stubs/D3DShot/d3dshot/dll/dxgi.pyi +++ b/stubs/D3DShot/d3dshot/dll/dxgi.pyi @@ -1,20 +1,17 @@ import ctypes from _typeshed import Incomplete from collections.abc import Callable -from typing import Any from typing_extensions import TypeAlias -import comtypes -from d3dshot.dll.d3d import ( - ID3D11Device as ID3D11Device, - ID3D11DeviceContext as ID3D11DeviceContext, - ID3D11Texture2D as ID3D11Texture2D, - prepare_d3d11_texture_2d_for_cpu as prepare_d3d11_texture_2d_for_cpu, -) +# TODO: Complete types once we can import non-types dependencies +# See: https://github.com/python/typeshed/issues/5768 +# from torch import Tensor +# import comtypes +_IUnknown: TypeAlias = Incomplete -Frame: TypeAlias = Any -# Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | torch.Tensor -Pointer: TypeAlias = Incomplete +_Frame: TypeAlias = Incomplete +# _Frame: TypeAlias = Image | npt.NDArray[np.int32] | npt.NDArray[np.float32] | Tensor +_Pointer: TypeAlias = Incomplete class LUID(ctypes.Structure): ... class DXGI_ADAPTER_DESC1(ctypes.Structure): ... @@ -22,7 +19,7 @@ class DXGI_OUTPUT_DESC(ctypes.Structure): ... class DXGI_OUTDUPL_POINTER_POSITION(ctypes.Structure): ... class DXGI_OUTDUPL_FRAME_INFO(ctypes.Structure): ... class DXGI_MAPPED_RECT(ctypes.Structure): ... -class IDXGIObject(comtypes.IUnknown): ... +class IDXGIObject(_IUnknown): ... class IDXGIDeviceSubObject(IDXGIObject): ... class IDXGIResource(IDXGIDeviceSubObject): ... class IDXGISurface(IDXGIDeviceSubObject): ... @@ -34,18 +31,18 @@ class IDXGIAdapter1(IDXGIAdapter): ... class IDXGIFactory(IDXGIObject): ... class IDXGIFactory1(IDXGIFactory): ... -def initialize_dxgi_factory() -> Pointer: ... # ctypes.POINTER(IDXGIFactory1)(handle.value) -def discover_dxgi_adapters(dxgi_factory: Pointer) -> list[Pointer]: ... -def describe_dxgi_adapter(dxgi_adapter: Pointer) -> Pointer: ... -def discover_dxgi_outputs(dxgi_adapter: Pointer) -> list[Pointer]: ... -def describe_dxgi_output(dxgi_output: Pointer) -> Pointer: ... -def initialize_dxgi_output_duplication(dxgi_output: Pointer, d3d_device: Pointer) -> Pointer: ... +def initialize_dxgi_factory() -> _Pointer: ... # ctypes.POINTER(IDXGIFactory1)(handle.value) +def discover_dxgi_adapters(dxgi_factory: _Pointer) -> list[_Pointer]: ... +def describe_dxgi_adapter(dxgi_adapter: _Pointer) -> _Pointer: ... +def discover_dxgi_outputs(dxgi_adapter: _Pointer) -> list[_Pointer]: ... +def describe_dxgi_output(dxgi_output: _Pointer) -> _Pointer: ... +def initialize_dxgi_output_duplication(dxgi_output: _Pointer, d3d_device: _Pointer) -> _Pointer: ... def get_dxgi_output_duplication_frame( - dxgi_output_duplication: Pointer, - d3d_device: Pointer, - process_func: Callable[[Pointer, int, int, int, tuple[int, int, int, int], int], Frame | None] | None = ..., + dxgi_output_duplication: _Pointer, + d3d_device: _Pointer, + process_func: Callable[[_Pointer, int, int, int, tuple[int, int, int, int], int], _Frame | None] | None = ..., width: int = ..., height: int = ..., region: tuple[int, int, int, int] | None = ..., rotation: int = ..., -) -> Frame: ... +) -> _Frame: ... diff --git a/stubs/D3DShot/d3dshot/dll/user32.pyi b/stubs/D3DShot/d3dshot/dll/user32.pyi index 15a34fd38c33..96523dc7e0a4 100644 --- a/stubs/D3DShot/d3dshot/dll/user32.pyi +++ b/stubs/D3DShot/d3dshot/dll/user32.pyi @@ -2,9 +2,9 @@ import ctypes from _typeshed import Incomplete from typing_extensions import TypeAlias -Pointer: TypeAlias = Incomplete +_Pointer: TypeAlias = Incomplete class DISPLAY_DEVICE(ctypes.Structure): ... def get_display_device_name_mapping() -> dict[str, tuple[str, bool]]: ... -def get_hmonitor_by_point(x: int, y: int) -> Pointer: ... # ctypes.windll.user32.MonitorFromPoint(point, 0) +def get_hmonitor_by_point(x: int, y: int) -> _Pointer: ... # ctypes.windll.user32.MonitorFromPoint(point, 0)