Check dyno and dcgm existence before disable them (#2496)
Summary:
For systems without dyno or dcgm installed and running without sudo, the `ncu_rep` metric will get stuck asking for a sudo password.
This PR checks the command or service existence before disabling them to avoid getting stuck.
Pull Request resolved: https://github.com/pytorch/benchmark/pull/2496
Reviewed By: xuzhao9
Differential Revision: D64141793
Pulled By: FindHao
fbshipit-source-id: 8d52468f04e7e5a0e8d23f3562a14c83d4a5934c