_utils_impl.pyi 724 B

12345678910111213141516171819202122
  1. from _typeshed import SupportsWrite
  2. from typing import LiteralString
  3. from typing_extensions import TypeVar
  4. import numpy as np
  5. __all__ = ["get_include", "info", "show_runtime"]
  6. _ScalarOrArrayT = TypeVar("_ScalarOrArrayT", bound=np.generic | np.ndarray)
  7. _DTypeT = TypeVar("_DTypeT", bound=np.dtype)
  8. ###
  9. def get_include() -> LiteralString: ...
  10. def show_runtime() -> None: ...
  11. def info(
  12. object: object = None, maxwidth: int = 76, output: SupportsWrite[str] | None = None, toplevel: str = "numpy"
  13. ) -> None: ...
  14. def drop_metadata(dtype: _DTypeT, /) -> _DTypeT: ...
  15. # used internally by `lib._function_base_impl._median`
  16. def _median_nancheck(data: np.ndarray, result: _ScalarOrArrayT, axis: int) -> _ScalarOrArrayT: ...