'r1': '/home/cam/projects/forensics/forensics_data/MiSeq_DFSC/R701-A506_S5_L001_R1_001.fastq.gz', 'single': 'single-end', 'threads': '3', }, 'Trimmomatic': { 'a': '', 'd': False, 'm': '20', 'q': '20', 's': True, 'w': '4' }, 'strrazor': { 'workdir': 'STRaitRazor', 'opt': 'ALL', # choice of X, Y, AUTOSOMAL, ALL }, } if 1: interface['Shared']['single'] = 'auto-detect' if len(sys.argv) == 2: interface['Shared']['r1'] = sys.argv[1] success = strrazor(interface, progress=dummypb.StatusProgress()) if success: print 'STRaitRazor pipeline completed successfully' else: print 'STRaitRazor pipeline failed'
'Trimmomatic': { 'c': False, # 'clip': 'ILLUMINACLIP:TruSeq3-SE:2:30:10', 's': True, 'w': '4', 'q': '15', # 'minlen': 'MINLEN:30', 'd': False, 'm': '30', # 'phred': '-phred33', }, 'LobSTR': { 'min-bp-before-indel': '7', 'maximal-end-match': '15', 'min-read-end-match': '5', 'min-border': '5' } } import sys import dummypb if 0: interface['Shared']['single'] = 'auto-detect' if len(sys.argv) == 2: interface['Shared']['r1'] = sys.argv[1] success = lobstr(interface, progress=dummypb.StatusProgress()) if success: print 'LobSTR pipeline completed successfully' else: print 'LobSTR pipeline failed'
'/home/cam/projects/forensics/forensics_data/MiSeq_DFSC/R701-A506_S5_L001_R1_001.fastq.gz', 'single': 'single-end', 'threads': '2', }, 'Trimmomatic': { 'clip': 'ILLUMINACLIP:TruSeq3-SE:2:30:10', 'sliding': 'SLIDINGWINDOW:4:15', 'w': '4', 'q': '15', 'minlen': 'MINLEN:30', 'm': '30', 'phred': '-phred33', } } if 0: interface['Shared']['single'] = 'paired-end' if 1: interface['Shared']['single'] = 'auto-detect' import dummypb if len(sys.argv) == 2: interface['Shared']['r1'] = sys.argv[1] res = prepare(interface, 'common', progress=dummypb.StatusProgress()) print "prepare(...) returns:" print " trim_fq =", res[0] print " bn =", res[1] for cmd in res[2]: print "\t", cmd
'phred': '-phred33', }, 'BWA': { 'p': 'ILLUMINA', 'T': '30' }, 'mpileup': {}, } # parameters for paired end testing if 0: # set paired end values interface['Shared'][ 'r1'] = '/home/cam/projects/forensics/forensics_data/MiSeq_DFSC/R701-A506_S5_L001_R1_001.fastq.gz' interface['Shared']['single'] = 'single-end' if 0: # run deduplication step interface['Shared']['dedup'] = True if 1: interface['Shared']['single'] = 'auto-detect' if len(sys.argv) == 2: interface['Shared']['r1'] = sys.argv[1] success = tovcf(interface, progress=dummypb.StatusProgress()) if success: print 'ToVCF pipeline completed successfully' else: print 'ToVCF pipeline failed' print "... using", interface['Shared']['tovcf']
progress.status('Step 1 - extracting FASTQ file(s)') files, sf = com.bam2fq(srcdir, dstdir, args['single']) cmds = [(None, 'b')] # first task shows up on progress bar for f in files: # use -f flag to avoid user dialog - force progress/overwrite cmds.append(([loc['gzip'], '-f', f], 'nb')) success = px.run_pipeline(cmds, logger=logger, progress=progress) if success: progress.status('conversion complete') return success if __name__ == '__main__': """ run the BAM to FASTQ process""" import sys import dummypb as sp # define dummy interface output so we can get started interface = {'Shared': {}, 'BAMtoFQ': {}} assert len(sys.argv) == 2 interface['BAMtoFQ']['b'] = sys.argv[1] success = bamToFQ(interface, progress=sp.StatusProgress()) if success: print 'BAM converted to FASTQ successfully' else: print 'BAM conversion to FASTQ failure'