diff --git a/develop/doc/_sources/howto/dev/new_op_en.md.txt b/develop/doc/_sources/howto/dev/new_op_en.md.txt index 57ff7caad19cc6bf2e4a052d306d4fc303c8875d..1e88e1f5b4df710f1b69f0305d8d8a2921c4249a 100644 --- a/develop/doc/_sources/howto/dev/new_op_en.md.txt +++ b/develop/doc/_sources/howto/dev/new_op_en.md.txt @@ -205,7 +205,7 @@ The definition of its corresponding backward operator, if applicable, is similar - `REGISTER_OP` registers the `ops::MulOp` class, type named `mul`, its type `ProtoMaker` is `ops::MulOpMaker`, registering `ops::MulOpGrad` as `mul_grad`. - `REGISTER_OP_WITHOUT_GRADIENT` registers an operator without gradient. - - `REGISTER_OP_CPU_KERNEL` registers `ops::MulKernel` class and specialized template types `paddle::platform::CPUPlace` and `float`, which also registers `ops::MulKernel`. + - `REGISTER_OP_CPU_KERNEL` registers `ops::MulKernel` class and specialized template types `paddle::platform::CPUPlace` and `float`, which also registers `ops::MulGradKernel`. - Registering GPU Kernel in `.cu` files diff --git a/develop/doc/howto/dev/new_op_en.html b/develop/doc/howto/dev/new_op_en.html index 51559bad019bcfdc45ce9a9484fe6279ad50041b..5def40c6adfdf54ff84c288d7750ba1b4f6ddbe8 100644 --- a/develop/doc/howto/dev/new_op_en.html +++ b/develop/doc/howto/dev/new_op_en.html @@ -359,7 +359,7 @@ Registering the Op | Ops are registered in
  • REGISTER_OP registers the ops::MulOp class, type named mul, its type ProtoMaker is ops::MulOpMaker, registering ops::MulOpGrad as mul_grad.
  • REGISTER_OP_WITHOUT_GRADIENT registers an operator without gradient.
  • -
  • REGISTER_OP_CPU_KERNEL registers ops::MulKernel class and specialized template types paddle::platform::CPUPlace and float, which also registers ops::MulKernel.
  • +
  • REGISTER_OP_CPU_KERNEL registers ops::MulKernel class and specialized template types paddle::platform::CPUPlace and float, which also registers ops::MulGradKernel.
  • diff --git a/develop/doc_cn/_sources/howto/dev/new_op_cn.md.txt b/develop/doc_cn/_sources/howto/dev/new_op_cn.md.txt index 9d3d02ffc3116ebec537ab9b890eafccad196ed0..c823d7e9fcd63dd7719ac1403952b03c2d2f03c0 100644 --- a/develop/doc_cn/_sources/howto/dev/new_op_cn.md.txt +++ b/develop/doc_cn/_sources/howto/dev/new_op_cn.md.txt @@ -206,7 +206,7 @@ MulOp(const std::string &type, const framework::VariableNameMap &inputs, - `REGISTER_OP` : 注册`ops::MulOp`类,类型名为`mul`,该类的`ProtoMaker`为`ops::MulOpMaker`,注册`ops::MulOpGrad`,类型名为`mul_grad`。 - `REGISTER_OP_WITHOUT_GRADIENT` : 用于注册没有反向的Op。 - - `REGISTER_OP_CPU_KERNEL` :注册`ops::MulKernel`类,并特化模板参数为`paddle::platform::CPUPlace`和`float`类型,同理,注册`ops::MulKernel`类。 + - `REGISTER_OP_CPU_KERNEL` :注册`ops::MulKernel`类,并特化模板参数为`paddle::platform::CPUPlace`和`float`类型,同理,注册`ops::MulGradKernel`类。 - 在 `.cu`文件中注册GPU Kernel。 diff --git a/develop/doc_cn/howto/dev/new_op_cn.html b/develop/doc_cn/howto/dev/new_op_cn.html index 162cf1ff7ba2256b2cda5215d86309c6278b38f7..1956d080dadbf8fbfb64fbaf6b61eb8b4d17ef79 100644 --- a/develop/doc_cn/howto/dev/new_op_cn.html +++ b/develop/doc_cn/howto/dev/new_op_cn.html @@ -373,7 +373,7 @@ Kernel实现 | CPU、GPU共享Kernel实现在
  • REGISTER_OP : 注册ops::MulOp类,类型名为mul,该类的ProtoMakerops::MulOpMaker,注册ops::MulOpGrad,类型名为mul_grad
  • REGISTER_OP_WITHOUT_GRADIENT : 用于注册没有反向的Op。
  • -
  • REGISTER_OP_CPU_KERNEL :注册ops::MulKernel类,并特化模板参数为paddle::platform::CPUPlacefloat类型,同理,注册ops::MulKernel类。
  • +
  • REGISTER_OP_CPU_KERNEL :注册ops::MulKernel类,并特化模板参数为paddle::platform::CPUPlacefloat类型,同理,注册ops::MulGradKernel类。