From 2dfdfd2c90d9c7cd6b4d386fac17d1d916b14c17 Mon Sep 17 00:00:00 2001 From: Claire Lemaitre Date: Tue, 1 Mar 2022 21:58:37 +0100 Subject: [PATCH] improving bed option --- src/FindBreakpoints.hpp | 8 ++++++-- src/Finder.cpp | 4 ++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/FindBreakpoints.hpp b/src/FindBreakpoints.hpp index c875720..0477cd9 100644 --- a/src/FindBreakpoints.hpp +++ b/src/FindBreakpoints.hpp @@ -479,8 +479,12 @@ void FindBreakpoints::operator()() v.push_back(token); } if(v[0]==m_chrom_name){ // we are on the current chromosome - interval=std::make_pair(std::stoi(v[1]),std::stoi(v[2])); - interval_vector.push_back( tuple(interval)); + uint64_t bed_begin = std::stoi(v[1]); + uint64_t bed_end = std::stoi(v[2]); + if ((bed_end-bed_begin) > this->finder->_kmerSize){ + interval=std::make_pair(std::stoi(v[1]),std::stoi(v[2])); + interval_vector.push_back( tuple(interval)); + } } iss.clear(); } diff --git a/src/Finder.cpp b/src/Finder.cpp index 0de5f8e..544faf5 100644 --- a/src/Finder.cpp +++ b/src/Finder.cpp @@ -431,6 +431,10 @@ void Finder::resumeParameters(){ getInfo()->add(2,"Graph",getInput()->getStr(STR_URI_GRAPH).c_str()); } getInfo()->add(2,"Reference",getInput()->getStr(STR_URI_REF).c_str()); + if(getInput()->get(STR_BED) != 0) + { + getInfo()->add(2,"Bed file",_bed_file_name.c_str()); + } getInfo()->add(1,"Graph"); getInfo()->add(2,"kmer-size","%i", _kmerSize);