Skip to content
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

【Hackathon 4th No.11】 为 paddle 添加 Geometric Distribution API #51224

Merged
merged 42 commits into from
Apr 28, 2023

Conversation

dasenCoding
Copy link
Contributor

@dasenCoding dasenCoding commented Mar 6, 2023

PR types

New features

PR changes

APIs

Description

为 Paddle 添加几何分布 API,该PR包括了 API 实现的代码,以及动态测试和静态测试类。
原设计文档: PaddlePaddle/community#376
更正后的设计文档: PaddlePaddle/community#519
中文API文档: PaddlePaddle/docs#5816

@paddle-bot
Copy link

paddle-bot bot commented Mar 6, 2023

你的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 contributor External developers status: proposed labels Mar 6, 2023
@paddle-bot
Copy link

paddle-bot bot commented Mar 6, 2023

❌ The PR is not created using PR's template. You can refer to this Demo.
Please use PR's template, it helps save our maintainers' time so that more developers get helped.

@luotao1 luotao1 added the API label Mar 10, 2023
@dasenCoding
Copy link
Contributor Author

@cxxly 已经修改,麻烦再检查以下,感谢!

cxxly
cxxly previously approved these changes Apr 20, 2023
Copy link
Contributor

@cxxly cxxly left a comment

Choose a reason for hiding this comment

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

LGTM

@luotao1
Copy link
Contributor

luotao1 commented Apr 21, 2023

@dasenCoding 中文API文档需要补充下

# [1.41421354])
"""

def __init__(self, probs=None):
Copy link
Contributor

@jeff41404 jeff41404 Apr 21, 2023

Choose a reason for hiding this comment

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

probs should not be a parameter with default value None?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

probs should not be a parameter with default value None?

Yes, here really should not set a default value for probs, i have fixed.

thanks for your review!

@jeff41404
Copy link
Contributor

in rfc, chapter 3: pytorch args should be logits instead of scale?

@dasenCoding
Copy link
Contributor Author

dasenCoding commented Apr 21, 2023

in rfc, chapter 3: pytorch args should be logits instead of scale?

根据您的建议,已经在此PR中进行了修正:
PaddlePaddle/community#519

谢谢!

@dasenCoding
Copy link
Contributor Author

@dasenCoding 中文API文档需要补充下

Geometric 的中文文档已经完成!

doc PR: PaddlePaddle/docs#5816

谢谢!

Copy link
Contributor

@luotao1 luotao1 left a comment

Choose a reason for hiding this comment

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

#52999 (comment)
可以参考下这个说明,单测目录发生变化了要进行迁移

@dasenCoding
Copy link
Contributor Author

#52999 (comment) 可以参考下这个说明,单测目录发生变化了要进行迁移

收到!谢谢!

@dasenCoding
Copy link
Contributor Author

@cxxly 剩下两个CI没有通过,其他的都已经通过了,请您审查一下,感谢!

jeff41404
jeff41404 previously approved these changes Apr 27, 2023
Copy link
Contributor

@jeff41404 jeff41404 left a comment

Choose a reason for hiding this comment

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

LGTM

Args:
probs (Real|Tensor): Probability parameter.
The value of probs must be positive. When the parameter is a tensor, probs is probability of success for each trial.

Copy link
Contributor

Choose a reason for hiding this comment

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

加一下返回(returns)的描述

Copy link
Contributor Author

Choose a reason for hiding this comment

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

加一下返回(returns)的描述

已添加!


.. code-block:: python

import paddle
Copy link
Contributor

Choose a reason for hiding this comment

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

代码部分统一再往后缩进,否则无法解析出代码
image

Copy link
Contributor Author

Choose a reason for hiding this comment

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

代码部分统一再往后缩进,否则无法解析出代码 image

已修复!

Copy link
Contributor

@sunzhongkai588 sunzhongkai588 left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API contributor External developers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants