From 5fc8de449a3b59e6e5f1fbc5a95f8e9b38636c07 Mon Sep 17 00:00:00 2001 From: qingqing01 Date: Mon, 19 Aug 2019 23:40:05 +0800 Subject: [PATCH] Remove warning in batch_norm_op (#19260) --- paddle/fluid/operators/batch_norm_op.cc | 4 ++-- paddle/fluid/operators/batch_norm_op.cu | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/paddle/fluid/operators/batch_norm_op.cc b/paddle/fluid/operators/batch_norm_op.cc index f6295337d1..56111c6633 100644 --- a/paddle/fluid/operators/batch_norm_op.cc +++ b/paddle/fluid/operators/batch_norm_op.cc @@ -245,8 +245,8 @@ class BatchNormKernel variance_out->mutable_data(ctx.GetPlace()), C); if ((N * sample_size) == 1) { - LOG(WARNING) << "Only 1 element in normalization dimension, " - << "we skip the batch norm calculation, let y = x."; + // Only 1 element in normalization dimension, + // we skip the batch norm calculation, let y = x. framework::TensorCopy(*x, ctx.GetPlace(), y); return; } diff --git a/paddle/fluid/operators/batch_norm_op.cu b/paddle/fluid/operators/batch_norm_op.cu index 9b50a4a61a..49ff7069ba 100644 --- a/paddle/fluid/operators/batch_norm_op.cu +++ b/paddle/fluid/operators/batch_norm_op.cu @@ -152,8 +152,8 @@ class BatchNormKernel functor(dev_ctx, saved_variance, static_cast>(0)); if ((N * H * W * D) == 1) { - LOG(WARNING) << "Only 1 element in normalization dimension, " - << "we skip the batch norm calculation, let y = x."; + // Only 1 element in normalization dimension, + // skip the batch norm calculation, let y = x. framework::TensorCopy(*x, ctx.GetPlace(), y); } else { double this_factor = 1. - momentum; -- GitLab