for (int i = 0; i < lines.size(); i++) { delete lines[i]; } lines.clear();
#ifdef USE_MPI
+
int pid, end, numSeqsPerProcessor;
int tag = 2001;
vector<long> MPIPos;
MPI_File_close(&outMPITempTax);
#else
+
//read namefile
if(namefile != "") {
nameMap.clear(); //remove old names
driver(lines[0], newTaxonomyFile, tempTaxonomyFile, fastaFileNames[s]);
#endif
#endif
-
+
+ delete classify;
+
#ifdef USE_MPI
if (pid == 0) { //this part does not need to be paralellized
#endif
//read in users taxonomy file and add sequences to tree
string name, taxon;
+
while(!in.eof()){
in >> name >> taxon; gobble(in);
m->mothurOut("It took " + toString(time(NULL) - start) + " secs to classify " + toString(numFastaSeqs) + " sequences."); m->mothurOutEndLine(); m->mothurOutEndLine();
}
- delete classify;
return 0;
}
catch(exception& e) {
if (m->control_pressed) { return 0; }
Sequence* candidateSeq = new Sequence(inFASTA);
-
+
if (candidateSeq->getName() != "") {
taxonomy = classify->getTaxonomy(candidateSeq);
if (m->control_pressed) { delete candidateSeq; return 0; }
- if (taxonomy != "bad seq") {
+ if ((taxonomy != "bad seq") && (taxonomy != "")) {
//output confidence scores or not
if (probs) {
outTax << candidateSeq->getName() << '\t' << taxonomy << endl;
}
outTaxSimple << candidateSeq->getName() << '\t' << classify->getSimpleTax() << endl;
- }
+ }else{ m->mothurOut("Sequence: " + candidateSeq->getName() + " is bad."); m->mothurOutEndLine(); }
}
delete candidateSeq;
if (candidateSeq->getName() != "") {
taxonomy = classify->getTaxonomy(candidateSeq);
- if (taxonomy != "bad seq") {
+ if ((taxonomy != "bad seq") && (taxonomy != "")) {
//output confidence scores or not
if (probs) {
outputString = candidateSeq->getName() + "\t" + taxonomy + "\n";
strcpy(buf, outputString.c_str());
MPI_File_write_shared(tempFile, buf, length, MPI_CHAR, &statusTemp);
- }
+ }else{ cout << "Sequence: " << candidateSeq->getName() << " is bad." << endl; }
}
delete candidateSeq;