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

[Pytorch] Add Vulkan support for aten::unsqueeze for 2d to 3d #101719

Closed
wants to merge 1 commit into from

Conversation

lucylq
Copy link
Contributor

@lucylq lucylq commented May 17, 2023

Summary: Unsqueeze operator: https://pytorch.org/docs/stable/generated/torch.unsqueeze.html#torch.unsqueeze

Test Plan:
Unsqueeze tests:
https://www.internalfb.com/phabricator/paste/view/P738187802

lfq@lfq-mbp fbsource % buck run --target-platforms ovr_config//platform/macos:arm64-fbsource //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64 -c pt.vulkan_full_precision=1 -- --gtest_filter="*unsqueeze*"
Downloaded 0/2 artifacts, 0.00 bytes, 100.0% cache miss (for updated rules)
Building: finished in 15.0 sec (100%) 455/455 jobs, 2/455 updated
  Total time: 15.0 sec
BUILD SUCCEEDED
Running main() from xplat/third-party/gmock/googletest-1.12.1/googletest/src/gtest_main.cc
Note: Google Test filter = *unsqueeze*
[==========] Running 3 tests from 1 test suite.
[----------] Global test environment set-up.
[----------] 3 tests from VulkanAPITest
[ RUN      ] VulkanAPITest.unsqueeze_dim0
[       OK ] VulkanAPITest.unsqueeze_dim0 (96 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim1
[       OK ] VulkanAPITest.unsqueeze_dim1 (2 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim2
[       OK ] VulkanAPITest.unsqueeze_dim2 (3 ms)
[----------] 3 tests from VulkanAPITest (101 ms total)
[----------] Global test environment tear-down
[==========] 3 tests from 1 test suite ran. (101 ms total)
[  PASSED  ] 3 tests.

All tests:
buck run //xplat/caffe2:pt_vulkan_api_test_binAppleMac#macosx-arm64

https://www.internalfb.com/phabricator/paste/view/P738255852

Reviewed By: SS-JIA

Differential Revision: D45893511

@pytorch-bot pytorch-bot bot added ciflow/periodic Trigger jobs ran periodically on master (periodic.yml) on the PR module: vulkan release notes: vulkan release notes category labels May 17, 2023
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented May 17, 2023

CLA Signed

The committers listed above are authorized under a signed CLA.

@pytorch-bot
Copy link

pytorch-bot bot commented May 17, 2023

🔗 Helpful Links

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

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

❌ 1 New Failure

As of commit 304c599:

NEW FAILURE - The following job has failed:

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

@facebook-github-bot
Copy link
Contributor

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

@lucylq
Copy link
Contributor Author

lucylq commented May 17, 2023

/easycla

lucylq added a commit to lucylq/pytorch that referenced this pull request May 17, 2023
…h#101719)

Summary:
Pull Request resolved: pytorch#101719

Unsqueeze operator: https://pytorch.org/docs/stable/generated/torch.unsqueeze.html#torch.unsqueeze

Test Plan:
Unsqueeze tests:
https://www.internalfb.com/phabricator/paste/view/P738187802
```
lfq@lfq-mbp fbsource % buck run --target-platforms ovr_config//platform/macos:arm64-fbsource //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64 -c pt.vulkan_full_precision=1 -- --gtest_filter="*unsqueeze*"
Downloaded 0/2 artifacts, 0.00 bytes, 100.0% cache miss (for updated rules)
Building: finished in 15.0 sec (100%) 455/455 jobs, 2/455 updated
  Total time: 15.0 sec
BUILD SUCCEEDED
Running main() from xplat/third-party/gmock/googletest-1.12.1/googletest/src/gtest_main.cc
Note: Google Test filter = *unsqueeze*
[==========] Running 3 tests from 1 test suite.
[----------] Global test environment set-up.
[----------] 3 tests from VulkanAPITest
[ RUN      ] VulkanAPITest.unsqueeze_dim0
[       OK ] VulkanAPITest.unsqueeze_dim0 (96 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim1
[       OK ] VulkanAPITest.unsqueeze_dim1 (2 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim2
[       OK ] VulkanAPITest.unsqueeze_dim2 (3 ms)
[----------] 3 tests from VulkanAPITest (101 ms total)
[----------] Global test environment tear-down
[==========] 3 tests from 1 test suite ran. (101 ms total)
[  PASSED  ] 3 tests.
```
All tests:
buck run //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64

https://www.internalfb.com/phabricator/paste/view/P738255852

Reviewed By: SS-JIA

Differential Revision: D45893511

fbshipit-source-id: 6875e1dcebc928282d8d6a2c795d3167e1dfb2cd
@facebook-github-bot
Copy link
Contributor

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

@facebook-github-bot
Copy link
Contributor

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

lucylq added a commit to lucylq/pytorch that referenced this pull request May 17, 2023
…h#101719)

Summary:
Pull Request resolved: pytorch#101719

Unsqueeze operator: https://pytorch.org/docs/stable/generated/torch.unsqueeze.html#torch.unsqueeze

Test Plan:
Unsqueeze tests:
https://www.internalfb.com/phabricator/paste/view/P738187802
```
lfq@lfq-mbp fbsource % buck run --target-platforms ovr_config//platform/macos:arm64-fbsource //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64 -c pt.vulkan_full_precision=1 -- --gtest_filter="*unsqueeze*"
Downloaded 0/2 artifacts, 0.00 bytes, 100.0% cache miss (for updated rules)
Building: finished in 15.0 sec (100%) 455/455 jobs, 2/455 updated
  Total time: 15.0 sec
BUILD SUCCEEDED
Running main() from xplat/third-party/gmock/googletest-1.12.1/googletest/src/gtest_main.cc
Note: Google Test filter = *unsqueeze*
[==========] Running 3 tests from 1 test suite.
[----------] Global test environment set-up.
[----------] 3 tests from VulkanAPITest
[ RUN      ] VulkanAPITest.unsqueeze_dim0
[       OK ] VulkanAPITest.unsqueeze_dim0 (96 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim1
[       OK ] VulkanAPITest.unsqueeze_dim1 (2 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim2
[       OK ] VulkanAPITest.unsqueeze_dim2 (3 ms)
[----------] 3 tests from VulkanAPITest (101 ms total)
[----------] Global test environment tear-down
[==========] 3 tests from 1 test suite ran. (101 ms total)
[  PASSED  ] 3 tests.
```
All tests:
buck run //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64

https://www.internalfb.com/phabricator/paste/view/P738255852

Reviewed By: SS-JIA

Differential Revision: D45893511

fbshipit-source-id: 18fd8808d9dfcda8a8e50e0234252f822f810662
lucylq added a commit to lucylq/pytorch that referenced this pull request May 18, 2023
…h#101719)

Summary:
Pull Request resolved: pytorch#101719

Unsqueeze operator: https://pytorch.org/docs/stable/generated/torch.unsqueeze.html#torch.unsqueeze

Test Plan:
Unsqueeze tests:
https://www.internalfb.com/phabricator/paste/view/P738187802
```
lfq@lfq-mbp fbsource % buck run --target-platforms ovr_config//platform/macos:arm64-fbsource //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64 -c pt.vulkan_full_precision=1 -- --gtest_filter="*unsqueeze*"
Downloaded 0/2 artifacts, 0.00 bytes, 100.0% cache miss (for updated rules)
Building: finished in 15.0 sec (100%) 455/455 jobs, 2/455 updated
  Total time: 15.0 sec
BUILD SUCCEEDED
Running main() from xplat/third-party/gmock/googletest-1.12.1/googletest/src/gtest_main.cc
Note: Google Test filter = *unsqueeze*
[==========] Running 3 tests from 1 test suite.
[----------] Global test environment set-up.
[----------] 3 tests from VulkanAPITest
[ RUN      ] VulkanAPITest.unsqueeze_dim0
[       OK ] VulkanAPITest.unsqueeze_dim0 (96 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim1
[       OK ] VulkanAPITest.unsqueeze_dim1 (2 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim2
[       OK ] VulkanAPITest.unsqueeze_dim2 (3 ms)
[----------] 3 tests from VulkanAPITest (101 ms total)
[----------] Global test environment tear-down
[==========] 3 tests from 1 test suite ran. (101 ms total)
[  PASSED  ] 3 tests.
```
All tests:
buck run //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64

https://www.internalfb.com/phabricator/paste/view/P738255852

Reviewed By: SS-JIA

Differential Revision: D45893511

fbshipit-source-id: 1a69b1ba8ec50aae5492548e61a565ac20fb7dc6
@facebook-github-bot
Copy link
Contributor

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

1 similar comment
@facebook-github-bot
Copy link
Contributor

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

lucylq added a commit to lucylq/pytorch that referenced this pull request May 18, 2023
…h#101719)

Summary:
Pull Request resolved: pytorch#101719

Unsqueeze operator: https://pytorch.org/docs/stable/generated/torch.unsqueeze.html#torch.unsqueeze

Test Plan:
Unsqueeze tests:
https://www.internalfb.com/phabricator/paste/view/P738187802
```
lfq@lfq-mbp fbsource % buck run --target-platforms ovr_config//platform/macos:arm64-fbsource //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64 -c pt.vulkan_full_precision=1 -- --gtest_filter="*unsqueeze*"
Downloaded 0/2 artifacts, 0.00 bytes, 100.0% cache miss (for updated rules)
Building: finished in 15.0 sec (100%) 455/455 jobs, 2/455 updated
  Total time: 15.0 sec
BUILD SUCCEEDED
Running main() from xplat/third-party/gmock/googletest-1.12.1/googletest/src/gtest_main.cc
Note: Google Test filter = *unsqueeze*
[==========] Running 3 tests from 1 test suite.
[----------] Global test environment set-up.
[----------] 3 tests from VulkanAPITest
[ RUN      ] VulkanAPITest.unsqueeze_dim0
[       OK ] VulkanAPITest.unsqueeze_dim0 (96 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim1
[       OK ] VulkanAPITest.unsqueeze_dim1 (2 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim2
[       OK ] VulkanAPITest.unsqueeze_dim2 (3 ms)
[----------] 3 tests from VulkanAPITest (101 ms total)
[----------] Global test environment tear-down
[==========] 3 tests from 1 test suite ran. (101 ms total)
[  PASSED  ] 3 tests.
```
All tests:
buck run //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64

https://www.internalfb.com/phabricator/paste/view/P738255852

Reviewed By: SS-JIA

Differential Revision: D45893511

fbshipit-source-id: cb856e02465c606b6046d826f24cb3ef9cece739
@SS-JIA SS-JIA self-requested a review May 22, 2023 16:57
…h#101719)

Summary:
bypass-github-export-checks
Pull Request resolved: pytorch#101719

Unsqueeze operator: https://pytorch.org/docs/stable/generated/torch.unsqueeze.html#torch.unsqueeze

Test Plan:
Unsqueeze tests:
https://www.internalfb.com/phabricator/paste/view/P738187802
```
lfq@lfq-mbp fbsource % buck run --target-platforms ovr_config//platform/macos:arm64-fbsource //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64 -c pt.vulkan_full_precision=1 -- --gtest_filter="*unsqueeze*"
Downloaded 0/2 artifacts, 0.00 bytes, 100.0% cache miss (for updated rules)
Building: finished in 15.0 sec (100%) 455/455 jobs, 2/455 updated
  Total time: 15.0 sec
BUILD SUCCEEDED
Running main() from xplat/third-party/gmock/googletest-1.12.1/googletest/src/gtest_main.cc
Note: Google Test filter = *unsqueeze*
[==========] Running 3 tests from 1 test suite.
[----------] Global test environment set-up.
[----------] 3 tests from VulkanAPITest
[ RUN      ] VulkanAPITest.unsqueeze_dim0
[       OK ] VulkanAPITest.unsqueeze_dim0 (96 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim1
[       OK ] VulkanAPITest.unsqueeze_dim1 (2 ms)
[ RUN      ] VulkanAPITest.unsqueeze_dim2
[       OK ] VulkanAPITest.unsqueeze_dim2 (3 ms)
[----------] 3 tests from VulkanAPITest (101 ms total)
[----------] Global test environment tear-down
[==========] 3 tests from 1 test suite ran. (101 ms total)
[  PASSED  ] 3 tests.
```
All tests:
buck run //xplat/caffe2:pt_vulkan_api_test_binAppleMac\#macosx-arm64

https://www.internalfb.com/phabricator/paste/view/P738255852

Reviewed By: SS-JIA

Differential Revision: D45893511

fbshipit-source-id: a465ec11b5c1b536bd1a56e0dd8b692fea67e8f8
@facebook-github-bot
Copy link
Contributor

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

@facebook-github-bot
Copy link
Contributor

@pytorchbot merge

(Initiating merge automatically since Phabricator Diff has merged)

@pytorch-bot pytorch-bot bot added the ciflow/trunk Trigger trunk jobs on your pull request label May 23, 2023
@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ciflow/periodic Trigger jobs ran periodically on master (periodic.yml) on the PR ciflow/trunk Trigger trunk jobs on your pull request fb-exported Merged module: vulkan release notes: vulkan release notes category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants