@@ -141,7 +141,7 @@ def create_top_level_task(
141
141
"-n" ,
142
142
type = click .STRING ,
143
143
help = "name for the specific task" ,
144
- default = "Pathways" ,
144
+ default = "Pathways HGNC " ,
145
145
)
146
146
@click .option (
147
147
"--allow-downloads" ,
@@ -156,13 +156,24 @@ def create_top_level_task(
156
156
default = None ,
157
157
)
158
158
@click .option (
159
- "--top- pathways-file" ,
159
+ "--pathways-relation -file" ,
160
160
type = click .STRING ,
161
161
help = "The location of the ReactomePathwaysRelation file available at https://reactome.org/download-data" ,
162
162
default = None ,
163
163
)
164
+ @click .option (
165
+ "--verbose/--quite" ,
166
+ "-v/-q" ,
167
+ is_flag = True ,
168
+ default = True ,
169
+ )
164
170
def main (
165
- main_task_directory , task_name , allow_downloads , pathways_file , top_pathways_file
171
+ main_task_directory ,
172
+ task_name ,
173
+ allow_downloads ,
174
+ pathways_file ,
175
+ pathways_relation_file ,
176
+ verbose ,
166
177
):
167
178
168
179
reactom_url = (
@@ -172,17 +183,20 @@ def main(
172
183
pathways_file = verify_source_of_data (
173
184
pathways_file , url = reactom_url , allow_downloads = allow_downloads
174
185
)
175
- top_pathways_file = verify_source_of_data (
176
- top_pathways_file , url = TOP_PATHWAYS_URL , allow_downloads = allow_downloads
186
+ pathways_relation_file = verify_source_of_data (
187
+ pathways_relation_file , url = TOP_PATHWAYS_URL , allow_downloads = allow_downloads
177
188
)
178
189
df_path = pd .read_csv (pathways_file , index_col = "Pathway identifier" )
179
190
180
191
hierarchies_df = pd .read_csv (
181
- top_pathways_file , delimiter = "\t " , header = 0 , names = ["parent" , "child" ]
192
+ pathways_relation_file , delimiter = "\t " , header = 0 , names = ["parent" , "child" ]
182
193
)
183
194
symbols , outcomes = create_top_level_task (hierarchies_df , df_path )
184
195
dump_task_definitions (symbols , outcomes , main_task_directory , task_name )
185
-
196
+ if verbose :
197
+ print (
198
+ f"{ task_name } was created at { main_task_directory } shaped { outcomes .shape } "
199
+ )
186
200
return
187
201
188
202
0 commit comments