Skip to content

Update tensor_base doc#34

Merged
SigureMo merged 2 commits intoPFCCLab:masterfrom
youge325:cSelect
Mar 21, 2026
Merged

Update tensor_base doc#34
SigureMo merged 2 commits intoPFCCLab:masterfrom
youge325:cSelect

Conversation

@youge325
Copy link
Contributor

@youge325 youge325 commented Feb 6, 2026

更新 tensor_base 文档

Copilot AI review requested due to automatic review settings February 6, 2026 07:16
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds comprehensive test coverage for various tensor operations in the ATen/PyTorch C++ API, specifically focusing on split, select, reciprocal, and detach operations.

Changes:

  • Added tests for multiple split-related operations (split, split_with_sizes, unsafe_split, unsafe_split_with_sizes, tensor_split, hsplit, vsplit, dsplit)
  • Added tests for tensor selection operations (select, select_symint)
  • Added tests for reciprocal operations (reciprocal, reciprocal_, global reciprocal function)
  • Added tests for tensor detach operations (detach, detach_)

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 7 comments.

File Description
test/ops/SplitTest.cpp Implements 16 test cases covering various split operations including basic split, split by sizes, unsafe split variants, tensor_split, and dimensional splits (hsplit, vsplit, dsplit)
test/ops/SelectTest.cpp Implements 10 test cases for tensor selection operations including dimension selection, negative indexing, chained selection, and SymInt variants
test/ops/ReciprocalTest.cpp Implements 5 test cases for reciprocal operations including basic reciprocal, in-place variant, various values, multi-dimensional tensors, and global function
test/ops/DetachTest.cpp Implements 5 test cases for tensor detach operations including basic detach, in-place variant, modification tests, and multi-dimensional tensors

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@@ -0,0 +1,221 @@
#include <ATen/ATen.h>
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

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

The PR description mentions adding tests for masked_select, but no test file for this function is included in the changes. Either the test file is missing, or the PR description should be updated to remove the mention of masked_select.

Copilot uses AI. Check for mistakes.
@youge325 youge325 changed the title add select, detach, reciprocal and split related tests update doc Mar 20, 2026
@youge325 youge325 changed the title update doc update tensor_base doc Mar 20, 2026
@youge325 youge325 changed the title update tensor_base doc Update tensor_base doc Mar 20, 2026
Copy link
Contributor

@SigureMo SigureMo left a comment

Choose a reason for hiding this comment

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

LGTMeow 🐾

@SigureMo SigureMo merged commit eae8422 into PFCCLab:master Mar 21, 2026
2 checks passed
@youge325 youge325 deleted the cSelect branch March 21, 2026 14:35
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.

3 participants