xref: /aosp_15_r20/external/pytorch/torch/_C/_lazy.pyi (revision da0073e96a02ea20f0ac840b70461e3646d07c45)
1# mypy: allow-untyped-defs
2from torch import Tensor
3
4# defined in torch/csrc/lazy/python/init.cpp
5def _mark_step(device: str, devices: list[str], wait: bool): ...
6def _wait_device_ops(devices: list[str]): ...
7def _reset_metrics(): ...
8def _counter_names() -> list[str]: ...
9def _counter_value(name: str) -> int: ...
10def _metrics_report() -> str: ...
11def _get_graph_hash(tensors: list[Tensor]) -> str: ...
12def _sync_multi(
13    tensors: list[Tensor],
14    devices: list[str],
15    wait: bool = True,
16    sync_ltc_data: bool = True,
17): ...
18def _get_tensor_id(tensor: Tensor) -> int: ...
19def _get_tensors_text(tensors: list[Tensor]) -> str: ...
20def _get_tensors_dot(tensors: list[Tensor]) -> str: ...
21def _get_tensors_backend(tensors: list[Tensor]) -> str: ...
22def _get_force_fallback() -> str: ...
23def _set_force_fallback(newval: str): ...
24def _clear_ir_cache(): ...
25def _dump_ir_cache(filename: str): ...
26def _set_reuse_ir(val: bool): ...
27def _get_default_device_type(): ...
28