本文整理汇总了Python中tests.conftest.make_workdir函数的典型用法代码示例。如果您正苦于以下问题:Python make_workdir函数的具体用法?Python make_workdir怎么用?Python make_workdir使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了make_workdir函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_programs
def test_programs(self, data_dir):
"""Identify programs and versions used in analysis.
"""
from bcbio.provenance import programs
with make_workdir() as workdir:
config = load_config(get_post_process_yaml(data_dir, workdir))
print programs._get_versions(config)
示例2: test_6_bamclean
def test_6_bamclean(install_test_files, data_dir):
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "100326_FC6107FAAXX"),
os.path.join(data_dir, "run_info-bamclean.yaml")]
subprocess.check_call(cl)
示例3: test_1_parallel_vcf_combine
def test_1_parallel_vcf_combine(self):
"""Parallel combination of VCF files, split by chromosome.
"""
from bcbio.variation import vcfutils
files = [
os.path.join(self.var_dir, "S1-variants.vcf"),
os.path.join(self.var_dir, "S2-variants.vcf")
]
with make_workdir() as workdir:
config = load_config(
get_post_process_yaml(self.automated_dir, workdir))
config["algorithm"] = {}
region_dir = os.path.join(self.var_dir, "S1_S2-combined-regions")
if os.path.exists(region_dir):
shutil.rmtree(region_dir)
if os.path.exists(self.combo_file):
os.remove(self.combo_file)
reqs = {"type": "local", "cores": 1}
with prun.start(reqs, [[config]], config) as run_parallel:
vcfutils.parallel_combine_variants(
files, self.combo_file, self.ref_file, config, run_parallel)
for fname in files:
if os.path.exists(fname + ".gz"):
subprocess.check_call(["gunzip", fname + ".gz"])
if os.path.exists(fname + ".gz.tbi"):
os.remove(fname + ".gz.tbi")
示例4: test_10_umi
def test_10_umi(install_test_files, data_dir):
"""Allow BAM files as input to pipeline.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, "run_info-umi.yaml")]
subprocess.check_call(cl)
示例5: test_7b_cancer_precall
def test_7b_cancer_precall(install_test_files, data_dir):
"""Test somatic prioritization and effects prediction with pre-called inputs.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, "run_info-cancer3.yaml")]
subprocess.check_call(cl)
示例6: test_9_joint
def test_9_joint(install_test_files, data_dir):
"""Perform joint calling/backfilling/squaring off following variant calling.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, "run_info-joint.yaml")]
subprocess.check_call(cl)
示例7: test_7_cancer
def test_7_cancer(install_test_files, data_dir):
"""Test paired tumor-normal calling using multiple
calling approaches: MuTect, VarScan, FreeBayes.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, "run_info-cancer.yaml")]
subprocess.check_call(cl)
示例8: test_srnaseq_bowtie
def test_srnaseq_bowtie(install_test_files, data_dir):
"""Run an sRNA-seq analysis.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "test_srnaseq"),
os.path.join(data_dir, "run_info-srnaseq_bowtie.yaml")]
subprocess.check_call(cl)
示例9: test_7_cancer_nonormal
def test_7_cancer_nonormal(install_test_files, data_dir):
"""Test cancer calling without normal samples or with normal VCF panels.
Requires MuTect and GATK.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, "run_info-cancer2.yaml")]
subprocess.check_call(cl)
示例10: test_2_rnaseq
def test_2_rnaseq(install_test_files, data_dir):
"""Run an RNA-seq analysis with TopHat and generate gene-level counts.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "110907_ERP000591"),
os.path.join(data_dir, "run_info-rnaseq.yaml")]
subprocess.check_call(cl)
示例11: test_3_full_pipeline
def test_3_full_pipeline(install_test_files, data_dir):
"""Run full automated analysis pipeline with multiplexing.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "110106_FC70BUKAAXX"),
os.path.join(data_dir, "run_info.yaml")]
subprocess.check_call(cl)
示例12: test_2_scrnaseq
def test_2_scrnaseq(install_test_files, data_dir):
"""Run a single-cell RNA-seq analysis
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "Harvard-inDrop"),
os.path.join(data_dir, "run_info-scrnaseq.yaml")]
subprocess.check_call(cl)
示例13: test_2_star
def test_2_star(install_test_files, data_dir):
"""Run an RNA-seq analysis with STAR and generate gene-level counts.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "test_fusion"),
os.path.join(data_dir, "run_info-star.yaml")]
subprocess.check_call(cl)
示例14: test_2_fastrnaseq
def test_2_fastrnaseq(install_test_files, data_dir):
"""Run a fast RNA-seq analysis
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "test_fusion"),
os.path.join(data_dir, "run_info-fastrnaseq.yaml")]
subprocess.check_call(cl)
示例15: test_4_empty_fastq
def test_4_empty_fastq(install_test_files, data_dir):
"""Handle analysis of empty fastq inputs from failed runs.
"""
with make_workdir() as workdir:
cl = ["bcbio_nextgen.py",
get_post_process_yaml(data_dir, workdir),
os.path.join(data_dir, os.pardir, "110221_empty_FC12345AAXX"),
os.path.join(data_dir, "run_info-empty.yaml")]
subprocess.check_call(cl)