KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Macros | Enumerations
logging_settings.hpp File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define RESET   "\033[0m"
 
#define BLACK   "\033[30m"
 
#define RED   "\033[31m"
 
#define GREEN   "\033[32m"
 
#define YELLOW   "\033[33m"
 
#define BLUE   "\033[34m"
 
#define MAGENTA   "\033[35m"
 
#define CYAN   "\033[36m"
 
#define WHITE   "\033[37m"
 
#define DK_GREY   "\033[90m"
 
#define LT_GREY   "\033[37m"
 
#define LT_RED   "\033[91m"
 
#define LT_GREEN   "\033[92m"
 
#define LT_YELLOW   "\033[93m"
 
#define LT_BLUE   "\033[94m"
 
#define LT_MAGENTA   "\033[95m"
 
#define LT_CYAN   "\033[96m"
 
#define BOLD   "\033[1m"
 
#define DIM   "\033[2m"
 
#define UNDERLINE   "\033[4m"
 
#define RESET_LOG_SETTINGS    std::cout << RESET << std::endl;
 
#define LOG_GENERAL(color, message, variable)
 
#define LOG_DEBUG(variable)
 
#define LOG_INFO(variable)
 
#define LOG_WARNING(variable)
 
#define LOG_DEBUG_HEADER(header, variable)
 
#define LOG_INFO_HEADER(header, variable)
 
#define LOG_WARNING_HEADER(header, variable)
 
#define DEBUG_MSG(message)
 
#define INFO_MSG(message)
 
#define WARNING_MSG(message)
 
#define ERROR_MSG(message, function)
 
#define TENSOR_LOG_SETTINGS
 
#define LOG_MATRIX_PRETTY(matrix)
 
#define LOG_VECTOR_PRETTY(vector)
 
#define LOG_VECTOR3(array)
 
#define LOG_VECTOR2(array)
 
#define LOG_SCALAR(scalar)
 
#define CONDITION_LOG_SETTINGS
 
#define LOG_CONDITION_HEADER(master, slave)
 

Enumerations

enum  LoggingLevel { none , info_warnings , system_matrices , debug }
 

Macro Definition Documentation

◆ BLACK

#define BLACK   "\033[30m"

◆ BLUE

#define BLUE   "\033[34m"

◆ BOLD

#define BOLD   "\033[1m"

◆ CONDITION_LOG_SETTINGS

#define CONDITION_LOG_SETTINGS
Value:
std::cout << BLUE << "Condition : " << std::endl; \
std::cout << LT_BLUE;\
#define LT_BLUE
Definition: logging_settings.hpp:32
#define BLUE
Definition: logging_settings.hpp:23

◆ CYAN

#define CYAN   "\033[36m"

◆ DEBUG_MSG

#define DEBUG_MSG (   message)
Value:
std::cout << BOLD << GREEN << UNDERLINE << "DEBUG" << RESET << std::endl;\
std::cout << BOLD << GREEN << message << std::endl;\
RESET_LOG_SETTINGS
#define BOLD
Definition: logging_settings.hpp:37
#define UNDERLINE
Definition: logging_settings.hpp:39
#define RESET
Definition: logging_settings.hpp:18
#define GREEN
Definition: logging_settings.hpp:21

◆ DIM

#define DIM   "\033[2m"

◆ DK_GREY

#define DK_GREY   "\033[90m"

◆ ERROR_MSG

#define ERROR_MSG (   message,
  function 
)
Value:
std::cout << BOLD << RED << UNDERLINE << "ERROR from " << function << RESET << std::endl;\
std::cout << BOLD << RED << message << std::endl;\
RESET_LOG_SETTINGS
#define RED
Definition: logging_settings.hpp:20

◆ GREEN

#define GREEN   "\033[32m"

◆ INFO_MSG

#define INFO_MSG (   message)
Value:
std::cout << BOLD << DK_GREY << UNDERLINE << "INFO : " << RESET << std::endl;\
std::cout << BOLD << DK_GREY << message << std::endl;\
RESET_LOG_SETTINGS
#define DK_GREY
Definition: logging_settings.hpp:27

◆ LOG_CONDITION_HEADER

#define LOG_CONDITION_HEADER (   master,
  slave 
)
Value:
CONDITION_LOG_SETTINGS \
std::cout << "|_ Master : "; \
for( unsigned int i = 0; i < master.PointsNumber( ) - 1; ++i ) \
std::cout << master[i].Id( ) << ", "; \
std::cout << master[master.PointsNumber( ) - 1].Id( ) << "\n";\
std::cout << "|_ Slave : "; \
for( unsigned int i = 0; i < master.PointsNumber( ) - 1; ++i ) \
std::cout << slave[i].Id( ) << ", "; \
std::cout << slave[slave.PointsNumber( ) - 1].Id( ) << "\n";\
RESET_LOG_SETTINGS
integer i
Definition: TensorModule.f:17

◆ LOG_DEBUG

#define LOG_DEBUG (   variable)
Value:
std::cout << BOLD << YELLOW << #variable << " : " << LT_YELLOW << variable; \
RESET_LOG_SETTINGS
#define YELLOW
Definition: logging_settings.hpp:22
#define LT_YELLOW
Definition: logging_settings.hpp:31

