Skip to content

Commit

Permalink
rename
Browse files Browse the repository at this point in the history
  • Loading branch information
gnefedev committed Sep 5, 2024
1 parent 50b9823 commit bd34d72
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/main/kotlin/com/milaboratory/mixcr/cli/CommandAlign.kt
Original file line number Diff line number Diff line change
Expand Up @@ -1401,7 +1401,7 @@ object CommandAlign {

ParseResult(
read = input.read,
sequence = newSeq,
sequenceForAlign = newSeq,
tags = result.tags,
sample = result.sample,
status = result.status
Expand Down Expand Up @@ -1429,7 +1429,7 @@ object CommandAlign {
threads = threads.value
) { bundle ->
if (bundle.ok) {
var alignment = aligner.process(bundle.sequence, bundle.read)
var alignment = aligner.process(bundle.sequenceForAlign, bundle.read)
?: return@mapChunksInParallel AlignmentResult.failed(bundle, NotAligned)
alignment = alignment
.withTagCount(TagCount(bundle.tags))
Expand Down Expand Up @@ -1600,13 +1600,13 @@ object CommandAlign {

private data class ParseResult(
val read: SequenceRead,
val sequence: NSQTuple,
val sequenceForAlign: NSQTuple,
val tags: TagTuple,
val sample: List<String>,
val status: Status
) {
val ok get() = status == Good
fun mapSequence(mapping: (NSQTuple) -> NSQTuple) = copy(sequence = mapping(sequence))
fun mapSequence(mapping: (NSQTuple) -> NSQTuple) = copy(sequenceForAlign = mapping(sequenceForAlign))
}

private data class AlignmentResult(
Expand All @@ -1620,7 +1620,7 @@ object CommandAlign {
companion object {
fun aligned(bundle: ParseResult, alignment: VDJCAlignments) = AlignmentResult(
read = bundle.read,
sequence = bundle.sequence,
sequence = bundle.sequenceForAlign,
sample = bundle.sample,
alignment = alignment,
status = Good,
Expand All @@ -1629,7 +1629,7 @@ object CommandAlign {

fun failed(bundle: ParseResult, status: Status) = AlignmentResult(
read = bundle.read,
sequence = bundle.sequence,
sequence = bundle.sequenceForAlign,
sample = bundle.sample,
alignment = null,
status = status,
Expand Down

0 comments on commit bd34d72

Please sign in to comment.