[PyPer] Skip printing out per node time when do_profile is on (#63256)
authorHao Lu <hlu@fb.com>
Mon, 16 Aug 2021 23:30:53 +0000 (16:30 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Mon, 16 Aug 2021 23:32:19 +0000 (16:32 -0700)
commitaa63c0d9df54ea1fe65791143c8cee6b34cab4f2
tree4d8b1209d0df78837add111d2d0f139a9644442f
parentb2069e7d01814d776c417042e28133c6b0e5082f
[PyPer] Skip printing out per node time when do_profile is on (#63256)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/63256

This suppresses printing out the per node time which is very long when the net has too many ops. It can be easily turned on by setting `--pt_sr_print_per_node_time=1`.

Reviewed By: ajyu, mikeiovine

Differential Revision: D30298331

fbshipit-source-id: 32b3f93b3fe19d335654168311fda93331a1e706
torch/csrc/jit/runtime/static/impl.cpp
torch/csrc/jit/runtime/static/impl.h