Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

simplify: allow initial models trained by initial data #1201

Merged
merged 1 commit into from
May 4, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 6 additions & 3 deletions dpgen/simplify/simplify.py
Original file line number Diff line number Diff line change
Expand Up @@ -530,12 +530,15 @@
task_name = "task %02d" % jj
sepline("{} {}".format(iter_name, task_name), "-")
jdata["model_devi_jobs"] = [{} for _ in range(ii + 1)]
if ii == 0 and jj < 6:
if ii == 0 and jj < 6 and (jj >= 3 or not jdata.get("init_data_sys", [])):

Check warning on line 533 in dpgen/simplify/simplify.py

View check run for this annotation

Codecov / codecov/patch

dpgen/simplify/simplify.py#L533

Added line #L533 was not covered by tests
if jj == 0:
log_iter("init_pick", ii, jj)
log_iter("init_train", ii, jj)

Check warning on line 535 in dpgen/simplify/simplify.py

View check run for this annotation

Codecov / codecov/patch

dpgen/simplify/simplify.py#L535

Added line #L535 was not covered by tests
init_model(ii, jdata, mdata)
elif jj == 3:
log_iter("init_pick", ii, jj)

Check warning on line 538 in dpgen/simplify/simplify.py

View check run for this annotation

Codecov / codecov/patch

dpgen/simplify/simplify.py#L537-L538

Added lines #L537 - L538 were not covered by tests
init_pick(ii, jdata, mdata)
dlog.info("first iter, skip step 1-5")
else:
dlog.info("first iter, skip step 1-5")

Check warning on line 541 in dpgen/simplify/simplify.py

View check run for this annotation

Codecov / codecov/patch

dpgen/simplify/simplify.py#L541

Added line #L541 was not covered by tests
elif jj == 0:
log_iter("make_train", ii, jj)
make_train(ii, jdata, mdata)
Expand Down