#include
#include
vector<vector> x; //样本集
void readData(string fileName)
{
float temp;
ifstream file(fileName, ios::in);
while (!file.eof())
{
vector rx;
for (int i = 0; i < 4; i++)
{
file >> temp;
rx.push_back(temp);
file.get();//分隔符,
}
x.push_back(rx);
};
file.close();
}
string text_time = exe_address + “\time.txt”; //得到耗时
ofstream fout_time(text_time);
fout_time << “running time = " << ((double)getTickCount() - start_time) / getTickFrequency() <<” s" <<endl;
fout_time.close();