Add should_generate

This commit is contained in:
Contramundum
2023-08-31 17:31:12 +09:00
parent 4f6c78b18f
commit c05d0bd866
3 changed files with 48 additions and 2 deletions
@@ -35,7 +35,7 @@ def main() -> NoReturn:
while True:
# If n_comparison "best" trials (that are not reported bad) exists,
# the generator waits for human evaluation.
if len(study.best_trials) >= n_comparison:
if study.should_generate():
time.sleep(0.1) # Avoid busy-loop
continue