Skip to content

Conversation

@Manfredss
Copy link
Contributor

PR Category

User Experience

PR Types

New features

Description

add param decorator and unit tests for paddle.std, paddle.square and paddle.randint

@paddle-bot
Copy link

paddle-bot bot commented Jan 5, 2026

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

if out is not None:
import paddle

paddle.assign(res, out)
Copy link
Contributor

Choose a reason for hiding this comment

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

这个为何不采用下沉的方式

x, axis=axis, unbiased=unbiased, keepdim=keepdim, name=name, out=out
)
if out is not None:
out.sqrt_()
Copy link
Contributor

Choose a reason for hiding this comment

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

用paddle.sqrt(out=) 吧,另外var如果支持了别名,这里是不是透传就行。无需再来一次装饰器。

@zhwesky2010
Copy link
Contributor

square已经下沉了,重新处理std、randint吧

@Manfredss Manfredss force-pushed the ApiEnhance352_372_376 branch from 1080822 to 4bd5672 Compare January 8, 2026 14:29
@Manfredss Manfredss force-pushed the ApiEnhance352_372_376 branch from c114028 to 4a0bbfb Compare January 10, 2026 09:51
@Manfredss Manfredss changed the title [API Compatibility No.352、372、376] add param decorator for paddle.std, paddle.square and paddle.randint -part [API Compatibility No.352、372] add param decorator for paddle.std and paddle.randint -part Jan 10, 2026
@codecov-commenter
Copy link

Codecov Report

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

Files with missing lines Patch % Lines
python/paddle/tensor/random.py 33.33% 2 Missing ⚠️

❌ Your patch status has failed because the patch coverage (66.66%) is below the target coverage (90.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop   #77194   +/-   ##
==========================================
  Coverage           ?   66.66%           
==========================================
  Files              ?        2           
  Lines              ?        6           
  Branches           ?        0           
==========================================
  Hits               ?        4           
  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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants