|
1 | 1 | import argparse |
2 | 2 | import configparser |
3 | 3 | from streamline.utils.parser_helpers import str2bool, save_config, load_config |
4 | | -from streamline.utils.parser_helpers import parse_general |
| 4 | +from streamline.utils.parser_helpers import parse_general, parse_replicate |
5 | 5 | from streamline.utils.parser_helpers import parse_logistic |
6 | 6 | from streamline.utils.parser_helpers import parser_function_all |
7 | 7 | from streamline.utils.parser_helpers import PARSER_LIST |
@@ -88,6 +88,17 @@ def single_parse(mode_params, argv, config_dict=None): |
88 | 88 | else: |
89 | 89 | config_dict = load_config(config_dict['output_path'], |
90 | 90 | config_dict['experiment_name'], config_dict) |
| 91 | + if i == 9: |
| 92 | + config_dict_copy = parse_replicate(argv, config_dict) |
| 93 | + if not config_dict_copy['rep_data_path'] == "": |
| 94 | + config_dict['rep_data_path'] = config_dict_copy['rep_data_path'] |
| 95 | + if not config_dict_copy['dataset_for_rep'] == "": |
| 96 | + config_dict['dataset_for_rep'] = config_dict_copy['dataset_for_rep'] |
| 97 | + if not config_dict_copy['rep_export_feature_correlations']: |
| 98 | + config_dict['rep_export_feature_correlations'] \ |
| 99 | + = config_dict_copy['rep_export_feature_correlations'] |
| 100 | + if not config_dict_copy['exclude_rep_plots'] == 'None': |
| 101 | + config_dict['exclude_rep_plots'] = config_dict_copy['exclude_rep_plots'] |
91 | 102 | config_dict = parse_logistic(argv, config_dict) |
92 | 103 | return config_dict |
93 | 104 |
|
@@ -140,17 +151,26 @@ def parser_function(argv): |
140 | 151 | config.read(config_file) |
141 | 152 | for s in config.sections(): |
142 | 153 | config_dict.update({k: eval(v) for k, v in config.items(s)}) |
| 154 | + save_config(config_dict['output_path'], |
| 155 | + config_dict['experiment_name'], |
| 156 | + config_dict) |
143 | 157 | elif mode_params['do_till_report']: |
144 | 158 | print("Running till Report Generation Stage") |
145 | 159 | config = parser_function_all(argv) |
146 | 160 | config_dict.update(config) |
147 | 161 | config_dict.update(mode_params) |
| 162 | + save_config(config_dict['output_path'], |
| 163 | + config_dict['experiment_name'], |
| 164 | + config_dict) |
148 | 165 |
|
149 | 166 | for key in mode_params: |
150 | 167 | if mode_params[key] and key not in ['config', 'do_till_report']: |
151 | 168 | config = single_parse(mode_params, argv, config_dict) |
152 | 169 | config_dict.update(config) |
153 | 170 | config_dict.update(mode_params) |
| 171 | + save_config(config_dict['output_path'], |
| 172 | + config_dict['experiment_name'], |
| 173 | + config_dict) |
154 | 174 |
|
155 | 175 | config_dict = process_params(config_dict) |
156 | 176 |
|
|
0 commit comments