@@ -42,10 +42,9 @@ def run_impute(
42
42
conf_file = "../conf/minimal-configuration.json" ,
43
43
project_dir_graph = "" ,
44
44
project_dir_in_file = "" ,
45
- hap_pop_pair = False ,
46
- graph = None
45
+ hap_pop_pair = False ,
46
+ graph = None ,
47
47
):
48
-
49
48
configuration_file = conf_file
50
49
51
50
# project_dir = ""# "../"
@@ -81,12 +80,24 @@ def run_impute(
81
80
+ json_conf .get ("edges_csv_file" ),
82
81
"imputation_input_file" : project_dir_in_file
83
82
+ json_conf .get ("imputation_in_file" ),
84
- "imputation_out_umug_freq_file" : full_path (output_dir , json_conf .get ("imputation_out_umug_freq_filename" )),
85
- "imputation_out_umug_pops_file" : full_path (output_dir , json_conf .get ("imputation_out_umug_pops_filename" )),
86
- "imputation_out_hap_freq_file" : full_path (output_dir , json_conf .get ("imputation_out_hap_freq_filename" )),
87
- "imputation_out_hap_pops_file" : full_path (output_dir , json_conf .get ("imputation_out_hap_pops_filename" )),
88
- "imputation_out_miss_file" : full_path (output_dir , json_conf .get ("imputation_out_miss_filename" )),
89
- "imputation_out_problem_file" : full_path (output_dir , json_conf .get ("imputation_out_problem_filename" )),
83
+ "imputation_out_umug_freq_file" : full_path (
84
+ output_dir , json_conf .get ("imputation_out_umug_freq_filename" )
85
+ ),
86
+ "imputation_out_umug_pops_file" : full_path (
87
+ output_dir , json_conf .get ("imputation_out_umug_pops_filename" )
88
+ ),
89
+ "imputation_out_hap_freq_file" : full_path (
90
+ output_dir , json_conf .get ("imputation_out_hap_freq_filename" )
91
+ ),
92
+ "imputation_out_hap_pops_file" : full_path (
93
+ output_dir , json_conf .get ("imputation_out_hap_pops_filename" )
94
+ ),
95
+ "imputation_out_miss_file" : full_path (
96
+ output_dir , json_conf .get ("imputation_out_miss_filename" )
97
+ ),
98
+ "imputation_out_problem_file" : full_path (
99
+ output_dir , json_conf .get ("imputation_out_problem_filename" )
100
+ ),
90
101
"factor_missing_data" : json_conf .get ("factor_missing_data" , 0.01 ),
91
102
"loci_map" : json_conf .get (
92
103
"loci_map" , {"A" : 1 , "B" : 3 , "C" : 2 , "DQB1" : 4 , "DRB1" : 5 }
@@ -180,7 +191,7 @@ def run_impute(
180
191
181
192
config ["full_loci" ] = "" .join (sorted (all_loci_set ))
182
193
# Perform imputation
183
- if graph == None :
194
+ if graph == None :
184
195
graph = Graph (config )
185
196
graph .build_graph (
186
197
config ["node_file" ], config ["top_links_file" ], config ["edges_file" ]
0 commit comments