Skip to content

Commit

Permalink
Merge pull request #1066 from milaboratory/alleles_fix
Browse files Browse the repository at this point in the history
don't cut features on export library
  • Loading branch information
gnefedev authored Apr 5, 2023
2 parents a8a222c + 0ffb6d6 commit 4a2b973
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 25 deletions.
6 changes: 3 additions & 3 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -134,10 +134,10 @@ val toObfuscate: Configuration by configurations.creating {

val obfuscationLibs: Configuration by configurations.creating

val mixcrAlgoVersion = "4.3.0-41-develop"
val milibVersion = "2.4.0-5-master"
val mixcrAlgoVersion = "4.3.0-46-allele_fix"
val milibVersion = "2.4.0-7-master"
val mitoolVersion = "1.7.0-5-main"
val repseqioVersion = "1.8.0-11-master"
val repseqioVersion = "1.8.0-20-master"

val picocliVersion = "4.6.3"
val jacksonBomVersion = "2.14.2"
Expand Down
28 changes: 6 additions & 22 deletions src/main/kotlin/com/milaboratory/mixcr/cli/CommandFindAlleles.kt
Original file line number Diff line number Diff line change
Expand Up @@ -445,28 +445,12 @@ class CommandFindAlleles : MiXCRCommandWithOutputs() {
primaryGenes
.sortedBy { it.name }
.forEach { gene ->
val geneFeaturesForFoundAllele =
gene.data.meta[metaKey.alleleMutationsReliableRegion]
?.map { GeneFeature.parse(it) }
?.sorted()
when {
geneFeaturesForFoundAllele != null -> {
geneFeaturesForFoundAllele.forEach { geneFeature ->
val range = gene.referencePoints.getRange(geneFeature)
val sequence = gene.getFeature(geneFeature)
writer.write(FastaRecord(id++, "${gene.name} $range $geneFeature", sequence))
}
}

else -> {
val range = Range(
gene.referencePoints.firstAvailablePosition,
gene.referencePoints.lastAvailablePosition
)
val sequence = gene.getSequence(range)
writer.write(FastaRecord(id++, "${gene.name} $range", sequence))
}
}
val range = Range(
gene.referencePoints.firstAvailablePosition,
gene.referencePoints.lastAvailablePosition
)
val sequence = gene.getSequence(range)
writer.write(FastaRecord(id++, "${gene.name} $range", sequence))
}
}
}
Expand Down
2 changes: 2 additions & 0 deletions src/main/resources/parameters/find_alleles_parameters.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"useClonesWithCountGreaterThen": 1
},
"searchAlleleParameterForFirstRound": {
"clonesToSearchCap": 10000,
"minClonesCountForAlleleSearch": 20,
"topByScore": 0.3,
"coefficientForNaiveClonesInScore": 2.0,
Expand All @@ -21,6 +22,7 @@
"minCountOfNaiveClonesToAddAllele": 0
},
"searchAlleleParameterForSecondRound": {
"clonesToSearchCap": 10000,
"minClonesCountForAlleleSearch": 10,
"topByScore": 0.65,
"coefficientForNaiveClonesInScore": 2.0,
Expand Down

0 comments on commit 4a2b973

Please sign in to comment.