Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
该 PR 为 ATen/compat 接口补充了一批 C++ 侧的 gtest 用例,通过将关键结果写入 /tmp/paddle_cpp_api_test/<exe>.txt 来做 Paddle/Torch 对齐验证。
Changes:
- 新增
view_as、transpose/transpose_、t/t_、to、item、eye、coalesce等接口的测试用例文件。 - 扩展
SumTest.cpp,新增Tensor::sum(...)成员函数形式的覆盖。
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| test/ops/ViewAsTest.cpp | 新增 view_as 形状变换与共享存储语义测试 |
| test/ops/TransposeTest.cpp | 新增 transpose/transpose_(含负维、原地)测试 |
| test/ops/ToTest.cpp | 新增 to(...) 多重载/可选参数覆盖测试 |
| test/ops/TTest.cpp | 新增 t/t_ 与 transpose 等价性测试 |
| test/ops/SumTest.cpp | 增加 Tensor::sum(...) 成员函数形式的测试覆盖 |
| test/ops/ItemTest.cpp | 新增 item() / item<T>() 标量提取测试 |
| test/ops/EyeTest.cpp | 新增 eye 不同形状/不同 dtype 的测试 |
| test/ops/CoalesceTest.cpp | 新增稀疏 COO coalesce/_nnz/_values/is_coalesced 测试 |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
c80f236 to
ef4c009
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
新增 sum、t、t_、transpose_、view_as、coalesce、is_variable、item 接口测试
