From cf7c431f2ee7454e5b138bc3339beabf3e65eb75 Mon Sep 17 00:00:00 2001 From: zhangyuqin1998 <75946871+zhangyuqin1998@users.noreply.github.com> Date: Mon, 3 Apr 2023 10:32:17 +0800 Subject: [PATCH] rename_batch_norm_grad_grad (#52372) --- paddle/phi/api/yaml/legacy_backward.yaml | 2 +- paddle/phi/kernels/cpu/batch_norm_grad_kernel.cc | 2 +- paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu | 4 ++-- paddle/phi/ops/compat/batch_norm_sig.cc | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/paddle/phi/api/yaml/legacy_backward.yaml b/paddle/phi/api/yaml/legacy_backward.yaml index 6736c379dfc..ddb2863cf48 100755 --- a/paddle/phi/api/yaml/legacy_backward.yaml +++ b/paddle/phi/api/yaml/legacy_backward.yaml @@ -115,7 +115,7 @@ func : GeneralTernaryGradInferMeta param : [x, scale, x] kernel : - func : batch_norm_grad_grad + func : batch_norm_double_grad data_type : x optional : out_mean, out_variance, grad_x_grad, grad_scale_grad, grad_bias_grad inplace : (grad_out -> grad_out_grad) diff --git a/paddle/phi/kernels/cpu/batch_norm_grad_kernel.cc b/paddle/phi/kernels/cpu/batch_norm_grad_kernel.cc index c2da486e9f7..9eec65e92a3 100644 --- a/paddle/phi/kernels/cpu/batch_norm_grad_kernel.cc +++ b/paddle/phi/kernels/cpu/batch_norm_grad_kernel.cc @@ -662,7 +662,7 @@ PD_REGISTER_KERNEL(batch_norm_grad_raw, float, double) {} -PD_REGISTER_KERNEL(batch_norm_grad_grad, +PD_REGISTER_KERNEL(batch_norm_double_grad, CPU, ALL_LAYOUT, phi::BatchNormDoubleGradKernel, diff --git a/paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu b/paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu index 3b09890e224..ede24587449 100644 --- a/paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu +++ b/paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu @@ -1345,14 +1345,14 @@ PD_REGISTER_KERNEL(batch_norm_grad_raw, #endif #ifdef PADDLE_WITH_HIP -PD_REGISTER_KERNEL(batch_norm_grad_grad, +PD_REGISTER_KERNEL(batch_norm_double_grad, GPU, ALL_LAYOUT, phi::BatchNormDoubleGradKernel, float, double) {} #else -PD_REGISTER_KERNEL(batch_norm_grad_grad, +PD_REGISTER_KERNEL(batch_norm_double_grad, GPU, ALL_LAYOUT, phi::BatchNormDoubleGradKernel, diff --git a/paddle/phi/ops/compat/batch_norm_sig.cc b/paddle/phi/ops/compat/batch_norm_sig.cc index ff7a5821425..5f6efcd9ce7 100644 --- a/paddle/phi/ops/compat/batch_norm_sig.cc +++ b/paddle/phi/ops/compat/batch_norm_sig.cc @@ -79,7 +79,7 @@ KernelSignature BatchNormGradOpArgumentMapping( KernelSignature BatchNormGradGradOpArgumentMapping( const ArgumentMappingContext& ctx) { - return KernelSignature("batch_norm_grad_grad", + return KernelSignature("batch_norm_double_grad", {"X", "Scale", "Mean", -- GitLab