Skip to content

Commit 6fa410d

Browse files
committed
Add more optimization logging
1 parent ce116a2 commit 6fa410d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

proseco/catalog.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -433,6 +433,7 @@ def optimize_acqs_fids(self):
433433
or len(self.fids.cand_fids) == 0
434434
or len(self.fids.cand_fid_sets) == 0
435435
):
436+
self.log("No acq-fid optimization required")
436437
return
437438

438439
# Start with the no-fids optimum catalog and save required info to restore
@@ -470,11 +471,13 @@ def optimize_acqs_fids(self):
470471

471472
# Iterate through each spoiler_score group and then within that iterate
472473
# over each fid set.
474+
n_tries = 0
473475
for fid_set_group in fid_sets.groups:
474476
spoiler_score = fid_set_group["spoiler_score"][0]
475477
self.log(f"Checking fid sets with spoiler_score={spoiler_score}", level=1)
476478

477479
for fid_set in fid_set_group:
480+
n_tries += 1
478481
# Set the internal acqs fid set. This does validation of the set
479482
# and also calls update_p_acq_column().
480483
acqs.fid_set = fid_set["fid_ids"]
@@ -547,7 +550,7 @@ def optimize_acqs_fids(self):
547550

548551
self.log(
549552
f"Best acq-fid set: P2={best_P2:.2f} "
550-
f"acq_idxs={best_acq_idxs} halfws={best_acq_halfws} fid_ids={acqs.fid_set}"
553+
f"acq_idxs={best_acq_idxs} halfws={best_acq_halfws} fid_ids={acqs.fid_set} N opt runs={n_tries}"
551554
)
552555

553556
if best_P2 < stage_min_P2:

0 commit comments

Comments
 (0)