def parallel_variantcall_region(samples, run_parallel):
    """Perform variant calling and post-analysis on samples by region.
    """
    to_process, extras = _dup_samples_by_variantcaller(samples)
    split_fn = _split_by_ready_regions(".vcf.gz", "work_bam", get_variantcaller)
    samples = _collapse_by_bam_variantcaller(
        grouped_parallel_split_combine(to_process, split_fn,
                                       multi.group_batches, run_parallel,
                                       "variantcall_sample", "concat_variant_files",
                                       "vrn_file", ["region", "sam_ref", "config"]))
    return extras + samples
def parallel_variantcall_region ( samples , run_parallel ) : to_process , extras = _dup_samples_by_variantcaller ( samples ) split_fn = _split_by_ready_regions ( ".vcf.gz" , "work_bam" , get_variantcaller ) samples = _collapse_by_bam_variantcaller ( grouped_parallel_split_combine ( to_process , split_fn , multi . group_batches , run_parallel , "variantcall_sample" , "concat_variant_files" , "vrn_file" , [ "region" , "sam_ref" , "config" ] ) ) return extras + samples
Perform variant calling and post-analysis on samples by region.