File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 8181 }
8282)
8383
84+ def expand_sys_str (root_dir : Union [str , Path ]) -> List [str ]:
85+ root_dir = Path (root_dir )
86+ matches = [str (d ) for d in root_dir .rglob ("*" ) if (d / "type.raw" ).is_file ()]
87+ if (root_dir / "type.raw" ).is_file ():
88+ matches .append (str (root_dir ))
89+ return matches
90+
8491def make_concurrent_learning_op (
8592 train_style : str = 'dp' ,
8693 explore_style : str = 'lmp' ,
@@ -329,7 +336,10 @@ def workflow_concurrent_learning(
329336 )
330337 fp_arti = upload_artifact (
331338 dump_object_to_file (fp_inputs , 'vasp_inputs.dat' ))
332- init_data = upload_artifact (config ['init_data_sys' ])
339+ init_data = config ['init_data_sys' ]
340+ if isinstance (init_data ,str ):
341+ init_data = expand_sys_str (init_data )
342+ init_data = upload_artifact (init_data )
333343 iter_data = upload_artifact ([])
334344 if init_models_paths is not None :
335345 init_models = upload_artifact (init_models_paths )
You can’t perform that action at this time.
0 commit comments