Skip to content
Snippets Groups Projects
Commit 84a877bb authored by Veronique Legrand's avatar Veronique Legrand
Browse files

bug fix+ traces for debug

parent 5d04ab44
No related branches found
No related tags found
No related merge requests found
......@@ -30,6 +30,7 @@
using namespace std;
//#define DEBUG
#define BENCHMARK
#ifdef BENCHMARK
......@@ -121,24 +122,31 @@ void lowFilterCMS(FqBaseBackend* map_id_backend[],int nb_be,int k, CountMinSketc
for (i=0;i<nb_be;i++){
map_id_backend[i]->openFile();
}
cout<<"all input files are open"<<endl;
for (it=io_sr->begin(); it!=io_sr->end(); ++it) {
for (it_offs=it->second.begin();it_offs!=it->second.end();it_offs++) {
unsigned int j=it_offs->first;
for (it_struct=it_offs->second.begin();it_struct!=it_offs->second.end();it_struct++) {
// read dna string corresponding to fastq record
DnaSeqStr a_seqs[2];
init_DnaSeqStr(&a_seqs[0]);
init_DnaSeqStr(&a_seqs[1]);
getDNASeqstr(map_id_backend,*it_struct,j,a_seqs);
// decompose dna string into k-mers and turn k_mers into numbers.
decomposeReadInKMerNums(read_p, nbrKmerDecompo,k,a_seqs);
ret=pcms->isBeneathMinKappa(nbrKmerDecompo);
if (ret) it_struct->fileid=0;
nbrKmerDecompo.clear();
if (it_struct->fileid) {
// read dna string corresponding to fastq record
DnaSeqStr a_seqs[2];
init_DnaSeqStr(&a_seqs[0]);
init_DnaSeqStr(&a_seqs[1]);
getDNASeqstr(map_id_backend,*it_struct,j,a_seqs);
#ifdef DEBUG
cout<<a_seqs[0].fq_record_buf<<" "<<a_seqs[0].start_idx<<" "<<a_seqs[0].length<<endl;
cout<<a_seqs[1].fq_record_buf<<" "<<a_seqs[1].start_idx<<" "<<a_seqs[1].length<<endl;
#endif
// decompose dna string into k-mers and turn k_mers into numbers.
decomposeReadInKMerNums(read_p, nbrKmerDecompo,k,a_seqs);
ret=pcms->isBeneathMinKappa(nbrKmerDecompo);
if (ret) it_struct->fileid=0;
nbrKmerDecompo.clear();
}
}
}
}
cout<<"going to close input files."<<endl;
for (i=0;i<nb_be;i++){
map_id_backend[i]->closeFile();
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment