Fix continue training in CLI

This commit is contained in:
tqchen
2016-03-10 12:42:54 -08:00
parent 845f80ec22
commit 96b17971ac
3 changed files with 17 additions and 11 deletions

View File

@@ -26,6 +26,15 @@ inline std::vector<std::string> Split(const std::string& s, char delim) {
}
return ret;
}
// simple routine to convert any data to string
template<typename T>
inline std::string ToString(const T& data) {
std::ostringstream os;
os << data;
return os.str();
}
} // namespace common
} // namespace xgboost
#endif // XGBOOST_COMMON_COMMON_H_