private void runBenchmark() {
try {
FastaIndexManager fastaIndexManager = getFastaIndexManger();
DirectoryStream<Path> stream = Files.newDirectoryStream(input, entry -> {
return entry.getFileName().toString().endsWith(".vep");
});
DataWriter<Pair<VariantAnnotationDiff, VariantAnnotationDiff>> dataWriter = new BenchmarkDataWriter("VEP", "CellBase", output);
ParallelTaskRunner.Config config = new ParallelTaskRunner.Config(numThreads, batchSize, QUEUE_CAPACITY, false);
List<ParallelTaskRunner.TaskWithException<VariantAnnotation, Pair<VariantAnnotationDiff, VariantAnnotationDiff>, Exception>>
variantAnnotatorTaskList = getBenchmarkTaskList(fastaIndexManager);
for (Path entry : stream) {
logger.info("Processing file '{}'", entry.toString());
DataReader dataReader = new VepFormatReader(input.resolve(entry.getFileName()).toString());
ParallelTaskRunner<VariantAnnotation, Pair<VariantAnnotationDiff, VariantAnnotationDiff>> runner
= new ParallelTaskRunner<>(dataReader, variantAnnotatorTaskList, dataWriter, config);
runner.run();
}
} catch (Exception e) {
e.printStackTrace();
}
}