Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
2 changes: 1 addition & 1 deletion docs/api/paddle/amp/debugging/DebugMode_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ DebugMode

.. py:class:: paddle.amp.debugging.DebugMode()

`DebugMode` 用于标识 `TensorCheckerConfig` 的状态。每个 `DebugMode` 的含义如下:
``DebugMode`` 用于标识 ``TensorCheckerConfig`` 的状态。每个 ``DebugMode`` 的含义如下:

- **DebugMode.CHECK_NAN_INF_AND_ABORT** - 打印或保存带有 NaN/Inf 的 Tensor 关键信息并中断程序。

Expand Down
6 changes: 3 additions & 3 deletions docs/api/paddle/compat/max_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ max
.. py:function:: paddle.compat.max(x, out=None)


对整个 input tensor 求最大值,见 `paddle.amax` :ref:`cn_api_paddle_amax`
对整个 input tensor 求最大值,见 ``paddle.amax`` :ref:`cn_api_paddle_amax`

.. note::

Expand All @@ -47,7 +47,7 @@ max

.. note::

对输入有多个最大值的情况下,`paddle.compat.max` 将只返回梯度值给 ``indices`` 中选择的位置。``out`` 返回方法与静态图联合使用是被禁止的行为,静态图下将报错。
对输入有多个最大值的情况下,``paddle.compat.max`` 将只返回梯度值给 ``indices`` 中选择的位置。``out`` 返回方法与静态图联合使用是被禁止的行为,静态图下将报错。

参数
:::::::::
Expand All @@ -67,7 +67,7 @@ MinMaxRetType(Tensor, Tensor),此处的 ``MinMaxRetType`` 是一个具名元
.. py:function:: paddle.compat.max(x, other, out=None)


与 ``other`` Tensor 计算逐元素最大值。见 `paddle.maximum` :ref:`cn_api_paddle_maximum`
与 ``other`` Tensor 计算逐元素最大值。见 ``paddle.maximum`` :ref:`cn_api_paddle_maximum`

.. note::

Expand Down
6 changes: 3 additions & 3 deletions docs/api/paddle/compat/min_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ min
.. py:function:: paddle.compat.min(x, out=None)


对整个 input tensor 求最小值,见 `paddle.amin` :ref:`cn_api_paddle_amin`
对整个 input tensor 求最小值,见 ``paddle.amin`` :ref:`cn_api_paddle_amin`

.. note::

Expand All @@ -47,7 +47,7 @@ min

.. note::

对输入有多个最小值的情况下,`paddle.compat.min` 将只返回梯度值给 ``indices`` 中选择的位置。``out`` 返回方法与静态图联合使用是被禁止的行为,静态图下将报错。
对输入有多个最小值的情况下,``paddle.compat.min`` 将只返回梯度值给 ``indices`` 中选择的位置。``out`` 返回方法与静态图联合使用是被禁止的行为,静态图下将报错。

参数
:::::::::
Expand All @@ -67,7 +67,7 @@ MinMaxRetType(Tensor, Tensor),此处的 ``MinMaxRetType`` 是一个具名元
.. py:function:: paddle.compat.min(x, other, out=None)


与 ``other`` Tensor 计算逐元素最小值。见 `paddle.minimum` :ref:`cn_api_paddle_minimum`
与 ``other`` Tensor 计算逐元素最小值。见 ``paddle.minimum`` :ref:`cn_api_paddle_minimum`

.. note::

Expand Down
6 changes: 3 additions & 3 deletions docs/api/paddle/distributed/shard_optimizer_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ shard_optimizer

.. py:function:: paddle.distributed.shard_optimizer(optimizer, shard_fn=None)

将单卡视角的优化器转变为分布式视角。可以通过指定 `shard_fn` 来定制化优化器状态的切分方式,否则会将参数的分布式信息传递给对应的优化器状态。
将单卡视角的优化器转变为分布式视角。可以通过指定 ``shard_fn`` 来定制化优化器状态的切分方式,否则会将参数的分布式信息传递给对应的优化器状态。

`shard_fn` 的函数签名为:def shard_fn(accumulator_name, param, accumulator) -> sharded_accumulator。
``shard_fn`` 的函数签名为:def shard_fn(accumulator_name, param, accumulator) -> sharded_accumulator。


参数
Expand All @@ -18,7 +18,7 @@ shard_optimizer

返回
:::::::::
Optimizer:一个具有分布式视角的 `Optimizer` 对象。
Optimizer:一个具有分布式视角的 ``Optimizer`` 对象。


代码示例
Expand Down
6 changes: 3 additions & 3 deletions docs/api/paddle/distributed/to_distributed_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ to_distributed

返回
:::::::::
Model:一个具有分布式信息的 `paddle.nn.Layer` 对象,根据自动选择的最优分布式策略,可能包含分布式化的权重参数。
Model:一个具有分布式信息的 ``paddle.nn.Layer`` 对象,根据自动选择的最优分布式策略,可能包含分布式化的权重参数。

Optimizer:一个 `Optimizer` 对象,根据自动选择的最优分布式策略,可能包含分布式化的优化器状态。
Optimizer:一个 ``Optimizer`` 对象,根据自动选择的最优分布式策略,可能包含分布式化的优化器状态。

DataLoader:一个 `ShardDataloader` 对象。能够给后续的分布式训练提供输入数据。
DataLoader:一个 ``ShardDataloader`` 对象。能够给后续的分布式训练提供输入数据。


代码示例
Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/hypot_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ hypot
.. py:function:: paddle.hypot(x, y, name=None, *, out=None)


`hypot` 函数对于给定直角三角形直角边 `x`, `y` 实现斜边长度求解的计算;
``hypot`` 函数对于给定直角三角形直角边 ``x``, ``y`` 实现斜边长度求解的计算;

.. math::
out= \sqrt{x^2 + y^2}
Expand Down
4 changes: 2 additions & 2 deletions docs/api/paddle/linalg/cholesky_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ cholesky



计算一个对称正定矩阵或一批对称正定矩阵的 Cholesky 分解。如果 `upper` 是 `True`,
计算一个对称正定矩阵或一批对称正定矩阵的 Cholesky 分解。如果 ``upper`` 是 ``True``,
则分解形式为 :math:`A = U ^ {T} U`,返回的矩阵 U 是上三角矩阵。
否则,分解形式为 :math:`A = LL ^ {T}`,并返回矩阵 :math:`L` 是下三角矩阵。

Expand All @@ -21,7 +21,7 @@ cholesky

返回
::::::::::::
Tensor,与 `x` 具有相同形状和数据类型。它代表了 Cholesky 分解生成的三角矩阵。
Tensor,与 ``x`` 具有相同形状和数据类型。它代表了 Cholesky 分解生成的三角矩阵。

代码示例
::::::::::::
Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/masked_fill_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ masked_fill

返回一个 1-D 的 Tensor,Tensor 的值是根据 ``mask`` 信息,将 ``value`` 中的值填充到 ``x`` 中 ``mask`` 对应为 ``True`` 的位置,``mask`` 的数据类型是 bool。

下图展示了一个例子:假设我们有一个所有元素值为 1 的 3x3 矩阵 `x` 和一个相同尺寸的掩码矩阵 `Mask`,`Value` 值为 3。
下图展示了一个例子:假设我们有一个所有元素值为 1 的 3x3 矩阵 ``x`` 和一个相同尺寸的掩码矩阵 ``Mask``,``Value`` 值为 3。

.. image:: ../../images/api_legend/masked_fill.png
:width: 700
Expand Down
4 changes: 2 additions & 2 deletions docs/api/paddle/msort_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ msort

.. py:function:: paddle.msort(input: Tensor, *, out: Tensor | None = None)

沿输入 `Tensor` 的第 0 轴(`axis=0`)按升序对元素进行排序。
沿输入 ``Tensor`` 的第 0 轴(``axis=0``)按升序对元素进行排序。

该函数等价于 `paddle.sort(x, axis=0)`。
该函数等价于 ``paddle.sort(x, axis=0)``。

参数
::::::::::::
Expand Down
4 changes: 2 additions & 2 deletions docs/api/paddle/optimizer/lr/PiecewiseDecay_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ PiecewiseDecay
.. py:class:: paddle.optimizer.lr.PiecewiseDecay(boundaries, values, last_epoch=-1, verbose=False)


该接口提供分段设置学习率的策略。`boundaries` 表示学习率变化的边界步数,对应 epoch 的值,`values` 表示学习率变化的值。
该接口提供分段设置学习率的策略。``boundaries`` 表示学习率变化的边界步数,对应 epoch 的值,``values`` 表示学习率变化的值。

过程可以描述如下:

