Skip to content

Preserve FP32 attention scores through softmax for CUDA alignments - #2143

Merged
jordimas merged 5 commits into
OpenNMT:masterfrom
jordimas:fix/cuda-attention-fp32-scores
Nov 1, 2026
Merged

jordimas merged 5 commits into
OpenNMT:masterfrom
jordimas:fix/cuda-attention-fp32-scores

Conversation

@jordimas

@jordimas jordimas commented Oct 31, 2026 •

Copy link
Copy Markdown
Collaborator

Fixes #2132. Preserve FP32 attention scores through softmax for FP16/BF16 CUDA alignments. ROCm tests: 197 passed, three skipped. Adds conversion overhead; NVIDIA validation pending.

@jordimas
jordimas merged commit e073f63 into OpenNMT:master Nov 1, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

return_attention on CUDA float16: scores are rounded to fp16 before the softmax, so close candidates tie

1 participant