Skip to content

Commit

Permalink
torchx - profile scheduler validate call (#972)
Browse files Browse the repository at this point in the history
Summary:

track torchx scheduler validate() call. Will capture elapse time and whether validation failed. There is no behavior impact to torchx users as this change only add logging for monitoring purpose

verified scuba log has the validate record:
https://fburl.com/scuba/pytorch_elastic_tsm_log/jza7f33n

Differential Revision: D66166216
  • Loading branch information
Tony Kao authored and facebook-github-bot committed Dec 9, 2024
1 parent cb0e457 commit 69bc841
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion torchx/runner/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,11 @@ def dryrun(
" Either a patch was built or no changes to workspace was detected."
)

sched._validate(app, scheduler)
with log_event(
"validate",
scheduler,
):
sched._validate(app, scheduler)
dryrun_info = sched.submit_dryrun(app, resolved_cfg)
dryrun_info._scheduler = scheduler
return dryrun_info
Expand Down

0 comments on commit 69bc841

Please sign in to comment.