Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explicitly check for None when using prefill attn_mask #983

Merged
merged 1 commit into from
Feb 19, 2025

Conversation

stbaione
Copy link
Contributor

When you attempt to implicitly null-check the attention_mask, you hit a torch error:

RuntimeError: Cannot call numel() on tensor with symbolic sizes/strides

Simply adding an explicit check for null fixes it, and the --use-attention-mask export path for prefill

@stbaione stbaione added the bug Something isn't working label Feb 19, 2025
@stbaione stbaione requested a review from rsuderman February 19, 2025 17:05
@stbaione stbaione merged commit 8b41015 into nod-ai:main Feb 19, 2025
34 of 36 checks passed
IanNod pushed a commit that referenced this pull request Feb 22, 2025
When you attempt to implicitly null-check the attention_mask, you hit a
torch error:

```bash
RuntimeError: Cannot call numel() on tensor with symbolic sizes/strides
```

Simply adding an explicit check for null fixes it, and the
`--use-attention-mask` export path for prefill
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants