pytorch/docs
albanD 76a26a885d Add module tracker (#125352)
This does a few things that were originally a few PRs but I am on a new machine and don't have ghstack.
If it is too problematic to review, I can re-split, just let me know.
This does:
- Cleanup context manager use in test_flop_counter
- Remove need for mod argument in FlopCounterMode, warning about it
- Re-implement a Module tracker from scratch using global forward Module use and multi_grad_hook (we cannot use global backward Module hook because they don't look for nested Tensor and they're custom Function based instead of multi_grad_hook).
- Update FlopCouterMode to use the new ModuleTracker. All the existing test suite passes as-is (only changes there are new tests and refactoring mentioned above)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/125352
Approved by: https://github.com/mikaylagawarecki
2024-05-04 18:33:35 +00:00
..
caffe2 Enable UFMT on a bunch of low traffic Python files outside of main files (#106052) 2023-07-27 01:01:17 +00:00
cpp Update Jinja to 3.1.3 (#124976) 2024-04-26 02:57:55 +00:00
source Add module tracker (#125352) 2024-05-04 18:33:35 +00:00
.gitignore
libtorch.rst
make.bat
Makefile Refactor torch.onnx documentation (#108379) 2023-09-08 18:23:48 +00:00
README.md
requirements.txt

Please see the Writing documentation section of CONTRIBUTING.md for details on both writing and building the docs.