From 9939e5421c0e5286a24bae57453dcad54ce5c82d Mon Sep 17 00:00:00 2001 From: Diane Trout Date: Mon, 10 Oct 2011 16:57:06 -0700 Subject: [PATCH] Remove ReadPrep and Thumbnail_Images being generated now. --- htsworkflow/pipelines/runfolder.py | 14 +++++++++++--- scripts/htsw-runfolder | 9 +++++++-- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/htsworkflow/pipelines/runfolder.py b/htsworkflow/pipelines/runfolder.py index a3e24f4..fcee65c 100644 --- a/htsworkflow/pipelines/runfolder.py +++ b/htsworkflow/pipelines/runfolder.py @@ -595,7 +595,7 @@ def clean_runs(runs, dry_run=True): logging.info('In dry-run mode') for run in runs: - logging.info('Cleaninging %s' % (run.pathname,)) + logging.info('Cleaning %s' % (run.pathname,)) # rm RunLog*.xml runlogs = glob(os.path.join(run.pathname, 'RunLog*xml')) rm_list(runlogs, dry_run) @@ -614,9 +614,17 @@ def clean_runs(runs, dry_run=True): logging.info("Cleaning images") image_dirs = glob(os.path.join(run.pathname, 'Images', 'L*')) rm_list(image_dirs, dry_run) - # cd Data/C1-*_Firecrest* - logging.info("Cleaning intermediate files") + # rm ReadPrep + logging.info("Cleaning ReadPrep*") + read_prep_dirs = glob(os.path.join(run.pathname, 'ReadPrep*')) + rm_list(read_prep_dirs, dry_run) + # rm ReadPrep + logging.info("Cleaning Thubmnail_images") + thumbnail_dirs = glob(os.path.join(run.pathname, 'Thumbnail_Images')) + rm_list(thumbnail_dirs, dry_run) + # make clean_intermediate + logging.info("Cleaning intermediate files") if os.path.exists(os.path.join(run.image_analysis.pathname, 'Makefile')): clean_process = subprocess.Popen(['make', 'clean_intermediate'], cwd=run.image_analysis.pathname,) diff --git a/scripts/htsw-runfolder b/scripts/htsw-runfolder index e98360a..7ae95b4 100755 --- a/scripts/htsw-runfolder +++ b/scripts/htsw-runfolder @@ -46,8 +46,10 @@ def main(cmdlist=None): opts, args = parser.parse_args(cmdlist) logging.basicConfig() - if opts.verbose: - root_log = logging.getLogger() + root_log = logging.getLogger() + if opts.debug: + root_log.setLevel(logging.DEBUG) + elif opts.verbose: root_log.setLevel(logging.INFO) logging.info('Starting htsworkflow illumina runfolder processing tool.') @@ -132,6 +134,9 @@ def make_parser(): parser.add_option('-v', '--verbose', dest='verbose', action='store_true', default=False, help='turn on verbose mode') + parser.add_option('--debug', action='store_true', + default=False, + help='turn on debug logging (implies verbose)') parser.add_option('--dry-run', action='store_true', default=False, help="Don't delete anything (in clean mode)") -- 2.30.2