8 inline static const std::size_t size = 100;
9 inline static const std::string title =
"LEARNING PROGRESS BAR";
14 static void draw(
float progress){
15 std::cout<<
"\033[2J\033[H";
17 std::cout<<
"\033[36m";
18 for(std::size_t i=0;i<size-title.length();i++){
20 if (i == (size - title.length())/2){
21 std::cout<<
"\033[31m"<<
"\033[5m"<<
"\033[1m"<<title<<
"\033[25m"<<
"\033[22m";
22 std::cout<<
"\033[36m";
27 std::cout<<
"\033[92m";
28 progress = (std::size_t)(progress * size);
30 for(i=0;i<progress;i++){
33 std::cout<<
"\033[31m";
39 std::cout<<
"\033[36m";
40 for(std::size_t i=0;i<size;i++){
Class used to write progress bars in the terminal.
Definition ProgressBar.hpp:7
static void draw(float progress)
Draws the progress bar.
Definition ProgressBar.hpp:14
Definition LeakyRelu.hpp:4