Skip to content

[Docs] Fix invalid single-backticks usage in guides docs (Batch 4)#7872

Merged
ooooo-create merged 3 commits intoPaddlePaddle:developfrom
StatefulDust:fix-single-backticks-batch4
Mar 13, 2026
Merged

[Docs] Fix invalid single-backticks usage in guides docs (Batch 4)#7872
ooooo-create merged 3 commits intoPaddlePaddle:developfrom
StatefulDust:fix-single-backticks-batch4

Conversation

@cutetocute
Copy link
Contributor

PR types

Typos

PR changes

Docs

Description

This PR continues to resolve the abuse of single backticks in RST documents as tracked in StatefulDust#40 .

The previous single-backticks used incorrectly for inline literals or variable names have been properly replaced with double backticks.

This batch focuses on tutorial guides like docs/guides/advanced/*, docs/guides/beginner/*, and docs/guides/flags/*, avoiding intersections with other pending PRs. Among them it also fixes a malformed cross-reference ref:cn_api_fluid_ParamAttr to properly use :ref:.

@paddle-bot
Copy link

paddle-bot bot commented Mar 13, 2026

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

@github-actions
Copy link

github-actions bot commented Mar 13, 2026

📚 本次 PR 文档预览链接(点击展开)
ℹ️ 预览提醒
请等待 Docs-NEW 流水线运行完成后再点击预览链接,否则可能会看到旧版本内容或遇到链接无法访问的情况。

@cutetocute cutetocute changed the title [Typos] Fix invalid single-backticks usage in guides docs (Batch 4) [Docs] Fix invalid single-backticks usage in guides docs (Batch 4) Mar 13, 2026
@ooooo-create ooooo-create marked this pull request as ready for review March 13, 2026 07:51
Copilot AI review requested due to automatic review settings March 13, 2026 07:51
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

该 PR 延续批量修复 RST 文档中单反引号误用的问题(将 inline literal/变量名从 ... 改为 ...),覆盖 flags 指南、入门索引与梯度裁剪高级指南,并尝试修正一个错误的交叉引用写法。

Changes:

  • 将多处错误使用的单反引号 inline literal 替换为双反引号 ...(中英 guides)。
  • 修复 gradient_clip_en.rstref: 形式的交叉引用为 :ref: 形式。
  • 对部分示例/描述文本同步做了 inline literal 标注更新。

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 10 comments.

Show a summary per file
File Description
docs/guides/flags/others_en.rst 修正 inline literal 的反引号用法(并触及相关句子行)。
docs/guides/flags/others_cn.rst 修正 inline literal 的反引号用法(并触及相关句子行)。
docs/guides/flags/npu_en.rst 修正编译选项 inline literal 的反引号用法。
docs/guides/flags/npu_cn.rst 修正编译选项 inline literal 的反引号用法。
docs/guides/flags/debug_en.rst 修正表达式 inline literal 的反引号用法。
docs/guides/flags/debug_cn.rst 修正表达式 inline literal 的反引号用法。
docs/guides/beginner/index_cn.rst 修正 Tensor inline literal 的反引号用法。
docs/guides/advanced/gradient_clip_en.rst 修正 inline literal,并将错误的 ref: 改为 :ref:(引入引用有效性风险点)。
docs/guides/advanced/gradient_clip_cn.rst 修正 inline literal 的反引号用法。

You can also share your feedback on Copilot code review. Take the survey.

(始于 0.15.0)

该 flag 用于调试。它表示是否在 CPU 侧确定计算结果。 在某些情况下,不同求和次序的结果可能不同,例如,`a+b+c+d` 的结果可能与 `c+a+b+d` 的结果不同。
该 flag 用于调试。它表示是否在 CPU 侧确定计算结果。 在某些情况下,不同求和次序的结果可能不同,例如,``a+b+c+d`` 的结果可能与 ``c+a+b+d`` 的结果不同。
(since 1.4.0)

FLAGS_tracer_profile_fname indicates the profiler filename for imperative tracer, which generated by gperftools. Only valid when compiled `WITH_PROFILER=ON`. Empty if disabled.
FLAGS_tracer_profile_fname indicates the profiler filename for imperative tracer, which generated by gperftools. Only valid when compiled ``WITH_PROFILER=ON``. Empty if disabled.
(始于 1.4.0)

FLAGS_tracer_profile_fname 表示由 gperftools 生成的命令式跟踪器的分析器文件名。仅在编译选项选择`WITH_PROFILER = ON`时有效。如果禁用则设为 empty。
FLAGS_tracer_profile_fname 表示由 gperftools 生成的命令式跟踪器的分析器文件名。仅在编译选项选择 ``WITH_PROFILER = ON`` 时有效。如果禁用则设为 empty。
(since 1.3)

If the FLAGS_sync_nccl_allreduce is true, there will call `cudaStreamSynchronize(nccl_stream)` in allreduce_op_handle, this mode can get better performance in some scenarios.
If the FLAGS_sync_nccl_allreduce is true, there will call ``cudaStreamSynchronize(nccl_stream)`` in allreduce_op_handle, this mode can get better performance in some scenarios.
(始于 1.3)

如果 FLAGS_sync_nccl_allreduce 为 True,则会在 allreduce_op_handle 中调用 `cudaStreamSynchronize(nccl_stream)` ,这种模式在某些情况下可以获得更好的性能。
如果 FLAGS_sync_nccl_allreduce 为 True,则会在 allreduce_op_handle 中调用 ``cudaStreamSynchronize(nccl_stream)`` ,这种模式在某些情况下可以获得更好的性能。
示例
-------
FLAGS_sync_nccl_allreduce=True - 在 allreduce_op_handle 中调用 `cudaStreamSynchronize(nccl_stream)` 。
FLAGS_sync_nccl_allreduce=True - 在 allreduce_op_handle 中调用 ``cudaStreamSynchronize(nccl_stream)`` 。
**b. Clip a part of gradients**

You can clip a part of gradients by setting `need_clip` of ref:`cn_api_fluid_ParamAttr` . `need_clip` is `True` by default, which represents that its gradient will be clipped. Otherwise, its gradient will not be clipped.
You can clip a part of gradients by setting ``need_clip`` of :ref:`cn_api_fluid_ParamAttr` . ``need_clip`` is ``True`` by default, which represents that its gradient will be clipped. Otherwise, its gradient will not be clipped.
**b. Clip a part of gradients**

You can clip a part of gradients by setting `need_clip` of ref:`cn_api_fluid_ParamAttr` . `need_clip` is `True` by default, which represents that its gradient will be clipped. Otherwise, its gradient will not be clipped.
You can clip a part of gradients by setting ``need_clip`` of :ref:`cn_api_fluid_ParamAttr` . ``need_clip`` is ``True`` by default, which represents that its gradient will be clipped. Otherwise, its gradient will not be clipped.
**b. Clip a part of gradients**

You can clip a part of gradients by setting `need_clip` of ref:`cn_api_fluid_ParamAttr` . `need_clip` is `True` by default, which represents that its gradient will be clipped. Otherwise, its gradient will not be clipped. Refer to the sample code above.
You can clip a part of gradients by setting ``need_clip`` of :ref:`cn_api_fluid_ParamAttr` . ``need_clip`` is ``True`` by default, which represents that its gradient will be clipped. Otherwise, its gradient will not be clipped. Refer to the sample code above.
(since 0.15.0)

This Flag is used for debugging. It indicates whether to make the result of computation deterministic in CPU side. In some case, the result of the different order of summing maybe different,for example, the result of `a+b+c+d` may be different with the result of `c+a+b+d`.
This Flag is used for debugging. It indicates whether to make the result of computation deterministic in CPU side. In some case, the result of the different order of summing maybe different,for example, the result of ``a+b+c+d`` may be different with the result of ``c+a+b+d``.
@ooooo-create ooooo-create merged commit 89ba9f4 into PaddlePaddle:develop Mar 13, 2026
9 checks passed
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.

3 participants