-
Notifications
You must be signed in to change notification settings - Fork 7
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
broadcast_in_dim: The size of contiguity must equal to the number of non-broadcasting IterDomains #2549
Comments
This is likely related to the recent contiguity cleanup by @zasdfgbnm. |
I think it is an issue of the repro. The definition of contiguity has changed a few hours ago. Now broadcast dimensions do not have a contiguity and for a non-broadcast dimension, it is contiguous if and only if its stride equals My question for @IvanYashchuk is:
|
FYI: this is the PR that changes the definition of contiguity: #2517 |
It's generated from code, and we can change it. Thank you for clarifying what's going on, changing T0's contiguity to We should
|
Probably versioning is not strictly needed, the code generator should use the |
Alright here's the real problem, the code generator actually uses a different overload of from nvfuser import FusionDefinition, DataType
import torch
a = torch.ones(4, 1, dtype=torch.double, device='cuda')
b = torch.ones(4, 4, dtype=torch.double, device='cuda')
def nvfuser_fusion_id2(fd : FusionDefinition) -> None :
T0 = fd.define_tensor(sizes=a.shape, strides=a.stride(), dtype=DataType.Double, is_cpu=False)
T1 = fd.define_tensor(sizes=b.shape, strides=b.stride(), dtype=DataType.Double, is_cpu=False)
T2 = fd.ops.broadcast_in_dim(T0, output_shape=[4, 4], broadcast_dims=[0, 1])
T3 = fd.ops.div(T1, T2)
fd.add_output(T3)
# RuntimeError: The size of contiguity must equal to the number of non-broadcasting IterDomains
with FusionDefinition() as fd:
nvfuser_fusion_id2(fd)
print(fd.execute([a, b])) |
🐛 Describe the bug
Versions
devel
The text was updated successfully, but these errors were encountered: