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

[Docathon][Add API Legend No.56,57] + add new images and change api document #6912

Merged
merged 1 commit into from
Oct 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions docs/api/paddle/column_stack_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ column_stack

沿水平轴堆叠输入 ``x`` 中的所有张量。 ``x`` 中的每个张量 ``tensor`` 如果在堆叠之前 ``tensor.ndim < 2`` ,则首先被整形为 ``(tensor.numel(), 1)``。所有张量必须具有相同的数据类型。

下图展示了一个 column_stack 的情形,将一个形状为(3,1)的二维张量与一个形状为(3,)的一维张量进行 column_stack 操作,其中一维张量首先被整形为(3,1),然后再沿水平轴堆叠输入所有张量。通过图例能很好看出张量的变化。

.. image:: ../../images/api_legend/column_stack.png
:width: 600
:alt: 图例

参数
::::::::::::

Expand Down
6 changes: 6 additions & 0 deletions docs/api/paddle/row_stack_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ row_stack

:ref:`cn_api_paddle_vstack` 的别名。沿垂直轴堆叠输入 ``x`` 中的所有张量。所有张量必须具有相同的数据类型。

下图展示了一个 row_stack 的情形,将一个形状为(1,3)的二维张量与另一个同样形状为(1,3),但是数据内容不同的二维张量进行 row_stack 操作,二者沿垂直轴堆叠成一个新的二维向量。通过图例能很好看出张量的变化。

.. image:: ../../images/api_legend/row_stack.png
:width: 600
:alt: 图例

参数
::::::::::::

Expand Down
Binary file added docs/images/api_legend/column_stack.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/api_legend/row_stack.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.