ir_cache.py 348 B

1234567891011121314
  1. # mypy: allow-untyped-defs
  2. import torch._C._lazy
  3. def dump(dot_file_name: str):
  4. """Dump TrieCache in the dot format"""
  5. return torch._C._lazy._dump_ir_cache(dot_file_name)
  6. def reset():
  7. """Clear TrieCache. This is needed in testing to avoid
  8. node reusing between different tests.
  9. """
  10. return torch._C._lazy._clear_ir_cache()