Name | Date | Size | #Lines | LOC | ||
---|---|---|---|---|---|---|
.. | - | - | ||||
alerts/ | 04-Jul-2025 | - | 322 | 258 | ||
amd_build/ | 04-Jul-2025 | - | 216 | 176 | ||
autograd/ | 04-Jul-2025 | - | 13,363 | 10,116 | ||
bazel_tools/ | 04-Jul-2025 | - | 65 | 38 | ||
build/bazel/ | 04-Jul-2025 | - | 231 | 228 | ||
build_defs/ | 04-Jul-2025 | - | 426 | 318 | ||
code_analyzer/ | 04-Jul-2025 | - | 923 | 663 | ||
code_coverage/ | 04-Jul-2025 | - | 1,712 | 1,289 | ||
config/ | 04-Jul-2025 | - | 108 | 87 | ||
coverage_plugins_package/ | 04-Jul-2025 | - | 122 | 87 | ||
dynamo/ | 04-Jul-2025 | - | 228 | 169 | ||
flight_recorder/ | 04-Jul-2025 | - | 1,319 | 1,063 | ||
gdb/ | 04-Jul-2025 | - | 59 | 44 | ||
github/ | 04-Jul-2025 | - | 83 | 69 | ||
iwyu/ | 04-Jul-2025 | - | 153 | 117 | ||
jit/ | 04-Jul-2025 | - | 395 | 315 | ||
linter/ | 04-Jul-2025 | - | 4,667 | 3,831 | ||
lite_interpreter/ | 04-Jul-2025 | - | 186 | 138 | ||
lldb/ | 04-Jul-2025 | - | 137 | 110 | ||
onnx/ | 04-Jul-2025 | - | 494 | 377 | ||
pyi/ | 04-Jul-2025 | - | 1,492 | 1,279 | ||
rules/ | 04-Jul-2025 | - | 108 | 96 | ||
rules_cc/ | 04-Jul-2025 | - | 81 | 76 | ||
setup_helpers/ | 04-Jul-2025 | - | 1,031 | 753 | ||
shared/ | 04-Jul-2025 | - | 36 | 26 | ||
stats/ | 04-Jul-2025 | - | 2,182 | 1,689 | ||
test/ | 04-Jul-2025 | - | 5,053 | 4,226 | ||
testing/ | 04-Jul-2025 | - | 2,539 | 1,942 | ||
BUCK.bzl | D | 04-Jul-2025 | 8 KiB | 305 | 282 | |
BUCK.oss | D | 04-Jul-2025 | 284 | 11 | 9 | |
README.md | D | 04-Jul-2025 | 2.6 KiB | 60 | 47 | |
__init__.py | D | 04-Jul-2025 | 0 | 1 | 0 | |
bazel.bzl | D | 04-Jul-2025 | 1.3 KiB | 40 | 35 | |
build_libtorch.py | D | 04-Jul-2025 | 1.1 KiB | 35 | 24 | |
build_pytorch_libs.py | D | 04-Jul-2025 | 3.3 KiB | 95 | 69 | |
build_with_debinfo.py | D | 04-Jul-2025 | 3.7 KiB | 119 | 89 | |
download_mnist.py | D | 04-Jul-2025 | 2.7 KiB | 95 | 78 | |
extract_scripts.py | D | 04-Jul-2025 | 3.1 KiB | 106 | 80 | |
gen_flatbuffers.sh | D | 04-Jul-2025 | 485 | 16 | 14 | |
gen_vulkan_spv.py | D | 04-Jul-2025 | 24.2 KiB | 769 | 586 | |
generate_torch_version.py | D | 04-Jul-2025 | 3.5 KiB | 107 | 85 | |
generated_dirs.txt | D | 04-Jul-2025 | 77 | 4 | 3 | |
git_add_generated_dirs.sh | D | 04-Jul-2025 | 353 | 14 | 2 | |
git_reset_generated_dirs.sh | D | 04-Jul-2025 | 357 | 14 | 2 | |
nightly.py | D | 04-Jul-2025 | 22.6 KiB | 715 | 573 | |
nvcc_fix_deps.py | D | 04-Jul-2025 | 3.3 KiB | 122 | 90 | |
render_junit.py | D | 04-Jul-2025 | 3.2 KiB | 108 | 87 | |
substitute.py | D | 04-Jul-2025 | 751 | 29 | 20 | |
update_masked_docs.py | D | 04-Jul-2025 | 1.6 KiB | 61 | 47 | |
vscode_settings.py | D | 04-Jul-2025 | 1.8 KiB | 67 | 47 |
README.md
1This folder contains a number of scripts which are used as 2part of the PyTorch build process. This directory also doubles 3as a Python module hierarchy (thus the `__init__.py`). 4 5## Overview 6 7Modern infrastructure: 8 9* [autograd](autograd) - Code generation for autograd. This 10 includes definitions of all our derivatives. 11* [jit](jit) - Code generation for JIT 12* [shared](shared) - Generic infrastructure that scripts in 13 tools may find useful. 14 * [module_loader.py](shared/module_loader.py) - Makes it easier 15 to import arbitrary Python files in a script, without having to add 16 them to the PYTHONPATH first. 17 18Build system pieces: 19 20* [setup_helpers](setup_helpers) - Helper code for searching for 21 third-party dependencies on the user system. 22* [build_pytorch_libs.py](build_pytorch_libs.py) - cross-platform script that 23 builds all of the constituent libraries of PyTorch, 24 but not the PyTorch Python extension itself. 25* [build_libtorch.py](build_libtorch.py) - Script for building 26 libtorch, a standalone C++ library without Python support. This 27 build script is tested in CI. 28 29Developer tools which you might find useful: 30 31* [git_add_generated_dirs.sh](git_add_generated_dirs.sh) and 32 [git_reset_generated_dirs.sh](git_reset_generated_dirs.sh) - 33 Use this to force add generated files to your Git index, so that you 34 can conveniently run diffs on them when working on code-generation. 35 (See also [generated_dirs.txt](generated_dirs.txt) which 36 specifies the list of directories with generated files.) 37 38Important if you want to run on AMD GPU: 39 40* [amd_build](amd_build) - HIPify scripts, for transpiling CUDA 41 into AMD HIP. Right now, PyTorch and Caffe2 share logic for how to 42 do this transpilation, but have separate entry-points for transpiling 43 either PyTorch or Caffe2 code. 44 * [build_amd.py](amd_build/build_amd.py) - Top-level entry 45 point for HIPifying our codebase. 46 47Tools which are only situationally useful: 48 49* [docker](docker) - Dockerfile for running (but not developing) 50 PyTorch, using the official conda binary distribution. Context: 51 https://github.com/pytorch/pytorch/issues/1619 52* [download_mnist.py](download_mnist.py) - Download the MNIST 53 dataset; this is necessary if you want to run the C++ API tests. 54 55[actions/github-script]: https://github.com/actions/github-script 56[flake8]: https://flake8.pycqa.org/en/latest/ 57[github actions expressions]: https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions#about-contexts-and-expressions 58[pytorch/add-annotations-github-action]: https://github.com/pytorch/add-annotations-github-action 59[shellcheck]: https://github.com/koalaman/shellcheck 60