mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
[RFC] Make fr trace script a console scripts (#134729)
We want to make fr analyzer script a command after users `pip install torch`, that's why we want to mimic what torchrun is doing. Pull Request resolved: https://github.com/pytorch/pytorch/pull/134729 Approved by: https://github.com/c-p-i-o, https://github.com/malfet ghstack dependencies: #134528, #134780
This commit is contained in:
6
setup.py
6
setup.py
@ -1103,6 +1103,12 @@ def configure_extension_build():
|
||||
"default = torch.distributed.elastic.multiprocessing:DefaultLogsSpecs",
|
||||
],
|
||||
}
|
||||
|
||||
if cmake_cache_vars["USE_DISTRIBUTED"]:
|
||||
# Only enable fr_trace command if distributed is enabled
|
||||
entry_points["console_scripts"].append(
|
||||
"torchfrtrace = tools.flight_recorder.fr_trace:main",
|
||||
)
|
||||
return extensions, cmdclass, packages, entry_points, extra_install_requires
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user