Skip to content

Enabling var_mean decomposition #2273

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

Merged
merged 2 commits into from
Aug 31, 2023
Merged
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
4 changes: 2 additions & 2 deletions py/torch_tensorrt/dynamo/lowering/_decomposition_groups.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,7 @@
aten.renorm,
aten.renorm_,
aten.rot90,
aten.rsub.Scalar,
aten.rsub.Tensor,
aten.rsub,
aten.select_backward,
aten.select_scatter,
aten.sgn,
Expand Down Expand Up @@ -175,6 +174,7 @@
aten.linalg_vector_norm,
aten.full,
aten.repeat,
aten.var_mean,
Copy link
Collaborator Author

@apbose apbose Aug 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gs-olive you mentioned the rsub. I will add that.
Regarding sqrt and rsqrt, sqrt is not of lowering type so I don't think it should be included here.
For rsqrt, should I include it here? Since rsqrt is already present in py/torch_tensorrt/dynamo/lowering/_decompositions.py and that would take precedence over the enabled ones, right? And we would not need to add it to the disabled ops then.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is true, I agree with your points. I think the rsub would be the main one to change; we can leave the others out, and the rsqrt implementation in _decompositions.py will take precedence, yes.

}
torch_disabled_decompositions: Set[Union[OpOverload, OpOverloadPacket]] = {
aten._softmax.default,
Expand Down