Skip to content

Commit 2ea1eb7

Browse files
wanghan-iapcmHan Wang
andauthored
implement exploration report by BigParameter (#39)
Co-authored-by: Han Wang <wang_han@iapcm.ac.cn>
1 parent ecffb70 commit 2ea1eb7

5 files changed

Lines changed: 6 additions & 5 deletions

File tree

dpgen2/flow/dpgen_loop.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
OPIOSign,
2323
Artifact,
2424
Slices,
25+
BigParameter,
2526
)
2627
import pickle, jsonpickle, os
2728
from typing import (
@@ -47,7 +48,7 @@ class SchedulerWrapper(OP):
4748
def get_input_sign(cls):
4849
return OPIOSign({
4950
"exploration_scheduler" : Artifact(Path),
50-
"exploration_report": ExplorationReport,
51+
"exploration_report": BigParameter(ExplorationReport),
5152
"trajs": Artifact(List[Path]),
5253
})
5354

dpgen2/op/select_confs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def get_input_sign(cls):
3030
@classmethod
3131
def get_output_sign(cls):
3232
return OPIOSign({
33-
"report" : ExplorationReport,
33+
"report" : BigParameter(ExplorationReport),
3434

3535
"confs" : Artifact(List[Path]),
3636
})

tests/test_block_cl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ def test(self):
230230
step = wf.query_step(name='step')[0]
231231
self.assertEqual(step.phase, "Succeeded")
232232

233-
report = jsonpickle.decode(step.outputs.parameters['exploration_report'].value)
233+
report = step.outputs.parameters['exploration_report'].value
234234
download_artifact(step.outputs.artifacts["iter_data"], path = 'iter_data')
235235
download_artifact(step.outputs.artifacts["models"], path = Path('models')/self.name)
236236

tests/test_prep_run_lmp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,6 @@ def test(self):
281281
download_artifact(step.outputs.artifacts["trajs"])
282282
download_artifact(step.outputs.artifacts["logs"])
283283

284-
for ii in jsonpickle.decode(step.outputs.parameters['task_names'].value):
284+
for ii in step.outputs.parameters['task_names'].value:
285285
self.check_run_lmp_output(ii, self.model_list)
286286

tests/test_prep_run_vasp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ def test(self):
259259
download_artifact(step.outputs.artifacts["labeled_data"])
260260
download_artifact(step.outputs.artifacts["logs"])
261261

262-
for ii in jsonpickle.decode(step.outputs.parameters['task_names'].value):
262+
for ii in step.outputs.parameters['task_names'].value:
263263
self.check_run_vasp_output(ii)
264264

265265
# for ii in range(6):

0 commit comments

Comments
 (0)