void ReadDataFromCsv(std::string &filename, std::vector<std::vector<std::string> > &lines_feat) {
std::ifstream vm_info(filename.c_str());
std::string lines, var;
std::vector<std::string> row; lines_feat.clear(); while(!vm_info.eof()) {
getline(vm_info, lines);
if(lines.empty())
break;
std::istringstream stringin(lines);
row.clear(); while(std::getline(stringin, var, ',')) {
row.push_back(var);
}
lines_feat.push_back(row);
}
}

最新文章

  1. 【JUC】JUC锁框架综述
  2. Lua 学习笔记(一)环境搭建
  3. [Linux]安装phpredis扩展
  4. hdu 5833 Zhu and 772002 高斯消元
  5. Struts2 实现文件上传和下载
  6. CentOS6.3连网获取IP失败 This device is not active
  7. Nginx + IIS
  8. 命令查看服务器SN号
  9. 常见.NET功能代码汇总 (3)
  10. GDAL1.11版本对SHP文件索引加速测试
  11. DAY20 常用模块(三)
  12. KFCM算法的matlab程序
  13. MT【48】分式连加形式下求不等式解集的区间长度
  14. 关于Altium Designer 提示发送错误报告解决方法
  15. CSS 标签实例二
  16. C#里面const和readonly
  17. Spring下获取项目根路径--good
  18. [Luogu3733][HAOI2017]八纵八横
  19. Python3 匿名函数
  20. 【POJ】1094 Sorting It All Out(拓扑排序)

热门文章

  1. 找到多个与名为“Home”的控制器匹配的类型。
  2. [Wf2015]Tours
  3. hihoCoder#1069 最近公共祖先&#183;三
  4. 游走(bzoj 3143)
  5. The Java library for converting Wikipedia wikitext notation to HTML
  6. go语言中的timer 和ticker定时任务
  7. hdu 4291 矩阵幂 循环节
  8. log4j 具体解释
  9. 演练:我的第一个 WPF 桌面应用程序 https://docs.microsoft.com/zh-cn/dotnet/framework/wpf/getting-started/walkthrough-my-first-wpf-desktop-application
  10. Java实现二叉排序树的插入、查找、删除