◆ LOG_DEBUG_HEADER

#define LOG_DEBUG_HEADER (   header,
  variable 
)
Value:
std::cout << BOLD << UNDERLINE << YELLOW << #header; \
RESET_LOG_SETTINGS \
std::cout << BOLD << YELLOW << #variable << " : " << LT_YELLOW << variable\
RESET_LOG_SETTINGS

◆ LOG_GENERAL

#define LOG_GENERAL (   color,
  message,
  variable 
)
Value:
std::cout << color << message << variable; \
RESET_LOG_SETTINGS
color
Definition: all_t_win_vs_m_fixed_error.py:230

◆ LOG_INFO

#define LOG_INFO (   variable)
Value:
std::cout << BOLD << GREEN << #variable << " : " << LT_GREEN << variable; \
RESET_LOG_SETTINGS
#define LT_GREEN
Definition: logging_settings.hpp:30

◆ LOG_INFO_HEADER

#define LOG_INFO_HEADER (   header,
  variable 
)
Value:
std::cout << BOLD << UNDERLINE << GREEN << #header; \
RESET_LOG_SETTINGS \
std::cout << BOLD << GREEN << #variable << " : " << LT_GREEN << variable\
RESET_LOG_SETTINGS

◆ LOG_MATRIX_PRETTY

#define LOG_MATRIX_PRETTY (   matrix)
Value:
TENSOR_LOG_SETTINGS \
std::cout << #matrix << " : [ " << matrix.size1() << " x " << matrix.size2() << " ] :" << std::endl;\
for ( unsigned int i = 0; i < matrix.size1( ); ++i )\
{\
for ( unsigned int j = 0; j < matrix.size2( ); ++j )\
std::cout << std::scientific << matrix(i,j) << "\t";\
std::cout << std::endl;\
}\
RESET_LOG_SETTINGS
int j
Definition: quadrature.py:648

◆ LOG_SCALAR

#define LOG_SCALAR (   scalar)
Value:
TENSOR_LOG_SETTINGS \
std::cout << #scalar << " : " << std::scientific << scalar;\
RESET_LOG_SETTINGS

◆ LOG_VECTOR2

#define LOG_VECTOR2 (   array)
Value:
TENSOR_LOG_SETTINGS \
std::cout << #array << " : " << std::scientific << array[0] << ", " << std::scientific << array[1];\
RESET_LOG_SETTINGS

◆ LOG_VECTOR3

#define LOG_VECTOR3 (   array)
Value:
TENSOR_LOG_SETTINGS \
std::cout << #array << " : " << std::scientific << array[0] << ", " << std::scientific << array[1] << ", " << std::scientific << array[2];\
RESET_LOG_SETTINGS

◆ LOG_VECTOR_PRETTY

#define LOG_VECTOR_PRETTY (   vector)
Value:
TENSOR_LOG_SETTINGS \
std::cout << #vector << " : " << std::scientific << vector;\
RESET_LOG_SETTINGS

◆ LOG_WARNING

#define LOG_WARNING (   variable)
Value:
std::cout << BOLD << RED << #variable << " : " << LT_RED << variable; \
RESET_LOG_SETTINGS
#define LT_RED
Definition: logging_settings.hpp:29

◆ LOG_WARNING_HEADER

#define LOG_WARNING_HEADER (   header,
  variable 
)
Value:
std::cout << BOLD << UNDERLINE << RED << #header; \
RESET_LOG_SETTINGS \
std::cout << BOLD << RED << #variable << " : " << LT_RED << variable\
RESET_LOG_SETTINGS

◆ LT_BLUE

#define LT_BLUE   "\033[94m"

◆ LT_CYAN

#define LT_CYAN   "\033[96m"

◆ LT_GREEN

#define LT_GREEN   "\033[92m"

◆ LT_GREY

#define LT_GREY   "\033[37m"

◆ LT_MAGENTA

#define LT_MAGENTA   "\033[95m"

◆ LT_RED

#define LT_RED   "\033[91m"

◆ LT_YELLOW

#define LT_YELLOW   "\033[93m"

◆ MAGENTA

#define MAGENTA   "\033[35m"

◆ RED

#define RED   "\033[31m"

◆ RESET

#define RESET   "\033[0m"

◆ RESET_LOG_SETTINGS

#define RESET_LOG_SETTINGS    std::cout << RESET << std::endl;

◆ TENSOR_LOG_SETTINGS

#define TENSOR_LOG_SETTINGS
Value:
std::cout << CYAN;\
std::cout.precision(2);\
#define CYAN
Definition: logging_settings.hpp:25

◆ UNDERLINE

#define UNDERLINE   "\033[4m"

◆ WARNING_MSG

#define WARNING_MSG (   message)
Value:
std::cout << BOLD << YELLOW << UNDERLINE << "WARNING" << RESET << std::endl;\
std::cout << BOLD << YELLOW << message << std::endl;\
RESET_LOG_SETTINGS

◆ WHITE

#define WHITE   "\033[37m"

◆ YELLOW

#define YELLOW   "\033[33m"

Enumeration Type Documentation

◆ LoggingLevel

Enumerator
none 
info_warnings 
system_matrices 
debug