<s> """<STR_LIT>""" <EOL> import os <EOL> import yaml <EOL> from bcbiovm . docker import manage , mounts <EOL> from bcbiovm . ship import pack <EOL> def run ( args , docker_config ) : <EOL> work_dir = os . getcwd ( ) <EOL> parallel = { "<STR_LIT:type>" : "<STR_LIT>" , "<STR_LIT>" : args . queue , "<STR_LIT>" : args . numcores , <EOL> "<STR_LIT>" : "<STR_LIT>" , "<STR_LIT>" : "<STR_LIT>" } <EOL> with open ( args . sample_config ) as in_handle : <EOL> ready_config , _ = mounts . normalize_config ( yaml . load ( in_handle ) , args . fcdir ) <EOL> ready_config_file = os . path . join ( work_dir , "<STR_LIT>" % <EOL> ( os . path . splitext ( os . path . basename ( args . sample_config ) ) ) ) <EOL> with open ( ready_config_file , "<STR_LIT:w>" ) as out_handle : <EOL> yaml . safe_dump ( ready_config , out_handle , default_flow_style = False , allow_unicode = False ) <EOL> parallel [ "<STR_LIT>" ] = pack . prep_s3 ( args . biodata_bucket , args . run_bucket , "<STR_LIT>" ) <EOL> parallel [ "<STR_LIT>" ] = [ { "<STR_LIT>" : ready_config_file , <EOL> "<STR_LIT>" : docker_config , <EOL> "<STR_LIT>" : args . fcdir , <EOL> "<STR_LIT>" : args . datadir , <EOL> "<STR_LIT>" : args . systemconfig } ] <EOL> workdir_mount = "<STR_LIT>" % ( work_dir , docker_config [ "<STR_LIT>" ] ) <EOL> manage . run_bcbio_cmd ( args . image , [ workdir_mount ] , <EOL> [ "<STR_LIT:version>" , "<STR_LIT>" % docker_config [ "<STR_LIT>" ] ] ) <EOL> from bcbio . pipeline import main <EOL> main . run_main ( work_dir , run_info_yaml = ready_config_file , <EOL> config_file = args . systemconfig , fc_dir = args . fcdir , <EOL> parallel = parallel ) </s>
