-
Notifications
You must be signed in to change notification settings - Fork 685
[BE] Add selected custom ops to CI #11744
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,11 @@ | |
import torch | ||
import torch.nn.functional as F | ||
|
||
from .custom_ops import custom_ops_lib # noqa | ||
from executorch.extension.llm.custom_ops import custom_ops # noqa | ||
|
||
|
||
def is_fbcode(): | ||
return not hasattr(torch.version, "git_version") | ||
|
||
|
||
def _sdpa_with_kv_cache_ref(q, k, v, k_cache, v_cache, attn_mask, start_pos, seq_len): | ||
|
@@ -604,6 +608,9 @@ def test_sdpa_with_cache_seq_len_llava_example(self): | |
n_heads_kv, n_heads_q, head_dim, max_seq_len, seq_len, next_iter_seq_len | ||
) | ||
|
||
@unittest.skipIf( | ||
not is_fbcode(), "in OSS error is too large 0.0004 for some reason" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Let's enable in OSS. Otherwise we will never enable in OSS. We can finetune atol and rtol during comparison. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I am little reluctant on this because on one hand yes we can make it pass by tuning this knob, but on the other hand if there is an issue we wont catch it. My preference would be to have this test at least running internally without compromise. I dont know the reason as to why it requires low atol |
||
) | ||
def test_sdpa_with_cache_seq_len_130_gqa(self): | ||
n_heads_kv = 8 | ||
n_heads_q = 32 | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does ""in OSS error is too large 0.0002 for some reason" mean?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I ran this test in OSS error i got was 0.0002. Which is too large for this test to pass. It does pass internally so not sure if this is blas lib issue or mac vs linux. Bug I wanted to enable the tests in oss since we have to coverage otherwise