Skip to content

[0-size Tensor No.319] Add 0-size Tensor support for paddle.median - #73477

Merged
luotao1 merged 3 commits into
PaddlePaddle:developfrom
co63oc:f26
Jun 24, 2025
Merged

luotao1 merged 3 commits into
PaddlePaddle:developfrom
co63oc:f26

Conversation

@co63oc

@co63oc co63oc commented Jun 19, 2025 •

Copy link
Copy Markdown
Contributor

PR Category

Execute Infrastructure

PR Types

Improvements

Description

[0-size Tensor No.319] Add 0-size Tensor support for paddle.Tensor.median
[0-size Tensor Job2 No.48] Add 0-size Tensor support for paddle.median

去掉 python/paddle/tensor/stat.py 中判断size=0
修改 topk kernel,topk kernel 在infermeta 时设置为-1,需要在kernel中Resize后再判断x.numel

PaddleAPITest测试通过
image

@paddle-bot

paddle-bot Bot commented Jun 19, 2025

Copy link
Copy Markdown

你的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.

@paddle-bot paddle-bot Bot added the contributor External developers label Jun 19, 2025
@codecov-commenter

codecov-commenter commented Jun 19, 2025 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 37.50000% with 5 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (develop@d16b9b4). Learn more about missing BASE report.

Files with missing lines Patch % Lines
paddle/phi/kernels/cpu/top_k_kernel.cc 28.57% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             develop   #73477   +/-   ##
==========================================
  Coverage           ?   37.50%           
==========================================
  Files              ?        2           
  Lines              ?        8           
  Branches           ?        0           
==========================================
  Hits               ?        3           
  Misses             ?        5           
  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.

@luotao1 luotao1 added the HappyOpenSource Pro 进阶版快乐开源活动,更具挑战性的任务 label Jun 20, 2025
@co63oc

co63oc commented Jun 22, 2025

Copy link
Copy Markdown
Contributor Author

/re-run all-failed

@DanielSun11 DanielSun11 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@luotao1
luotao1 merged commit aaf077d into PaddlePaddle:develop Jun 24, 2025
@co63oc
co63oc deleted the f26 branch June 30, 2025 10:30
@co63oc co63oc changed the title [0-size Tensor Job2 No.48] Add 0-size Tensor support for paddle.median [0-size Tensor No.319] Add 0-size Tensor support for paddle.median Jul 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor External developers HappyOpenSource Pro 进阶版快乐开源活动,更具挑战性的任务

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants