Пример #1
0
void FeatureArray::save(ostream* os, bool bin)
{
  if (size() <= 0) return;
  if (bin) {
    savebin(os);
  } else {
    savetxt(os);
  }
}
Пример #2
0
void ScoreArray::save(ostream* os, const string& score_type, bool bin)
{
  if (size() <= 0) return;
  if (bin) {
    savebin(os, score_type);
  } else {
    savetxt(os, score_type);
  }
}
Пример #3
0
void AbstractCorrelator::savetxt (string_ref filename)
{
    std::ofstream ofs (filename);
    if (!ofs)
        rt_error ("cannot open file: " + filename);
    savetxt (ofs);
    if (!ofs)
        rt_error ("error writing data: " + filename);
    ofs.close ();
    if (!ofs)
        rt_error ("error writing data (2): " + filename);
}
Пример #4
0
void ScoreStats::savetxt()
{
  savetxt(&cout);
}
Пример #5
0
void ScoreStats::savetxt(const string &file)
{
  ofstream ofs(file.c_str(), ios::out); // matches a stream with a file. Opens the file
  ostream* os = &ofs;
  savetxt(os);
}
void ScoreArray::save(std::ofstream& inFile, const std::string& sctype, bool bin)
{
  if (size()>0)
    (bin)?savebin(inFile, sctype):savetxt(inFile, sctype);
}
Пример #7
0
void FeatureStats::savetxt() {
  savetxt(&cout);
}
Пример #8
0
void FeatureStats::savetxt(const string &file)
{
  ofstream ofs(file.c_str(), ios::out);
  ostream* os = &ofs;
  savetxt(os);
}