Skip to content

Commit

Permalink
[wenet/bin/train.py] add barrier before destory process group (#2590)
Browse files Browse the repository at this point in the history
Co-authored-by: tianyukun <tianyukun@cambricon.com>
  • Loading branch information
scshtyk and tianyukun authored Aug 6, 2024
1 parent ec3d80f commit bc58f83
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions wenet/bin/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,8 @@ def main():
final_model_path) else None
os.symlink('{}.pt'.format(final_epoch), final_model_path)
writer.close()
dist.barrier(
) # NOTE(yktian): Ensure all ranks end Train before destroy process group.
dist.destroy_process_group()


Expand Down

0 comments on commit bc58f83

Please sign in to comment.