From a25a2c58b7b84035790c44a1934cc255d5dca28f Mon Sep 17 00:00:00 2001 From: Michal Kravcenko <michal.kravcenko@vsb.cz> Date: Wed, 20 Feb 2019 14:03:47 +0100 Subject: [PATCH] ADD: added two new learning methods and a new learning method able to cycle through user defined sequence of learning methods --- src/CMakeLists.txt | 3 ++- src/message.h | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index bce60ecf..326e1d42 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -53,13 +53,14 @@ if ("${BUILD_LIB}" STREQUAL "yes") NetConnection/ConnectionFunctionIdentity.cpp LearningMethods/ParticleSwarm.cpp LearningMethods/GradientDescent.cpp + LearningMethods/GradientDescentBB.cpp DataSet/DataSet.cpp ErrorFunction/ErrorFunctions.cpp Solvers/DESolver.cpp CSVReader/CSVReader.cpp CrossValidator/CrossValidator.cpp NormalizationStrategy/NormalizationStrategy.cpp - ) + LearningMethods/GradientDescentSingleItem.cpp LearningMethods/GradientDescentSingleItem.h LearningMethods/LearningSequence.cpp LearningMethods/LearningSequence.h) # FileSystem C++ library - has to be linked manually in GCC-8 set(CXX_FILESYSTEM_LIB "") diff --git a/src/message.h b/src/message.h index aafadbd1..7fcb06f5 100644 --- a/src/message.h +++ b/src/message.h @@ -11,13 +11,13 @@ #define COL_WIDTH 20 #define R_ALIGN std::setw(COL_WIDTH) << std::right -#define COUT_INFO(inp) std::cout << std::flush << "INFO: " << inp << std::flush +#define COUT_INFO(inp) std::cout << std::flush << std::fixed << std::setprecision(12) << "INFO: " << inp << std::flush #ifdef L4N_DEBUG -#define COUT_DEBUG(inp) assert(std::cerr << std::flush << std::fixed << std::setprecision(6) << "DEBUG: " << inp << std::flush) +#define COUT_DEBUG(inp) assert(std::cerr << std::flush << std::fixed << std::setprecision(12) << "DEBUG: " << inp << std::flush) #define WRITE_TO_OFS_DEBUG(ofs, msg) { if(ofs && ofs->is_open())\ - *ofs << std::fixed << std::setprecision(6) << "DEBUG: " << msg;\ + *ofs << std::fixed << std::setprecision(12) << "DEBUG: " << msg;\ } #else #define COUT_DEBUG(inp) -- GitLab