Expand Down Expand Up @@ -43,7 +43,7 @@ COPY-FROM: paddle.optimizer.lr.PiecewiseDecay
step(epoch=None)
'''''''''

step 函数需要在优化器的 `optimizer.step()` 函数之后调用,调用之后将会根据 epoch 数来更新学习率,更新之后的学习率将会在优化器下一轮更新参数时使用。
step 函数需要在优化器的 ``optimizer.step()`` 函数之后调用,调用之后将会根据 epoch 数来更新学习率,更新之后的学习率将会在优化器下一轮更新参数时使用。

**参数**

Expand Down
6 changes: 3 additions & 3 deletions docs/api/paddle/optimizer/lr/ReduceOnPlateau_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ ReduceOnPlateau

.. py:class:: paddle.optimizer.lr.ReduceOnPlateau(learning_rate, mode='min', factor=0.1, patience=10, threshold=1e-4, threshold_mode='rel', cooldown=0, min_lr=0, epsilon=1e-8, verbose=False)

`loss` 自适应的学习率衰减策略。默认情况下,当 ``loss`` 停止下降时,降低学习率。其思想是:一旦模型表现不再提升,将学习率降低 2-10 倍对模型的训练往往有益。
``loss`` 自适应的学习率衰减策略。默认情况下,当 ``loss`` 停止下降时,降低学习率。其思想是:一旦模型表现不再提升,将学习率降低 2-10 倍对模型的训练往往有益。

`loss` 是传入到该类方法 ``step`` 中的 ``metrics`` 参数,其可以是 float 或者 shape 为[]的 0-D Tensor 或 numpy\.ndarray。如果 loss 停止下降超过 ``patience`` 个 epoch,学习率将会衰减为 ``learning_rate * factor`` (特殊地,``mode`` 也可以被设置为 ``'max'``,此时逻辑相反)。
``loss`` 是传入到该类方法 ``step`` 中的 ``metrics`` 参数,其可以是 float 或者 shape 为[]的 0-D Tensor 或 numpy\.ndarray。如果 loss 停止下降超过 ``patience`` 个 epoch,学习率将会衰减为 ``learning_rate * factor`` (特殊地,``mode`` 也可以被设置为 ``'max'``,此时逻辑相反)。

此外,每降低一次学习率后,将会进入一个时长为 ``cooldown`` 个 epoch 的冷静期,在冷静期内,将不会监控 ``loss`` 的变化情况,也不会衰减。在冷静期之后,会继续监控 ``loss`` 的上升或下降。

Expand Down Expand Up @@ -40,7 +40,7 @@ COPY-FROM: paddle.optimizer.lr.ReduceOnPlateau
step(metrics, epoch=None)
'''''''''

step 函数需要在优化器的 `optimizer.step()` 函数之后调用,其根据传入的 metrics 调整 optimizer 中的学习率,调整后的学习率将会在下一个 ``step`` 时生效。
step 函数需要在优化器的 ``optimizer.step()`` 函数之后调用,其根据传入的 metrics 调整 optimizer 中的学习率,调整后的学习率将会在下一个 ``step`` 时生效。

**参数**

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/sparse/expm1_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ expm1

.. py:function:: paddle.sparse.expm1(x, name=None)

逐元素计算输入 :attr:`x` 的 `exp(x)-1` ,要求 输入 :attr:`x` 为 `SparseCooTensor` 或 `SparseCsrTensor` 。
逐元素计算输入 :attr:`x` 的 ``exp(x)-1`` ,要求 输入 :attr:`x` 为 ``SparseCooTensor`` 或 ``SparseCsrTensor`` 。

数学公式:

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/sparse/square_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ square
.. py:function:: paddle.sparse.square(x, name=None)


逐元素计算 :attr:`x` 的平方,要求 输入 :attr:`x` 为 `SparseCooTensor` 或 `SparseCsrTensor` 。
逐元素计算 :attr:`x` 的平方,要求 输入 :attr:`x` 为 ``SparseCooTensor`` 或 ``SparseCsrTensor`` 。

数学公式:

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/sparse/sum_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ sum
.. py:function:: paddle.sparse.sum(x, axis=None, dtype=None, keepdim=False, name=None)

计算给定维度 :attr:`axis` 上稀疏张量 :attr:`x` 元素的和。
输入 :attr:`x` 必须为稀疏压缩格式( `SparseCooTensor` 或 `SparseCsrTensor`)。
输入 :attr:`x` 必须为稀疏压缩格式( ``SparseCooTensor`` 或 ``SparseCsrTensor``)。

等式为:

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/sparse/tan_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ tan

.. py:function:: paddle.sparse.tan(x, name=None)

逐元素计算 :attr:`x` 的正切,要求 输入 :attr:`x` 为 `SparseCooTensor` 或 `SparseCsrTensor` 。
逐元素计算 :attr:`x` 的正切,要求 输入 :attr:`x` 为 ``SparseCooTensor`` 或 ``SparseCsrTensor`` 。

数学公式:

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/sparse/tanh_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ tanh
.. py:function:: paddle.sparse.tanh(x, name=None)


