Skip to content

add aten.sum.default#2807

Closed
copyrightly wants to merge 1 commit intopytorch:mainfrom
copyrightly:export-D55630993
Closed

add aten.sum.default#2807
copyrightly wants to merge 1 commit intopytorch:mainfrom
copyrightly:export-D55630993

Conversation

@copyrightly
Copy link
Copy Markdown
Contributor

Summary:
The operator aten.sum.dim_IntList could take an empty list as the parameter for dims. We modify vulkan_graph_builder.py to accommodate the empty list.

Moreover, the op aten.sum.default is implemented as a decomposition into aten.sum.dim_IntList with empty dims. So we will support aten.sum.default with the changes.

Context: torch.sum(x, ()) and torch.sum(x) are two ways to compute the sum of all elements in tensor x.

Differential Revision: D55630993

@pytorch-bot
Copy link
Copy Markdown

pytorch-bot Bot commented Apr 2, 2024

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/2807

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 New Failure

As of commit 79943ca with merge base 564c276 (image):

NEW FAILURE - The following job has failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Apr 2, 2024
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55630993

copyrightly added a commit to copyrightly/executorch that referenced this pull request Apr 2, 2024
Summary:

The operator `aten.sum.dim_IntList` could take an empty list as the parameter for `dims`. We modify `vulkan_graph_builder.py` to accommodate the empty list.

Moreover, the op `aten.sum.default` is implemented as a [decomposition](https://www.internalfb.com/code/fbsource/[96e496f9db8f92967b4394bd4f60e39ab916740b]/xplat/caffe2/torch/_decomp/decompositions.py?lines=4676) into `aten.sum.dim_IntList` with empty `dims`. So we will support `aten.sum.default` with the changes.

Context: `torch.sum(x, ())` and `torch.sum(x)` are two ways to compute the sum of all elements in tensor `x`.

Differential Revision: D55630993
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55630993

Summary:

The operator `aten.sum.dim_IntList` could take an empty list as the parameter for `dims`. We modify `vulkan_graph_builder.py` to accommodate the empty list.

Moreover, the op `aten.sum.default` is implemented as a [decomposition](https://www.internalfb.com/code/fbsource/[96e496f9db8f92967b4394bd4f60e39ab916740b]/xplat/caffe2/torch/_decomp/decompositions.py?lines=4676) into `aten.sum.dim_IntList` with empty `dims`. So we will support `aten.sum.default` with the changes.

Context: `torch.sum(x, ())` and `torch.sum(x)` are two ways to compute the sum of all elements in tensor `x`.

Reviewed By: SS-JIA, jorgep31415

Differential Revision: D55630993
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55630993

@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request has been merged in b145701.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants