-
Notifications
You must be signed in to change notification settings - Fork 596
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updating MarkDuplicatesSpark tie-breaking to reflect changes in picard (
#5011) * updated tiebreaking * checked that values were being set properly in every case * added test from Picard for the tie-breaking code * updated documentation
- Loading branch information
1 parent
3b4e273
commit 0f5b253
Showing
5 changed files
with
132 additions
and
42 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
53 changes: 53 additions & 0 deletions
53
...ute/hellbender/utils/read/markduplicates/sparkrecords/TransientFieldPhysicalLocation.java
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,53 @@ | ||
package org.broadinstitute.hellbender.utils.read.markduplicates.sparkrecords; | ||
|
||
import picard.sam.util.PhysicalLocation; | ||
|
||
/** | ||
* A common class for holding the fields in PhysicalLocation that we don't want to be serialized by kryo. | ||
* | ||
* NOTE: readGroupIndex is not transient as the readgroup is needed in several stages of MarkDuplicatesSpark, but is still | ||
* contained in this class to mirror {@link PhysicalLocation} | ||
*/ | ||
public abstract class TransientFieldPhysicalLocation extends PairedEnds implements PhysicalLocation { | ||
// Information used to detect optical dupes | ||
protected short readGroupIndex = -1; | ||
protected transient short tile = -1; | ||
protected transient int x = -1; | ||
protected transient int y = -1; | ||
protected transient short libraryId = -1; | ||
|
||
public TransientFieldPhysicalLocation(int partitionIndex, String name) { | ||
super(partitionIndex, name); | ||
} | ||
|
||
// Methods for OpticalDuplicateFinder.PhysicalLocation | ||
@Override | ||
public short getReadGroup() { return this.readGroupIndex; } | ||
|
||
@Override | ||
public void setReadGroup(final short readGroup) { this.readGroupIndex = readGroup; } | ||
|
||
@Override | ||
public short getTile() { return this.tile; } | ||
|
||
@Override | ||
public void setTile(final short tile) { this.tile = tile; } | ||
|
||
@Override | ||
public int getX() { return this.x; } | ||
|
||
@Override | ||
public void setX(final int x) { this.x = x; } | ||
|
||
@Override | ||
public int getY() { return this.y; } | ||
|
||
@Override | ||
public void setY(final int y) { this.y = y; } | ||
|
||
@Override | ||
public short getLibraryId() { return this.libraryId; } | ||
|
||
@Override | ||
public void setLibraryId(final short libraryId) { this.libraryId = libraryId; } | ||
} |
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