Skip to content

Conversation

Hhankyangg
Copy link
Contributor

@Hhankyangg Hhankyangg commented Nov 22, 2023

PR types

Function optimization

PR changes

Docs

Description

涉及到的 API 有

paddle.vision.transforms.RandomHorizontalFlip

  • 增加更具体的示例
    paddle.vision.transforms.RandomVerticalFlip
  • 增加更具体的示例
    paddle.lr.LRScheduler
  • 增加中文文档中介绍的14种策略

相关 中英文文档
paddlepaddle.org.cn/documentation/docs/zh/develop/api/paddle/optimizer/lr/LRScheduler_cn.html
paddlepaddle.org.cn/documentation/docs/zh/develop/api/paddle/vision/transforms/RandomHorizontalFlip_cn.html
paddlepaddle.org.cn/documentation/docs/zh/develop/api/paddle/vision/transforms/RandomVerticalFlip_cn.html

Copy link

paddle-bot bot commented Nov 22, 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 the contributor External developers label Nov 22, 2023
Copy link

paddle-bot bot commented Nov 22, 2023

✅ This PR's description meets the template requirements!
Please wait for other CI results.

Copy link
Contributor

Choose a reason for hiding this comment

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

试一试加 seed 能不能固定住输出?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

已用我手动输入的 Tensor 解决了随机的问题

@@ -55,6 +55,26 @@ class LRScheduler:

LRScheduler Base class. Define the common interface of a learning rate scheduler.

There are currently 14 strategies implemented in paddle based on this base class, which are:
Copy link
Contributor

Choose a reason for hiding this comment

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

列了 17 种

Suggested change
There are currently 14 strategies implemented in paddle based on this base class, which are:
There are currently 17 strategies implemented in paddle based on this base class, which are:

Copy link
Contributor Author

Choose a reason for hiding this comment

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

好的谢谢!已修改

@@ -55,6 +55,26 @@ class LRScheduler:

LRScheduler Base class. Define the common interface of a learning rate scheduler.

There are currently 14 strategies implemented in paddle based on this base class, which are:

- ``NoamDecay``: Related algorithms are derived from `*Attention Is All You Need* <http://blog.inkypy.com>`_ . Please refer to :ref:`en_api_paddle_optimizer_lr_NoamDecay`.
Copy link
Contributor

Choose a reason for hiding this comment

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

在英文文档中,英文 api 文档的 label 是由路径转化来的,如该例中的 paddle.optimizer.lr.NoamDecay,label应该是api_paddle_optimizer_lr_NoamDecay,中文的label则会在前面加 cn_

Suggested change
- ``NoamDecay``: Related algorithms are derived from `*Attention Is All You Need* <http://blog.inkypy.com>`_ . Please refer to :ref:`en_api_paddle_optimizer_lr_NoamDecay`.
- ``NoamDecay``: Related algorithms are derived from `*Attention Is All You Need* <http://blog.inkypy.com>`_ . Please refer to :ref:`api_paddle_optimizer_lr_NoamDecay`.

下面每一条都按上述修改~

Copy link
Contributor Author

Choose a reason for hiding this comment

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

已修改~

增加 class: LRScheduler 中文文档中介绍的 17 种策略至 docstring
修改 RandomHorizontalFlip 和 RandomVerticalFlip docstring 的示例代码
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~写的非常好

@luotao1 luotao1 merged commit c811851 into PaddlePaddle:develop Dec 4, 2023
SigureMo pushed a commit to gouzil/Paddle that referenced this pull request Dec 5, 2023
* docs(paddle.lr): 丰富 docstring 内容

增加 class: LRScheduler 中文文档中介绍的 17 种策略至 docstring

* docs(paddle.vision.transforms): 增加docstring更具体的示例

修改 RandomHorizontalFlip 和 RandomVerticalFlip docstring 的示例代码
@Hhankyangg Hhankyangg deleted the bugs branch January 14, 2024 02:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers HappyOpenSource 快乐开源活动issue与PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants