| 47 | |
| 48 | template <typename T> |
| 49 | std::string VectorToString(std::vector<T> val) { |
| 50 | if (val.empty()) |
| 51 | return ""; |
| 52 | |
| 53 | std::stringstream stream; |
| 54 | stream << "["; |
| 55 | for (int i = 0; i < val.size(); ++i) { |
| 56 | stream << val[i]; |
| 57 | if (i != val.size() - 1) |
| 58 | stream << ","; |
| 59 | } |
| 60 | stream << "]"; |
| 61 | return stream.str(); |
| 62 | } |
| 63 | |
| 64 | std::vector<std::pair<std::string, std::vector<float>>> SortMapByValue(std::map<std::string, std::vector<float>> &map); |
| 65 |
no test coverage detected