Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,14 @@ def __post_init__(self):
"""Check the validity of the config."""
if self.reuse_grad_buf_for_mxfp8_param_ag:
assert self.fp8_param_gather, "Reuse grad buffer only when keeping params in MXFP8."
# Using mxfp8 param without overlap param gather and overlap grad reduce will cause NaN.
# TODO: Remove this assertion when the issue is fixed.
assert (
self.overlap_param_gather
), "--overlap-param-gather is required when using mxfp8 params"
assert (
self.overlap_grad_reduce
), "--overlap-grad-reduce is required when using mxfp8 params"

if self.nccl_ub:
if 'expandable_segments:True' in os.getenv('PYTORCH_CUDA_ALLOC_CONF', '').split(','):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,14 @@ def __post_init__(self):
"""Check the validity of the config."""
if self.reuse_grad_buf_for_mxfp8_param_ag:
assert self.fp8_param_gather, "Reuse grad buffer only when keeping params in MXFP8."
# Using mxfp8 param without overlap param gather and overlap grad reduce will cause NaN.
# TODO: Remove this assertion when the issue is fixed.
assert (
self.overlap_param_gather
), "--overlap-param-gather is required when using mxfp8 params"
assert (
self.overlap_grad_reduce
), "--overlap-grad-reduce is required when using mxfp8 params"

if self.nccl_ub:
if 'expandable_segments:True' in os.getenv('PYTORCH_CUDA_ALLOC_CONF', '').split(','):
Expand Down