(pytorch_api)=
# Reference API

```{toctree}
:maxdepth: 1

C++ <https://docs.pytorch.org/cppdocs/>
```

```{toctree}
:glob:
:maxdepth: 1
:caption: Python API

torch
nn
nn.functional
tensors
tensor_attributes
tensor_view
torch.amp <amp>
torch.autograd <autograd>
torch.library <library>
accelerator
cpu
cuda
torch.cuda.memory <torch_cuda_memory>
mps
xpu
mtia
mtia.memory
mtia.mtia_graph
meta
torch.backends <backends>
torch.export <user_guide/torch_compiler/export>
torch.distributed <distributed>
torch.distributed.tensor <distributed.tensor>
torch.distributed.algorithms.join <distributed.algorithms.join>
torch.distributed.elastic <distributed.elastic>
torch.distributed.fsdp <fsdp>
torch.distributed.fsdp.fully_shard <distributed.fsdp.fully_shard>
torch.distributed.tensor.parallel <distributed.tensor.parallel>
torch.distributed.optim <distributed.optim>
torch.distributed.pipelining <distributed.pipelining>
torch.distributed._symmetric_memory <symmetric_memory>
torch.distributed.checkpoint <distributed.checkpoint>
torch.distributions <distributions>
torch.compiler <torch.compiler_api>
torch.fft <fft>
torch.func <func>
futures
fx
fx.experimental
torch.hub <hub>
torch.linalg <linalg>
torch.monitor <monitor>
torch.signal <signal>
torch.special <special>
torch.overrides
torch.nativert <nativert>
torch.package <package>
profiler
nn.init
nn.attention
onnx
optim
complex_numbers
ddp_comm_hooks
quantization
rpc
torch.random <random>
masked
torch.nested <nested>
size
sparse
storage
torch.testing <testing>
torch.utils <utils>
torch.utils.benchmark <benchmark_utils>
torch.utils.checkpoint <checkpoint>
torch.utils.cpp_extension <cpp_extension>
torch.utils.data <data>
torch.utils.deterministic <deterministic>
torch.utils.jit <jit_utils>
torch.utils.dlpack <dlpack>
torch.utils.mobile_optimizer <mobile_optimizer>
torch.utils.model_zoo <model_zoo>
torch.utils.tensorboard <tensorboard>
torch.utils.module_tracker <module_tracker>
type_info
named_tensor
name_inference
torch.__config__ <config_mod>
torch.__future__ <future_mod>
logging
torch_environment_variables
```
