Skip to content

Commit

Permalink
fix: fix UnboundLocalError in _select_by_model_devi_standard (#1587)
Browse files Browse the repository at this point in the history
Fix #1586.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Bug Fixes**
- Fixed an issue where detailed reports were not generated under certain
conditions by ensuring `fp_rest_accurate` and `fp_rest_failed` lists are
always initialized.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Signed-off-by: Jinzhe Zeng <[email protected]>
  • Loading branch information
njzjz authored Jul 15, 2024
1 parent 13dc51f commit a33e270
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions dpgen/generator/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -2345,9 +2345,8 @@ def _select_by_model_devi_standard(
numofspecies = _parse_calypso_input("NumberOfSpecies", calypso_run_opt_path)
min_dis = _parse_calypso_dis_mtx(numofspecies, calypso_run_opt_path)
fp_candidate = []
if detailed_report_make_fp:
fp_rest_accurate = []
fp_rest_failed = []
fp_rest_accurate = []
fp_rest_failed = []
cc = 0
counter = Counter()
counter["candidate"] = 0
Expand Down

0 comments on commit a33e270

Please sign in to comment.