try {
string helpString = "";
helpString += "The chimera.check command reads a fastafile and referencefile and outputs potentially chimeric sequences.\n";
- helpString += "This command was created using the algorythms described in CHIMERA_CHECK version 2.7 written by Niels Larsen. \n";
+ helpString += "This command was created using the algorithms described in CHIMERA_CHECK version 2.7 written by Niels Larsen. \n";
helpString += "The chimera.check command parameters are fasta, reference, processors, ksize, increment, svg and name.\n";
helpString += "The fasta parameter allows you to enter the fasta file containing your potentially chimeric sequences, and is required unless you have a valid current fasta file. \n";
helpString += "You may enter multiple fasta files by separating their names with dashes. ie. fasta=abrecovery.fasta-amzon.fasta \n";
#endif
//report progress
- if((count) % 100 == 0){ m->mothurOut("Processing sequence: " + toString(count)); m->mothurOutEndLine(); }
- count++;
+ if((count) % 100 == 0){ m->mothurOutJustToScreen("Processing sequence: " + toString(count) + "\n"); }
}
//report progress
- if((count) % 100 != 0){ m->mothurOut("Processing sequence: " + toString(count)); m->mothurOutEndLine(); }
+ if((count) % 100 != 0){ m->mothurOutJustToScreen("Processing sequence: " + toString(count) + "\n"); }
out.close();
inFASTA.close();
delete candidateSeq;
//report progress
- if((i+1) % 100 == 0){ cout << "Processing sequence: " << (i+1) << endl; m->mothurOutJustToLog("Processing sequence: " + toString(i+1) + "\n"); }
+ if((i+1) % 100 == 0){ cout << "Processing sequence: " << (i+1) << endl; }
}
//report progress
- if(num % 100 != 0){ cout << "Processing sequence: " << num << endl; m->mothurOutJustToLog("Processing sequence: " + toString(num) + "\n"); }
+ if(num % 100 != 0){ cout << "Processing sequence: " << num << endl; }
return 0;
}
//loop through and create all the processes you want
while (process != processors) {
- int pid = fork();
+ pid_t pid = fork();
if (pid > 0) {
processIDS.push_back(pid); //create map from line number to pid so you can append files in correct order later
process++;
}else if (pid == 0){
- num = driver(lines[process], outputFileName + toString(getpid()) + ".temp", filename);
+ num = driver(lines[process], outputFileName + toString(m->mothurGetpid(process)) + ".temp", filename);
//pass numSeqs to parent
ofstream out;
- string tempFile = outputFileName + toString(getpid()) + ".num.temp";
+ string tempFile = outputFileName + toString(m->mothurGetpid(process)) + ".num.temp";
m->openOutputFile(tempFile, out);
out << num << endl;
out.close();