Mercurial > repos > greg > queue_genotype_workflow
comparison queue_genotype_workflow.py @ 10:41477ff2ce8e draft
Uploaded
author | greg |
---|---|
date | Wed, 26 Aug 2020 13:49:26 -0400 |
parents | b7212fe2d597 |
children | 0882b7bb3dfc |
comparison
equal
deleted
inserted
replaced
9:0ed7dc418a6d | 10:41477ff2ce8e |
---|---|
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 import argparse | 2 import argparse |
3 import os | 3 import os |
4 import shutil | 4 import shutil |
5 import string | |
6 import sys | 5 import sys |
7 import threading | 6 import threading |
8 import time | 7 import time |
8 from datetime import datetime | |
9 | 9 |
10 from bioblend import galaxy | 10 from bioblend import galaxy |
11 from datetime import datetime | 11 |
12 from six.moves import configparser | 12 from six.moves import configparser |
13 | 13 |
14 parser = argparse.ArgumentParser() | 14 parser = argparse.ArgumentParser() |
15 parser.add_argument('--affy_metadata', dest='affy_metadata', help='Input Affymetrix 96 well plate metadata file') | 15 parser.add_argument('--affy_metadata', dest='affy_metadata', help='Input Affymetrix 96 well plate metadata file') |
16 parser.add_argument('--annot', dest='annot', help='Probeset annotation file') | 16 parser.add_argument('--annot', dest='annot', help='Probeset annotation file') |
78 d = {} | 78 d = {} |
79 config_parser = configparser.ConfigParser() | 79 config_parser = configparser.ConfigParser() |
80 config_parser.read(config_file) | 80 config_parser.read(config_file) |
81 for key, value in config_parser.items(section): | 81 for key, value in config_parser.items(section): |
82 if section == 'defaults': | 82 if section == 'defaults': |
83 d[string.upper(key)] = value | 83 d[key.upper()] = value |
84 else: | 84 else: |
85 d[key] = value | 85 d[key] = value |
86 return d | 86 return d |
87 | 87 |
88 | 88 |
264 outputfh.write("Updated step id %s with the following entry:\n%s\n" % (step_id, str(reference_genome_source_cond_dict))) | 264 outputfh.write("Updated step id %s with the following entry:\n%s\n" % (step_id, str(reference_genome_source_cond_dict))) |
265 if tool_id.find('coral_multilocus_genotype') > 0 and output_nj_phylogeny_tree == 'yes': | 265 if tool_id.find('coral_multilocus_genotype') > 0 and output_nj_phylogeny_tree == 'yes': |
266 # Reset the default value 'no' of output_nj_phylogeny_tree to 'yes'. | 266 # Reset the default value 'no' of output_nj_phylogeny_tree to 'yes'. |
267 if parameter_updates is None: | 267 if parameter_updates is None: |
268 parameter_updates = {} | 268 parameter_updates = {} |
269 output_nj_phylogeny_tree_dict = {'output_nj_phylogeny_tree' : 'yes'} | 269 output_nj_phylogeny_tree_dict = {'output_nj_phylogeny_tree': 'yes'} |
270 parameter_updates[step_id] = output_nj_phylogeny_tree_dict | 270 parameter_updates[step_id] = output_nj_phylogeny_tree_dict |
271 outputfh.write("Updated step id %s with the following entry:\n%s\n" % (step_id, str(output_nj_phylogeny_tree_dict))) | 271 outputfh.write("Updated step id %s with the following entry:\n%s\n" % (step_id, str(output_nj_phylogeny_tree_dict))) |
272 return parameter_updates | 272 return parameter_updates |
273 | 273 |
274 | 274 |