-
Notifications
You must be signed in to change notification settings - Fork 821
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
[Docathon][Add Inplace CN Doc No.9] #7230
base: develop
Are you sure you want to change the base?
Conversation
感谢你贡献飞桨文档,文档预览构建中,Docs-New 跑完后即可预览,预览链接:http://preview-pr-7230.paddle-docs-preview.paddlepaddle.org.cn/documentation/docs/zh/api/index_cn.html |
docs/api/paddle/Overview_cn.rst
Outdated
@@ -254,6 +254,7 @@ tensor 数学操作原位(inplace)版本 | |||
" :ref:`paddle.nan_to_num_ <cn_api_paddle_nan_to_num_>` ", "Inplace 版本的 nan_to_num API,对输入 x 采用 Inplace 策略" | |||
" :ref:`paddle.i0_ <cn_api_paddle_i0_>` ", "Inplace 版本的 i0 API,对输入 x 采用 Inplace 策略" | |||
" :ref:`paddle.lcm_ <cn_api_paddle_lcm_>` ", "Inplace 版本的 lcm API,对输入 x 采用 Inplace 策略" | |||
" :ref:`paddle.cauchy_ <cn_api_paddle_cauchy_>` ", 对现有张量``x``进行原地修改,将所有元素替换为从柯西分布中随机采样的数值。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
按字母排序放到前面吧
docs/api/paddle/cauchy__cn.rst
Outdated
cauchy\_ | ||
------------------------------- | ||
|
||
.. py:function:: paddle.cauchy_(x: paddle.Tensor, loc: Numeric = 0, scale: Numeric = 1, name: str | None = None) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.. py:function:: paddle.cauchy_(x: paddle.Tensor, loc: Numeric = 0, scale: Numeric = 1, name: str | None = None) | |
.. py:function:: paddle.cauchy_(x, loc = 0, scale = 1, name = None) |
docs/api/paddle/cauchy__cn.rst
Outdated
|
||
|
||
|
||
对现有张量``x``进行原地修改,将所有元素替换为从柯西分布中随机采样的数值。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
逗号用中文的。对现有张量``x``进行原地修改
赶紧语句有些不通顺,改成如 直接修改输入张量
docs/api/paddle/cauchy__cn.rst
Outdated
:::::::::::: | ||
|
||
- **x** (Tensor) - 输入的 Tensor,支持的数据类型为:float32、float64。 | ||
- **loc** (scalar|可选) - 分布峰值的位置参数,数据类型为 float32 或 float64。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
参考 API 文档的参数写法,可选参数写为 可选
,并且参数说明里要写清楚默认值和默认值的含义
- **loc** (scalar|可选) - 分布峰值的位置参数,数据类型为 float32 或 float64。 | |
- **loc** (scalar,可选) - 分布峰值的位置参数,数据类型为 float32 或 float64。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
已经按要求和规范进行了修改,感谢您的指正 @sunzhongkai588
@sunzhongkai588
新增cauchy_.rst中文文档,同时在Overview_cn.rst中新增cauchy_相关信息(在“tensor 数学操作原位(inplace)版本”标题下)
issue:#7090
英文文档链接:https://www.paddlepaddle.org.cn/documentation/docs/en/develop/api/paddle/cauchy__en.html