Add stratified and discretize to b_manage list

This commit is contained in:
2024-04-11 11:45:43 +02:00
parent 78b8a8ae66
commit ad168d13ba
2 changed files with 6 additions and 2 deletions

View File

@@ -206,11 +206,11 @@ namespace platform {
//
int maxModel = results.maxModelSize();
int maxTitle = results.maxTitleSize();
std::vector<int> header_lengths = { 3, 10, maxModel, 10, 9, 12, 3, 7, maxTitle };
std::vector<int> header_lengths = { 3, 10, maxModel, 10, 9, 12, 2, 3, 7, maxTitle };
std::cout << Colors::RESET();
std::string arrow_dn = Symbols::down_arrow + " ";
std::string arrow_up = Symbols::up_arrow + " ";
std::vector<std::string> header_labels = { " #", "Date", "Model", "Score Name", "Score", "Platform", "C/P", "Time", "Title" };
std::vector<std::string> header_labels = { " #", "Date", "Model", "Score Name", "Score", "Platform", "SD", "C/P", "Time", "Title" };
std::vector<std::string> sort_fields = { "Date", "Model", "Score", "Time" };
for (int i = 0; i < header_labels.size(); i++) {
std::string suffix = "", color = Colors::GREEN();

View File

@@ -82,6 +82,9 @@ namespace platform {
{
auto tmp = ConfigLocale();
std::stringstream oss;
std::string s = data["stratified"].get<bool>() ? "S" : "";
std::string d = data["discretized"].get<bool>() ? "D" : "";
std::string sd = s + d;
auto duration = data["duration"].get<double>();
double durationShow = duration > 3600 ? duration / 3600 : duration > 60 ? duration / 60 : duration;
std::string durationUnit = duration > 3600 ? "h" : duration > 60 ? "m" : "s";
@@ -90,6 +93,7 @@ namespace platform {
oss << std::setw(10) << std::left << data["score_name"].get<std::string>() << " ";
oss << std::right << std::setw(9) << std::setprecision(7) << std::fixed << score << " ";
oss << std::left << std::setw(12) << data["platform"].get<std::string>() << " ";
oss << std::left << std::setw(2) << sd << " ";
auto completeString = isComplete() ? "C" : "P";
oss << std::setw(1) << " " << completeString << " ";
oss << std::setw(5) << std::setprecision(2) << std::fixed << durationShow << " " << durationUnit << " ";