Skip to content
Open
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
10 changes: 9 additions & 1 deletion transformer_engine/jax/cpp_extensions/gemm.py
Original file line number Diff line number Diff line change
Expand Up @@ -936,7 +936,15 @@ def _parse_operand_output_specs(

# Non-contracting dims of RHS always needs to be gathered along the FSDP axis
rhs_non_cspecs = tuple(
None if spec is not None and spec == gsr.fsdp_resource else spec
(
None
if spec is not None
and (
spec == gsr.fsdp_resource
or (isinstance(spec, tuple) and gsr.fsdp_resource in spec)
)
else spec
)
for spec in rhs_non_cspecs
)

Expand Down
Loading