Commit 4626aad3 authored by Sander Bollen's avatar Sander Bollen Committed by GitHub

Merge pull request #156 from biopet/fix-BIOPET-741

Fixing grouping in GenotypeGVCFs
parents 050ed7a9 ad759469
......@@ -55,7 +55,7 @@ class GenotypeGvcfs(val parent: Configurable) extends QScript with BiopetQScript
job.out = outputFile
job.isIntermediate = group.nonEmpty
val subJobs: ListBuffer[CombineJob] = ListBuffer()
val groupedInput = makeEqualGroups(allInput)
val groupedInput: List[List[File]] = makeEqualGroups(allInput)
if (groupedInput.size == 1) job.variant = groupedInput.head
else {
for ((list, i) <- groupedInput.zipWithIndex) {
......@@ -71,7 +71,7 @@ class GenotypeGvcfs(val parent: Configurable) extends QScript with BiopetQScript
val groupSize = if (files.size > (maxNumberOfFiles * maxNumberOfFiles)) {
files.size / maxNumberOfFiles
} else if (files.size < maxNumberOfFiles) files.size
else files.size / (files.size / maxNumberOfFiles)
else (files.size.toDouble / (files.size.toDouble / maxNumberOfFiles).ceil).ceil.toInt
files.grouped(groupSize).toList
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment