-
Notifications
You must be signed in to change notification settings - Fork 309
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ADAM-1402] Fix INDEL realigner bad binary search.
Resolves #1402. Includes fixes to consensus generator and reference scorer. Improve INDEL realigner performance: * Exit early when realigning will not yield a better score. * Eliminate substring call in sweep over reference. * Change datastructures to be immutable wherever possible. * Add bound checking and other error checking. * Rewrite target association code to use array instead of set, and improve load balancing. * Delete high coverage targets with reduceByKey. Additionally: * Improve telemetry/logging to sort out load balance issue. * Support using reference file in INDEL realignment. * Log reads with negative alignment sizes. * Improved test coverage for insertion realignment. * Fix CIGARs on reads that partially overlap INDEL. * Soft clip reads that partially align to an insertion. * Eliminate non-determinism. * Fixed reference file. * Serialization fixes and debug. * Fix bad score. * Clean up clipping code? * Unclip clipped reads.
- Loading branch information
Showing
19 changed files
with
1,653 additions
and
377 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
adam-core/src/main/scala/org/bdgenomics/adam/rdd/read/realignment/ModPartitioner.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/** | ||
* Licensed to Big Data Genomics (BDG) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The BDG licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package org.bdgenomics.adam.rdd.read.realignment | ||
|
||
import org.apache.spark.Partitioner | ||
|
||
private[realignment] case class ModPartitioner(numPartitions: Int) extends Partitioner { | ||
|
||
def getPartition(key: Any): Int = key match { | ||
case i: Int => { | ||
i.abs % numPartitions | ||
} | ||
case _ => { | ||
throw new IllegalArgumentException("Key %s is not an Int.".format(key)) | ||
} | ||
} | ||
} |
Oops, something went wrong.