Shakerato

pytorch code bottleneck analysis 본문

Research

pytorch code bottleneck analysis

Shakeratto 2021. 5. 26. 14:36

파이토치 개발 후 코드의 어느 부분에서 계산에 많은 시간이 소요되는지 분석하고,

이를 통해 코드 성능을 향상하는데 도움이됨

 

python -m torch.utils.bottleneck /path/to/source/script.py [args]

 

Reference: https://pytorch.org/docs/stable/bottleneck.html

 

torch.utils.bottleneck — PyTorch 1.8.1 documentation

torch.utils.bottleneck torch.utils.bottleneck is a tool that can be used as an initial step for debugging bottlenecks in your program. It summarizes runs of your script with the Python profiler and PyTorch’s autograd profiler. Run it on the command line

pytorch.org

 

Comments