-
Notifications
You must be signed in to change notification settings - Fork 5.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
paddle.uniform api生成数值超过指定范围 #45713
Comments
您好,我们已经收到了您的问题,会安排技术人员尽快解答您的问题,请耐心等待。请您再次检查是否提供了清晰的问题描述、复现代码、环境&版本、报错信息等。同时,您也可以通过查看官网API文档、常见问题、历史Issue、AI社区来寻求解答。祝您生活愉快~ Hi! We've received your issue and please be patient to get responded. We will arrange technicians to answer your questions as soon as possible. Please make sure that you have posted enough message to demo your request. You may also check out the API,FAQ,Github Issue and AI community to get the answer.Have a nice day! |
It's my fault. Ignore it, please. |
hi,我本地跑出了-1,但是没有出现1。uniform是产生[min, max)的随机数, 建议设置 min > -1 试试。 |
楼主说uniform是产生(min, max)的随机数,下面的zhiqiu说uniform是产生[min, max)的随机数,请问2位,这个结论是谁告诉你们的? |
是的,uniform的c++ kernel用的是std::uniform_real_distribution实现,c++文档说是[min, max)。参考:cppreference |
好的,我们会讨论下怎么修复哈。 |
Since you haven't replied for more than a year, we have closed this issue/pr. |
bug描述 Describe the Bug
paddle版本:2.3.2
系统:MacOS, M1芯片
在使用paddle.uniform生成(-1,1)区间随机数时,会有一定概率出现返回值为-1或1的情况,导致后续计算log1p出现异常值。因为是随机生成,复现该bug可能需多次重复执行代码。
某次复现出的结果:

辛苦看下是我使用的问题还是uniform 算子实现存在bug。
其他补充信息 Additional Supplementary Information
No response
The text was updated successfully, but these errors were encountered: