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

DLPack: fix test using PyTorch API. #8348

Merged
merged 1 commit into from
Dec 5, 2024
Merged

Conversation

ysiraichi
Copy link
Collaborator

This PR fixes the test introduced in #7213, where it called PyTorch's to_dlpack() function before actually calling from_dlpack(). Meaning that both Tensor.__dlpack__ and Tensor.__dlpack_device__ functions weren't getting called, which were the functions that that test was supposed to be testing.

This should be merged after pytorch/pytorch#138470.

cc @JackCaoG @vanbasten23 @qihqi

@ysiraichi
Copy link
Collaborator Author

At first, I won't add the .torch_pin file, so as to make sure the test is failing without pytorch/pytorch#138470. Then, I will add it, so as to make sure it is the reason the test passes.

@ysiraichi ysiraichi force-pushed the ysiraichi/fix-dlpack-test branch from ca03671 to d567592 Compare December 5, 2024 14:51
@ysiraichi
Copy link
Collaborator Author

@JackCaoG @vanbasten23 It looks like CUDA build/tests are not running. Do I need to add a label for it?

@JackCaoG
Copy link
Collaborator

JackCaoG commented Dec 5, 2024

cuda test was disabled on head due to some build issue.

@ysiraichi
Copy link
Collaborator Author

Oh, I see. Is it ok if we merge this one? pytorch/pytorch#138470 was already merged.

@JackCaoG JackCaoG merged commit 4c99d21 into master Dec 5, 2024
12 checks passed
rpsilva-aws pushed a commit to rpsilva-aws/xla that referenced this pull request Dec 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants