From 345901ae863c340b90fd08896bd4cdf60f7e9da8 Mon Sep 17 00:00:00 2001 From: acgist <289547414@qq.com> Date: Tue, 22 Oct 2024 19:52:22 +0800 Subject: [PATCH] [*] format --- model/include/lifuren/Model.hpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/model/include/lifuren/Model.hpp b/model/include/lifuren/Model.hpp index 022dcc6..da2674a 100644 --- a/model/include/lifuren/Model.hpp +++ b/model/include/lifuren/Model.hpp @@ -217,7 +217,7 @@ void lifuren::Model::train(size_t epoch) { auto z = std::chrono::system_clock::now(); if(this->params.classify) { SPDLOG_INFO( - "当前训练第 {} 轮,损失值为:{},正确率为:{} / {},耗时:{}。", + "当前训练第 {} 轮,损失值为:{:.6f},正确率为:{} / {},耗时:{}。", epoch, loss_val / batch_count, accu_val, @@ -226,7 +226,7 @@ void lifuren::Model::train(size_t epoch) { ); } else { SPDLOG_INFO( - "当前训练第 {} 轮,损失值为:{},耗时:{}。", + "当前训练第 {} 轮,损失值为:{:.6f},耗时:{}。", epoch, loss_val / batch_count, std::chrono::duration_cast((z - a)).count() @@ -262,7 +262,7 @@ void lifuren::Model::val(size_t epoch) { auto z = std::chrono::system_clock::now(); if(this->params.classify) { SPDLOG_INFO( - "当前验证第 {} 轮,损失值为:{},正确率为:{} / {},耗时:{}。", + "当前验证第 {} 轮,损失值为:{:.6f},正确率为:{} / {},耗时:{}。", epoch, loss_val / batch_count, accu_val, @@ -271,7 +271,7 @@ void lifuren::Model::val(size_t epoch) { ); } else { SPDLOG_INFO( - "当前验证第 {} 轮,损失值为:{},耗时:{}。", + "当前验证第 {} 轮,损失值为:{:.6f},耗时:{}。", epoch, loss_val / batch_count, std::chrono::duration_cast((z - a)).count() @@ -307,7 +307,7 @@ void lifuren::Model::test() { auto z = std::chrono::system_clock::now(); if(this->params.classify) { SPDLOG_INFO( - "当前测试损失值为:{},正确率为:{} / {},耗时:{}。", + "当前测试损失值为:{:.6f},正确率为:{} / {},耗时:{}。", loss_val / batch_count, accu_val, data_val, @@ -315,7 +315,7 @@ void lifuren::Model::test() { ); } else { SPDLOG_INFO( - "当前测试损失值为:{},耗时:{}。", + "当前测试损失值为:{:.6f},耗时:{}。", loss_val / batch_count, std::chrono::duration_cast((z - a)).count() );