diff --git a/paddle/fluid/operators/sampling_id_op.cc b/paddle/fluid/operators/sampling_id_op.cc index 20e3d43217d7f96b0cc03ce7f2391f0da1e4766a..b9e3b0372d6aea2c043d9ed1c15d4016af05d2b4 100644 --- a/paddle/fluid/operators/sampling_id_op.cc +++ b/paddle/fluid/operators/sampling_id_op.cc @@ -58,7 +58,8 @@ SamplingId Operator. namespace ops = paddle::operators; REGISTER_OP_CUDA_KERNEL( - slice, ops::SamplingIdKernel, + sampling_id, + ops::SamplingIdKernel, ops::SamplingIdKernel, ops::SamplingIdKernel, ops::SamplingIdKernel); diff --git a/paddle/fluid/operators/sampling_id_op.cu b/paddle/fluid/operators/sampling_id_op.cu index 4fa10de2cde2e60ab0d9ddb438427d5fd9ac13c6..f82ba68ce4fb08e7069baa267dd22c9cbda1cd80 100644 --- a/paddle/fluid/operators/sampling_id_op.cu +++ b/paddle/fluid/operators/sampling_id_op.cu @@ -30,11 +30,11 @@ class SamplingIdOp : public framework::OperatorWithKernel { } // namespace paddle namespace ops = paddle::operators; -REGISTER_OPERATOR(samplingid, ops::SamplingIdOp, ops::SamplingIdOpMaker, +REGISTER_OPERATOR(sampling_id, ops::SamplingIdOp, ops::SamplingIdOpMaker, paddle::framework::EmptyGradOpMaker); REGISTER_OP_CPU_KERNEL( - slice, ops::SamplingIdKernel, + sampling_id, ops::SamplingIdKernel, ops::SamplingIdKernel, ops::SamplingIdKernel, ops::SamplingIdKernel);