From ff9e531bd9d70fa9a8397aa74252ee2caf96a1b9 Mon Sep 17 00:00:00 2001 From: Yu Yang Date: Tue, 6 Nov 2018 12:17:35 +0800 Subject: [PATCH] style(platform): disable warning when cuda cc not matched (#14029) Warning only at first when CUDA CC not matched. test=develop --- paddle/fluid/platform/device_context.cc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/paddle/fluid/platform/device_context.cc b/paddle/fluid/platform/device_context.cc index 924810bd618..2c7f6c9d5f1 100644 --- a/paddle/fluid/platform/device_context.cc +++ b/paddle/fluid/platform/device_context.cc @@ -222,12 +222,12 @@ CUDADeviceContext::CUDADeviceContext(CUDAPlace place) driver_version_ = GetCUDADriverVersion(place_.device); runtime_version_ = GetCUDARuntimeVersion(place_.device); - LOG(INFO) << "device: " << place_.device - << ", CUDA Capability: " << compute_capability_ - << ", Driver Version: " << driver_version_ / 1000 << "." - << (driver_version_ % 100) / 10 - << ", Runtime Version: " << runtime_version_ / 1000 << "." - << (runtime_version_ % 100) / 10; + LOG_FIRST_N(WARNING, 1) << "Please NOTE: device: " << place_.device + << ", CUDA Capability: " << compute_capability_ + << ", Driver Version: " << driver_version_ / 1000 + << "." << (driver_version_ % 100) / 10 + << ", Runtime Version: " << runtime_version_ / 1000 + << "." << (runtime_version_ % 100) / 10; callback_manager_.reset(new StreamCallbackManager(stream_)); } -- GitLab