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

映射文档 No. 46 #5854

Merged
merged 3 commits into from
May 6, 2023
Merged

映射文档 No. 46 #5854

merged 3 commits into from
May 6, 2023

Conversation

xianyu11-x
Copy link
Contributor

完成 #5691 中No.46的文档映射工作,其中新增8个api映射文档,有问题请联系

@paddle-bot
Copy link

paddle-bot bot commented May 5, 2023

感谢你贡献飞桨文档,文档预览构建中,Docs-New 跑完后即可预览,预览链接:http://preview-pr-5854.paddle-docs-preview.paddlepaddle.org.cn/documentation/docs/zh/api/index_cn.html
预览工具的更多说明,请参考:飞桨文档预览工具

@xianyu11-x
Copy link
Contributor Author

torch.diag和torch.meshgrid的API 映射已在仓库中存在
paddle.renorm的缺失对应的API文档,函数相关定义只在Release Note和对应的PR中存在

Copy link
Collaborator

@Skylark-hjyp Skylark-hjyp left a comment

Choose a reason for hiding this comment

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

  • 参数映射部分没有的参数可以用 - 代替
  • 分类名可以直接写为 torch 参数更多,保持和其他文件的统一

@@ -0,0 +1,35 @@
## [仅 torch 参数更多]torch.gcd
Copy link
Collaborator

Choose a reason for hiding this comment

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

分类名写为 torch参数更多 即可~

| ------- | ------------ | --------------------------------------------------- |
| input | x | 表示输入的第一个 Tensor ,仅参数名不一致。 |
| other | y | 表示输入的第二个 Tensor ,仅参数名不一致。 |
| out | | 表示输出的 Tensor,Paddle 无此参数,需要进行转写。 |
Copy link
Collaborator

Choose a reason for hiding this comment

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

缺失的参数用 - 替代

@@ -0,0 +1,37 @@
## [仅 torch 参数更多]torch.histc
Copy link
Collaborator

Choose a reason for hiding this comment

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

分类名写为 torch参数更多 即可

paddle.histogram(input, bins=100, min=0, max=0, name=None)
```

其中 Paddle 相比 PyTorch 支持更多其他参数,具体如下:
Copy link
Collaborator

Choose a reason for hiding this comment

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

应该是 其中 PyTorch 相比 Paddle 支持更多其他参数,具体如下:

| bins | bins | 表示直方图直条的个数。 |
| min | min | 表示范围的下边界。 |
| max | max | 表示范围的上边界。 |
| out | | 表示输出的 Tensor,Paddle 无此参数,需要进行转写。 |
Copy link
Collaborator

Choose a reason for hiding this comment

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

缺失的参数用 - 替代

| ------- | ------------ | --------------------------------------------------- |
| input | input | 表示输入的 Tensor 。 |
| p | p | 表示 p-范数计算的 p 值。|
| dim | axis | 表示切分的维度。 |
Copy link
Collaborator

Choose a reason for hiding this comment

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

备注可以补充一句 仅参数名不一致

| p | p | 表示 p-范数计算的 p 值。|
| dim | axis | 表示切分的维度。 |
| maxnorm | max_norm | 表示子张量的 p-范数最大值,仅参数名不一致。 |
| out | | 表示输出的 Tensor,Paddle 无此参数,需要进行转写。 |
Copy link
Collaborator

Choose a reason for hiding this comment

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

缺失的参数用 - 替代

@@ -0,0 +1,23 @@
## [仅 torch 参数更多]torch.repeat_interleave
Copy link
Collaborator

Choose a reason for hiding this comment

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

torch 参数更多

| input | x | 表示输入的 Tensor ,仅参数名不一致。 |
| repeats | repeats | 表示指定复制次数的 1-D Tensor 或指定的复制次数。 |
| dim | axis | 表示复制取值的维度,仅参数名不一致。 |
| output_size | | 表示给定维度的总输出尺寸,Paddle 无此参数,一般对网络训练结果影响不大,可直接删除。 |
Copy link
Collaborator

Choose a reason for hiding this comment

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

缺失的参数可以用 - 代替

@@ -0,0 +1,46 @@
## [仅 torch 参数更多]torch.searchsorted
Copy link
Collaborator

Choose a reason for hiding this comment

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

torch 参数更多

@xianyu11-x
Copy link
Contributor Author

所有问题均已修改更正。

Copy link
Collaborator

@Skylark-hjyp Skylark-hjyp 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 e26ec66 into PaddlePaddle:develop May 6, 2023
@luotao1
Copy link
Collaborator

luotao1 commented May 8, 2023

hi, @xianyu11-x

  • 非常感谢你对飞桨框架的贡献,我们正在运营一个PFCC组织,会通过定期分享技术知识与发布开发者主导任务的形式持续为飞桨框架做贡献,详情可见 https://github.com/luotao1 主页说明。
  • 如果你对PFCC有兴趣,请发送邮件至 [email protected],我们会邀请你加入~

lijialin03 pushed a commit to lijialin03/Paddledocs that referenced this pull request May 16, 2023
* add md file

* fix bug

* fix some errors
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.

4 participants