From f8e6b8d433f7ff765e034d2e6623130355c74ab9 Mon Sep 17 00:00:00 2001 From: Chris Saunders Date: Mon, 27 Apr 2015 12:07:48 -0700 Subject: [PATCH] update cl/fmt for release --- ChangeLog.txt | 3 +- .../EstimateSVLoci/ESLOptions.cpp | 2 +- .../SVCandidateAssemblyRefiner.cpp | 32 +++++++++---------- .../GenerateSVCandidates/SVScorerSplit.cpp | 4 +-- src/c++/lib/format/VcfWriterSV.cpp | 3 +- src/c++/lib/manta/SVLocusScanner.cpp | 2 +- src/c++/lib/manta/SVLocusScanner.hh | 3 +- src/cmake/cxxTestLibrary.cmake | 2 +- 8 files changed, 27 insertions(+), 24 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index 7d7bfae7..07dad3ff 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,4 +1,5 @@ -- MANTA-224 improve short-fragment handling for RNA +v0.26.0 +- MANTA-224 improve short-fragment handling for RNA - MANTA-235 kmer refernce mask to accelerate RNA contig alignments - MANTA-232 filter large SVs with no read pair support - MANTA-236 expand conditions for large insertion search to normalize diff --git a/src/c++/lib/applications/EstimateSVLoci/ESLOptions.cpp b/src/c++/lib/applications/EstimateSVLoci/ESLOptions.cpp index 6a470b5d..f5f8ce63 100644 --- a/src/c++/lib/applications/EstimateSVLoci/ESLOptions.cpp +++ b/src/c++/lib/applications/EstimateSVLoci/ESLOptions.cpp @@ -84,7 +84,7 @@ parseESLOptions( "samtools formatted region, eg. 'chr1:20-30'") ("rna", po::value(&opt.isRNA)->zero_tokens(), "For RNA input. Changes small fragment handling.") - ; + ; po::options_description alignDesc(getOptionsDescription(opt.alignFileOpt)); po::options_description scanDesc(getOptionsDescription(opt.scanOpt)); diff --git a/src/c++/lib/applications/GenerateSVCandidates/SVCandidateAssemblyRefiner.cpp b/src/c++/lib/applications/GenerateSVCandidates/SVCandidateAssemblyRefiner.cpp index e862eaa1..ac7baf3e 100644 --- a/src/c++/lib/applications/GenerateSVCandidates/SVCandidateAssemblyRefiner.cpp +++ b/src/c++/lib/applications/GenerateSVCandidates/SVCandidateAssemblyRefiner.cpp @@ -1151,7 +1151,7 @@ bool translateMaskedAlignment( else { const unsigned length = translateMaskedPos(exclBlocks, cpos + seg.length) - - translateMaskedPos(exclBlocks, cpos); + translateMaskedPos(exclBlocks, cpos); if (is_segment_align_match(seg.type) && (length != seg.length)) return false; #ifdef DEBUG_KMER log_os << __FUNCTION__ << " SEGMENT " << seg.type << " " << seg.length << "\n"; @@ -1176,11 +1176,11 @@ bool translateMaskedAlignment( /// Returns a reduced reference sequence where long stretches without kmer matches to the contig are removed template std::string kmerMaskReference( - const SymIter refSeqStart, - const SymIter refSeqEnd, - const std::string& contig, - const int nSpacer, - std::vector& exclBlocks) + const SymIter refSeqStart, + const SymIter refSeqEnd, + const std::string& contig, + const int nSpacer, + std::vector& exclBlocks) { // Hash all kmers in the contig static const int merSize(10); @@ -1510,16 +1510,16 @@ getJumpAssembly( { #ifdef DEBUG_REFINER log_os << __FUNCTION__ << " RNA alignment\n"; -#endif +#endif static const int nSpacer(25); std::vector exclBlocks1; const std::string cutRef1 = kmerMaskReference(align1RefStrPtr->begin() + align1LeadingCut, - align1RefStrPtr->end() - align1TrailingCut, - contig.seq, nSpacer, exclBlocks1); + align1RefStrPtr->end() - align1TrailingCut, + contig.seq, nSpacer, exclBlocks1); std::vector exclBlocks2; const std::string cutRef2 = kmerMaskReference(align2RefStrPtr->begin() + align2LeadingCut, - align2RefStrPtr->end() - align2TrailingCut, - contig.seq, nSpacer, exclBlocks2); + align2RefStrPtr->end() - align2TrailingCut, + contig.seq, nSpacer, exclBlocks2); #ifdef DEBUG_REFINER log_os << __FUNCTION__ << " Kmer-masked references\n"; log_os << "\t ref Lengths " << align1RefStrPtr->size() << " " << align2RefStrPtr->size() << "\n"; @@ -1532,16 +1532,16 @@ getJumpAssembly( log_os << __FUNCTION__ << ": bp1Fw: " << bp1Fw << " ; bp2Fw: " << bp2Fw << '\n'; #endif _RNASpanningAligner.align(contig.seq.begin(), contig.seq.end(), - cutRef1.begin(), cutRef1.end(), cutRef2.begin(), cutRef2.end(), - bp1Fw, bp2Fw, - alignment); - + cutRef1.begin(), cutRef1.end(), cutRef2.begin(), cutRef2.end(), + bp1Fw, bp2Fw, + alignment); + #ifdef DEBUG_REFINER log_os << __FUNCTION__ << " Masked 1: " << alignment.align1 << '\n'; log_os << __FUNCTION__ << " Masked 2: " << alignment.align2 << '\n'; #endif if (!(translateMaskedAlignment(alignment.align1, exclBlocks1) && - translateMaskedAlignment(alignment.align2, exclBlocks2))) + translateMaskedAlignment(alignment.align2, exclBlocks2))) { #ifdef DEBUG_REFINER log_os << __FUNCTION__ << " Failed to fix kmer-masked alignment\n"; diff --git a/src/c++/lib/applications/GenerateSVCandidates/SVScorerSplit.cpp b/src/c++/lib/applications/GenerateSVCandidates/SVScorerSplit.cpp index 434ca9b9..e0e29cde 100644 --- a/src/c++/lib/applications/GenerateSVCandidates/SVScorerSplit.cpp +++ b/src/c++/lib/applications/GenerateSVCandidates/SVScorerSplit.cpp @@ -188,8 +188,8 @@ scoreSplitReads( // We are not looking for remote reads, (semialigned-) reads mapping near this breakpoint, but not across it // or any other kind of additional reads used for assembly. readStream.set_new_region(bp.interval.tid, - std::max(0, bp.interval.range.begin_pos() - extendedSearchRange), - bp.interval.range.end_pos() + extendedSearchRange); + std::max(0, bp.interval.range.begin_pos() - extendedSearchRange), + bp.interval.range.end_pos() + extendedSearchRange); while (readStream.next()) { const bam_record& bamRead(*(readStream.get_record_ptr())); diff --git a/src/c++/lib/format/VcfWriterSV.cpp b/src/c++/lib/format/VcfWriterSV.cpp index 6ea02f82..f5f6f57b 100644 --- a/src/c++/lib/format/VcfWriterSV.cpp +++ b/src/c++/lib/format/VcfWriterSV.cpp @@ -831,7 +831,8 @@ writeSVCore( BOOST_THROW_EXCEPTION(LogicException(oss.str())); } - try { + try + { if (isSVTransloc(svType)) { writeTranslocPair(sv, svId, svData, adata, event); diff --git a/src/c++/lib/manta/SVLocusScanner.cpp b/src/c++/lib/manta/SVLocusScanner.cpp index 5f171fbe..958aa337 100644 --- a/src/c++/lib/manta/SVLocusScanner.cpp +++ b/src/c++/lib/manta/SVLocusScanner.cpp @@ -1353,7 +1353,7 @@ isSemiAlignedEvidence( { unsigned leadingMismatchLen(0), trailingMismatchLen(0); getSVBreakendCandidateSemiAlignedSimple(bamRead, bamAlign, refSeq, _dopt.isUseOverlappingPairs, - leadingMismatchLen, trailingMismatchLen); + leadingMismatchLen, trailingMismatchLen); return ((leadingMismatchLen >= _opt.minSemiAlignedMismatchLen) || (trailingMismatchLen >= _opt.minSemiAlignedMismatchLen)); } diff --git a/src/c++/lib/manta/SVLocusScanner.hh b/src/c++/lib/manta/SVLocusScanner.hh index 0ac36f7b..9178ca84 100644 --- a/src/c++/lib/manta/SVLocusScanner.hh +++ b/src/c++/lib/manta/SVLocusScanner.hh @@ -111,7 +111,8 @@ struct SVLocusScanner { if (bamRead.is_filter()) return true; else if (bamRead.is_dup()) return true; - else { + else + { // hack to work with bwamem '-M' formatting, // keep secondary reads when they contain an SA tag if (bamRead.is_secondary()) diff --git a/src/cmake/cxxTestLibrary.cmake b/src/cmake/cxxTestLibrary.cmake index 748ebdee..9f4429f7 100644 --- a/src/cmake/cxxTestLibrary.cmake +++ b/src/cmake/cxxTestLibrary.cmake @@ -39,7 +39,7 @@ endif () if (WIN32) # create a fake library target on win32 instead of linking and running the unit test # this creates a project in VS that allows for interaction with the unit test code - + # add all files to TEST_SOURCE to make the IDE project more usable: file(GLOB TMP_TARGET_FILES *)