Skip to content

Conversation

@zhanghonggeng
Copy link
Contributor

@zhanghonggeng zhanghonggeng commented Sep 2, 2025

PR Category

User Experience

PR Types

New features

Description

Add Tensor.is_cuda and paddle.Size

pcard-67164

@paddle-bot
Copy link

paddle-bot bot commented Sep 2, 2025

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

Copy link
Contributor

@zhwesky2010 zhwesky2010 left a comment

Choose a reason for hiding this comment

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

可以把
torch.Size([2, 3]).count(2)
torch.Size([2, 3]).index(3, 0)

这两种用法测一下

@zhanghonggeng zhanghonggeng force-pushed the cuda branch 2 times, most recently from 78674e8 to c3817fc Compare September 3, 2025 11:46
@PaddlePaddle PaddlePaddle deleted a comment from zhanghonggeng Sep 4, 2025
zhwesky2010
zhwesky2010 previously approved these changes Sep 4, 2025
Copy link
Contributor

@zhwesky2010 zhwesky2010 left a comment

Choose a reason for hiding this comment

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

LGTM

@codecov-commenter
Copy link

codecov-commenter commented Sep 4, 2025

Codecov Report

❌ Patch coverage is 96.49123% with 2 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (develop@01f5572). Learn more about missing BASE report.

Files with missing lines Patch % Lines
python/paddle/pir/math_op_patch.py 87.50% 1 Missing ⚠️
python/paddle/tensor/size.py 97.82% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             develop   #75043   +/-   ##
==========================================
  Coverage           ?   96.49%           
==========================================
  Files              ?        3           
  Lines              ?       57           
  Branches           ?        0           
==========================================
  Hits               ?       55           
  Misses             ?        2           
  Partials           ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

SigureMo
SigureMo previously approved these changes Sep 4, 2025
Copy link
Contributor

@zhwesky2010 zhwesky2010 left a comment

Choose a reason for hiding this comment

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

看覆盖率还有一些没过,得加点pir下的单测

Copy link
Contributor

@XiaoguangHu01 XiaoguangHu01 left a comment

Choose a reason for hiding this comment

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

LGTM

@zhwesky2010 zhwesky2010 merged commit 5a38950 into PaddlePaddle:develop Sep 5, 2025
78 of 80 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants