labelname=oneFacePath+".txt";
ifstream f(labelname);
cout<< labelname<<":"<<f.good()<<endl;
#include <boost/algorithm/string.hpp> // logging module
#include <boost/algorithm/string/split.hpp>
#include <boost/algorithm/string/classification.hpp>
using namespace boost::algorithm;
std::getline(f, line);
split(tokens, line, is_any_of(" ")); // here it is
std::string::size_type pos_space;
pos_space=line.rfind(" ");
string class_label=line.substr(line.length()-pos_space-1);
用到过的C++技巧
最新推荐文章于 2023-07-14 20:28:54 发布