Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jan 16, 2025
1 parent a1d810e commit 67c3c28
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions transformer_engine/pytorch/module/linear.py
Original file line number Diff line number Diff line change
Expand Up @@ -568,9 +568,7 @@ def backward(ctx, grad_output: torch.Tensor) -> Tuple[Union[torch.Tensor, None],
if dgrad is None:
if ctx.parallel_mode == "column" and ctx.sequence_parallel:
dgrad_shape[0] = dgrad_shape[0] * tp_world_size
dgrad = torch.empty(
dgrad_shape, dtype=output_dtype, device=grad_output.device
)
dgrad = torch.empty(dgrad_shape, dtype=output_dtype, device=grad_output.device)

if ctx.requires_dgrad:
if ctx.fp8:
Expand Down

0 comments on commit 67c3c28

Please sign in to comment.