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

triu/tril: complete dtype support for CPU/CUDA. #101414

Closed
wants to merge 1 commit into from

Conversation

nikitaved
Copy link
Collaborator

@nikitaved nikitaved commented May 15, 2023

@pytorch-bot
Copy link

pytorch-bot bot commented May 15, 2023

🔗 Helpful Links

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

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

✅ No Failures

As of commit a5c05bf:
💚 Looks good so far! There are no failures yet. 💚

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

@nikitaved nikitaved added module: cuda Related to torch.cuda, and CUDA support in general module: cpu CPU specific problem (e.g., perf, algorithm) ciflow/trunk Trigger trunk jobs on your pull request labels May 15, 2023
@@ -69,8 +69,12 @@ void triu_tril_cuda_template(const Tensor& result, const Tensor& self, int64_t k
int64_t N = self.numel();
dim3 dim_block = cuda::getApplyBlock();
dim3 dim_grid((N + dim_block.x - 1) / dim_block.x);
AT_DISPATCH_ALL_TYPES_AND_COMPLEX_AND3(kComplexHalf, at::ScalarType::Half, at::ScalarType::Bool,
self.scalar_type(), "triu_tril_cuda_template", [&]{
AT_DISPATCH_ALL_TYPES_AND_COMPLEX_AND4(
Copy link
Collaborator

Choose a reason for hiding this comment

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

btw given that this op only copies elements or sets them to 0, can you dispatch just based on the size of the type?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Are you fine with a follow-up?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes, sure

@nikitaved nikitaved added the release notes: linalg_frontend release notes category label May 16, 2023
@nikitaved
Copy link
Collaborator Author

@pytorchbot merge

@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/trunk Trigger trunk jobs on your pull request Merged module: cpu CPU specific problem (e.g., perf, algorithm) module: cuda Related to torch.cuda, and CUDA support in general open source release notes: linalg_frontend release notes category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants