pytorch/torch/csrc/jit
Zhengxu Chen 1115a25c36 Add obc counter for TS migration. (#125986)
Summary: Since table caffe2_pytorch_usage_stats only has 1 day retention which renders it useless for TS migration purposes, we want to build a lightweight counter mechanism to collect usage data about torch jit APIs which can monitor the usage decline in the long term.

Test Plan: CI

Reviewed By: SherlockNoMad

Differential Revision: D57216847

Pull Request resolved: https://github.com/pytorch/pytorch/pull/125986
Approved by: https://github.com/gmagogsfm
2024-05-11 05:14:02 +00:00
..
api Refactor autocast C++ APIs to be device-agnostic (#124359) 2024-04-23 10:38:50 +00:00
backends
codegen
cuda
docs
frontend Revert "Verify types in custom op schemas (#124520)" 2024-04-26 08:42:11 +00:00
ir Revert "Verify types in custom op schemas (#124520)" 2024-04-26 08:42:11 +00:00
mobile
operator_upgraders
passes [onnx.export] Avoid linear look up in env for exist_in_env (#124909) 2024-05-09 22:38:00 +00:00
python Revert "Add write_record_metadata to PyTorchFileWriter (#125184)" 2024-05-05 22:40:00 +00:00
runtime make torch.amp.autocast more generic (#125103) 2024-05-08 12:13:26 +00:00
serialization Add obc counter for TS migration. (#125986) 2024-05-11 05:14:02 +00:00
tensorexpr
testing
jit_log.cpp
jit_log.h
jit_opt_limit.cpp
jit_opt_limit.h
JIT-AUTOCAST.md
OVERVIEW.md
README.md
resource_guard.h

PyTorch JIT

This folder contains (most of) the C++ code for the PyTorch JIT, a language and compiler stack for executing PyTorch models portably and efficiently. To learn more about the JIT from a user perspective, please consult our reference documentation and tutorials.

A brief summary of the source tree:

  • OVERVIEW.md: High-level technical overview of the JIT.
  • frontend/: Taking PyTorch modules in Python and translating them into the JIT IR.
  • ir/: Core IR abstractions.
  • runtime/: Interpreter, graph execution, and JIT operators.
  • codegen/: Generating efficient, hardware-specific code for JIT subgraphs.
  • serialization/: Saving and loading modules.
  • api/: Any user-facing C++ or Python interfaces.
  • python/: Binding stuff into Python or accessing information from the Python environment.
  • testing/: Utilities and helpers for testing.
  • mobile/: Mobile-specific implementations of runtime components.
  • passes/: IR-to-IR passes, generally for optimization and lowering.
  • generated/: This folder is generated by the PyTorch build, and contains bindings for native PyTorch operators into the JIT.

Refer to each folder for more in-depth documentation.

Other relevant parts of the codebase not contained here:

  • aten/src/ATen/core: contains JIT code re-used by other elements of the runtime system (eager, mobile, etc.)