逐元素计算 :attr:`x` 的双曲正切,要求 输入 :attr:`x` 为 `SparseCooTensor` 或 `SparseCsrTensor` 。
逐元素计算 :attr:`x` 的双曲正切,要求 输入 :attr:`x` 为 ``SparseCooTensor`` 或 ``SparseCsrTensor`` 。

数学公式:

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/squeeze_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ squeeze
删除输入 Tensor 的 Shape 中尺寸为 1 的维度。如果指定了 axis,则会删除指定 axis 中尺寸为 1 的维度。如果没有指定 axis,那么所有等于 1 的维度都会被删除。

请注意,在动态图模式下,输出 Tensor 将与输入 Tensor 共享数据,并且没有 Tensor 数据拷贝的过程。
如果不希望输入与输出共享数据,请使用 `Tensor.clone` ,例如 `squeeze_clone_x = x.squeeze().clone()` 。
如果不希望输入与输出共享数据,请使用 ``Tensor.clone`` ,例如 ``squeeze_clone_x = x.squeeze().clone()`` 。

.. code-block:: text

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/static/IpuCompiledProgram_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ COPY-FROM: paddle.static.IpuCompiledProgram
compile(self, feed_list, fetch_list)
'''''''''

将 Program 进行编译,以便在 ipu 上运行。用户可以通过 `feed_list` 、`fetch_list` 传入计算图输入和输出的名字。
将 Program 进行编译,以便在 ipu 上运行。用户可以通过 ``feed_list`` 、``fetch_list`` 传入计算图输入和输出的名字。

**参数**

Expand Down
4 changes: 2 additions & 2 deletions docs/api/paddle/static/Program_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ state_dict(mode='all', scope=None)
**参数**

- **mode** (str,可选) - 获取何种持久性变量。目前支持以下选项:(1) ``opt``:获得优化器的持久性变量放在 ``dict`` 结构中;(2) ``param``:获得组网中的持久性变量放在 ``dict`` 结构中,不包含优化器中的持久性变量;(3) ``all``:获得组网和优化器中的持久性变量放在 dict 结构中;默认值为 ``all``。
- **scope** (Scope,可选) - 如果 scope 为 ``None``,通过 `paddle.static.global_scope()` 获取全局/默认作用域实例,并从中获取 ``state_dict``;否则从指定的 ``scope`` 获取 ``state_dict``。默认值为 ``None`` 。
- **scope** (Scope,可选) - 如果 scope 为 ``None``,通过 ``paddle.static.global_scope()`` 获取全局/默认作用域实例,并从中获取 ``state_dict``;否则从指定的 ``scope`` 获取 ``state_dict``。默认值为 ``None`` 。

**返回**

Expand All @@ -242,7 +242,7 @@ set_state_dict(state_dict, scope=None)
**参数**

- **state_dict** (dict) - 包含持久性变量的字典。键值是持久性变量的名字,值为持久性变量。
- **scope** (Scope,可选) - 如果 scope 为 ``None``,通过 `paddle.static.global_scope()` 获取全局/默认作用域实例,并将 ``state_dict`` 中久性变量设置到这个作用域中;否则将 ``state_dict`` 设置到指定的 ``scope`` 中。默认值为 ``None`` 。
- **scope** (Scope,可选) - 如果 scope 为 ``None``,通过 ``paddle.static.global_scope()`` 获取全局/默认作用域实例,并将 ``state_dict`` 中久性变量设置到这个作用域中;否则将 ``state_dict`` 设置到指定的 ``scope`` 中。默认值为 ``None`` 。

**返回**

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/static/nn/batch_norm_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ batch_norm
moving\_variance = moving\_variance * momentum + mini\_batch\_var * (1. - momentum)

moving_mean 和 moving_var 是训练过程中统计得到的全局均值和方差,在预测或者评估中使用。
`is_test` 参数只能用于测试或者评估阶段,如果想在训练阶段使用预训练模型的全局均值和方差的话,可以设置 `use_global_stats=True`。
``is_test`` 参数只能用于测试或者评估阶段,如果想在训练阶段使用预训练模型的全局均值和方差的话,可以设置 ``use_global_stats=True``。

当 use_global_stats = True 时,:math:`\mu_{\beta}` 和 :math:`\sigma_{\beta}^{2}` 不是一个 minibatch 的统计数据。它们是全局(或运行)统计数据(moving_mean 和 moving_variance),通常来自预先训练好的模型。训练和测试(或预测)具有相同的行为:

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/tan_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ tan
.. py:function:: paddle.tan(x, name=None, *, out=None)
三角函数 tangent。

输入范围是 `(k*pi-pi/2, k*pi+pi/2)`,输出范围是 `[-inf, inf]` 。
输入范围是 ``(k*pi-pi/2, k*pi+pi/2)``,输出范围是 ``[-inf, inf]`` 。

.. math::
out = tan(x)
Expand Down
4 changes: 2 additions & 2 deletions docs/api/paddle/triu_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ triu
.. py:function:: paddle.triu(x, diagonal=0, name=None, *, out=None)


返回输入矩阵 `input` 的上三角部分,其余部分被设为 0。
返回输入矩阵 ``input`` 的上三角部分,其余部分被设为 0。
矩形的上三角部分被定义为对角线上和上方的元素。

参数
Expand All @@ -22,7 +22,7 @@ triu

返回
:::::::::
Tensor,数据类型与输入 `input` 数据类型一致。
Tensor,数据类型与输入 ``input`` 数据类型一致。

代码示例
:::::::::
Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/unsqueeze_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ unsqueeze
向输入 Tensor 的 Shape 中一个或多个位置(axis)插入尺寸为 1 的维度。

请注意,在动态图模式下,输出 Tensor 将与输入 Tensor 共享数据,并且没有 Tensor 数据拷贝的过程。
如果不希望输入与输出共享数据,请使用 `Tensor.clone`,例如 `unsqueeze_clone_x = x.unsqueeze(-1).clone()` 。
如果不希望输入与输出共享数据,请使用 ``Tensor.clone``,例如 ``unsqueeze_clone_x = x.unsqueeze(-1).clone()`` 。

下图展示了一个 Shape 为 [2, 3] 的 Tensor 如何使用 ``unsqueeze`` 方法在最后一个位置(axis = 2)增加一个维度,从二维变成三维。

Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/utils/cpp_extension/load_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ load

此接口将即时编译(Just-In-Time)传入的自定义 OP 对应的 cpp 和 cuda 源码文件,返回一个包含自定义算子 API 的 ``Module`` 对象。

其通过子进程的方式,在后台隐式地执行源码文件编译、符号链接、动态库生成、组网 API 接口生成等一系列过程。不需要本地预装 CMake 或者 Ninja 等工具命令,仅需必要的编译器命令环境,Linux 下需安装版本不低于 5.4 的 GCC,并软链到 `/usr/bin/cc` ,Windows 下需安装版本不低于 2017 的 Visual Studio;若编译支持 GPU 设备的算子,则需要提前安装 CUDA,其中自带 `nvcc` 编译环境。
其通过子进程的方式,在后台隐式地执行源码文件编译、符号链接、动态库生成、组网 API 接口生成等一系列过程。不需要本地预装 CMake 或者 Ninja 等工具命令,仅需必要的编译器命令环境,Linux 下需安装版本不低于 5.4 的 GCC,并软链到 ``/usr/bin/cc`` ,Windows 下需安装版本不低于 2017 的 Visual Studio;若编译支持 GPU 设备的算子,则需要提前安装 CUDA,其中自带 ``nvcc`` 编译环境。

在编译前会执行 `ABI 兼容性检查 <https://gcc.gnu.org/onlinedocs/libstdc++/manual/abi.html>`_ ,即检查编译器版本是否与本地安装的 Paddle 一致。如在 Linux 下,对于 CUDA 10.1 以上的 Paddle 默认使用 GCC 8.2 编译,则本地 ``cc`` 对应的编译器版本也需为 8.2,在 Windows 下,Paddle 使用 Visualt Studio 2017 编译,则本地也需安装
大于 2017 的 Visual Studio,如果不满足,则可能由于 ABI 兼容性原因引发自定义 OP 编译或执行报错。Mac 下默认使用 clang 进行编译,无 ABI 兼容性问题。
Expand Down
2 changes: 1 addition & 1 deletion docs/api/paddle/vision/ops/box_coder_cn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ box_coder

返回
::::::::::::
- **output_box** (Tensor) - 解码或编码结果。数据类型为 float32 或 float64。当 code_type 为 `encode_center_size` 时,形状为 [N, M, 4] 的编码结果, N 为目标框的个数, M 为先验框的个数。当 code_type 为 `decode_center_size` 时,形状为 [N, M, 4] 的解码结果,形状与输入目标框相同。
- **output_box** (Tensor) - 解码或编码结果。数据类型为 float32 或 float64。当 code_type 为 ``encode_center_size`` 时,形状为 [N, M, 4] 的编码结果, N 为目标框的个数, M 为先验框的个数。当 code_type 为 ``decode_center_size`` 时,形状为 [N, M, 4] 的解码结果,形状与输入目标框相同。


代码示例
Expand Down
Loading