Skip to content

Commit

Permalink
Delly v0.6.3
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasrausch committed Feb 23, 2015
1 parent d23262a commit 467e8bd
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/coverage.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,19 +104,15 @@ inline void
annotateCoverage(TFiles const& files, uint16_t minMapQual, TSampleLibrary& sampleLib, TSVs& svs, TCountMap& countMap, TBpLevelType bpLevel, TCoverageType covType)
{
typedef typename TSVs::value_type TSV;
typedef typename TCountMap::key_type TSampleSVPair;

// Get the references
BamTools::BamReader readerRef;
if ( ! readerRef.Open(files[0].string()) ) return;
BamTools::RefVector references = readerRef.GetReferenceData();
// For alignment midpoint, maximum read-length
int32_t maxReadLen = 1000;

// Sort Structural Variants
sort(svs.begin(), svs.end(), SortSVs<TSV>());

// Initialize count maps
int32_t maxReadLen = 1000;
for(typename TSampleLibrary::iterator sIt = sampleLib.begin(); sIt!=sampleLib.end();++sIt) {
for(typename TSampleLibrary::iterator sIt = sampleLib.begin(); sIt!=sampleLib.end(); ++sIt) {
for(typename TSVs::const_iterator itSV = svs.begin(); itSV!=svs.end(); ++itSV) {
countMap.insert(std::make_pair(std::make_pair(sIt->first, itSV->id), std::make_pair(0,0)));
}
Expand Down Expand Up @@ -231,6 +227,7 @@ annotateCoverage(TFiles const& files, uint16_t minMapQual, TSampleLibrary& sampl
// Store counts
#pragma omp critical
{
typedef typename TCountMap::key_type TSampleSVPair;
TSampleSVPair svSample = std::make_pair(sampleName, itSV->id);
typename TCountMap::iterator countMapIt=countMap.find(svSample);
//std::cerr << itSV->id << ':' << cumBpSum << ',' << cumReadSum << std::endl;
Expand Down

0 comments on commit 467e8bd

Please sign in to comment.