Showing
3 changed files
with
0 additions
and
33 deletions
... | @@ -41,33 +41,6 @@ namespace data{ | ... | @@ -41,33 +41,6 @@ namespace data{ |
41 | } | 41 | } |
42 | } | 42 | } |
43 | virtual multithread::Buffer<data::Data_basic*>* get(std::string pattern)=0; | 43 | virtual multithread::Buffer<data::Data_basic*>* get(std::string pattern)=0; |
44 | -// void write(std::string file_name, std::string pattern){ | ||
45 | -// multithread::Buffer<data::Data_basic*> *buf; | ||
46 | -// std::string towrite; | ||
47 | -// std::ofstream output; | ||
48 | -// output.open(file_name, std::ios::out | std::ios::trunc); | ||
49 | -// buf = this->get(pattern); | ||
50 | -// int count_buf(0); | ||
51 | -// while(buf->available()){ | ||
52 | -// if(!buf->isEmpty()){ | ||
53 | -// data::Data_basic* tmp = buf->pop(); | ||
54 | -// towrite += tmp->to_csv()+"\n"; | ||
55 | -// count_buf ++; | ||
56 | -// delete tmp; | ||
57 | -// }else{ | ||
58 | -// std::this_thread::sleep_for(THREAD_SLEEP); | ||
59 | -// } | ||
60 | -// if(count_buf == NB_ELT_BUF){ | ||
61 | -// output << towrite; | ||
62 | -// towrite.clear(); | ||
63 | -// count_buf=0; | ||
64 | -// } | ||
65 | -// } | ||
66 | -// if(count_buf>0){ | ||
67 | -// output << towrite; | ||
68 | -// } | ||
69 | -// output.close(); | ||
70 | -// } | ||
71 | }; | 44 | }; |
72 | } | 45 | } |
73 | #endif // DATA_STORE_H | 46 | #endif // DATA_STORE_H | ... | ... |
... | @@ -53,7 +53,6 @@ class Producer_map: public multithread::Buffer_producer<data::Data_basic*>{ | ... | @@ -53,7 +53,6 @@ class Producer_map: public multithread::Buffer_producer<data::Data_basic*>{ |
53 | Data_Store_Map(){} | 53 | Data_Store_Map(){} |
54 | Data_Store_Map(std::string file_name):data::Data_Store(file_name){} | 54 | Data_Store_Map(std::string file_name):data::Data_Store(file_name){} |
55 | ~Data_Store_Map(){ | 55 | ~Data_Store_Map(){ |
56 | - //~data::Data_Store::~Data_Store(); | ||
57 | for(auto const &kv: this->data_map){ | 56 | for(auto const &kv: this->data_map){ |
58 | delete kv.second; | 57 | delete kv.second; |
59 | } | 58 | } | ... | ... |
... | @@ -53,7 +53,6 @@ int main(int argc, char* argv[]) | ... | @@ -53,7 +53,6 @@ int main(int argc, char* argv[]) |
53 | 53 | ||
54 | /* ************** KMER ******************/ | 54 | /* ************** KMER ******************/ |
55 | feature::Feature_callable *kmer = static_cast<feature::Feature_callable*>(feature::Kmer::get_callable(3)); | 55 | feature::Feature_callable *kmer = static_cast<feature::Feature_callable*>(feature::Kmer::get_callable(3)); |
56 | -// tmp_ds = new data::Data_Store_Map(); | ||
57 | tmp_ds = new data::Data_Store_Map(output+"KMER3.txt"); | 56 | tmp_ds = new data::Data_Store_Map(output+"KMER3.txt"); |
58 | ds["KMER3"] = tmp_ds; | 57 | ds["KMER3"] = tmp_ds; |
59 | create_feature_maker(kmer,feature::Kmer::TYPE+std::to_string(6),tmp_ds,&re); | 58 | create_feature_maker(kmer,feature::Kmer::TYPE+std::to_string(6),tmp_ds,&re); |
... | @@ -67,7 +66,6 @@ int main(int argc, char* argv[]) | ... | @@ -67,7 +66,6 @@ int main(int argc, char* argv[]) |
67 | /* ORF callable */ | 66 | /* ORF callable */ |
68 | 67 | ||
69 | feature::Feature_callable *orf = static_cast<feature::Feature_callable*>(feature::ORF::get_callable()); | 68 | feature::Feature_callable *orf = static_cast<feature::Feature_callable*>(feature::ORF::get_callable()); |
70 | -// tmp_ds = new data::Data_Store_Map(); | ||
71 | tmp_ds = new data::Data_Store_Map(output+"ORF.txt"); | 69 | tmp_ds = new data::Data_Store_Map(output+"ORF.txt"); |
72 | ds["ORF"] = tmp_ds; | 70 | ds["ORF"] = tmp_ds; |
73 | create_feature_maker(orf,feature::ORF::TYPE,tmp_ds,&re); | 71 | create_feature_maker(orf,feature::ORF::TYPE,tmp_ds,&re); |
... | @@ -75,7 +73,6 @@ int main(int argc, char* argv[]) | ... | @@ -75,7 +73,6 @@ int main(int argc, char* argv[]) |
75 | /* *********** Codon Position ***************/ | 73 | /* *********** Codon Position ***************/ |
76 | 74 | ||
77 | feature::Feature_callable *cp = static_cast<feature::Feature_callable*>(feature::CodonPosition::get_callable()); | 75 | feature::Feature_callable *cp = static_cast<feature::Feature_callable*>(feature::CodonPosition::get_callable()); |
78 | -// tmp_ds = new data::Data_Store_Map(); | ||
79 | tmp_ds = new data::Data_Store_Map(output+"CP.txt"); | 76 | tmp_ds = new data::Data_Store_Map(output+"CP.txt"); |
80 | ds["CP"] = tmp_ds; | 77 | ds["CP"] = tmp_ds; |
81 | create_feature_maker(cp,feature::CodonPosition::TYPE,tmp_ds,&re); | 78 | create_feature_maker(cp,feature::CodonPosition::TYPE,tmp_ds,&re); |
... | @@ -108,8 +105,6 @@ int main(int argc, char* argv[]) | ... | @@ -108,8 +105,6 @@ int main(int argc, char* argv[]) |
108 | 105 | ||
109 | auto it = ds.begin(); | 106 | auto it = ds.begin(); |
110 | while(it != ds.end()){ | 107 | while(it != ds.end()){ |
111 | -// it->second->write(output+it->first+".txt",".*"); | ||
112 | -// std::cout << "File " << output+it->first+".txt" << " writted" << std::endl; | ||
113 | delete it->second; | 108 | delete it->second; |
114 | ++it; | 109 | ++it; |
115 | } | 110 | } | ... | ... |
-
Please register or login to post a comment