Skip to content

Commit e84ea05

Browse files
committed
Remove empty pool checking since we will never reach it.
We have forcely remained one config by setting `action[0] = True`, so this condition is always False.
1 parent fc413a8 commit e84ea05

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

qmb/rldiag.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
This file implements the reinforcement learning based subspace diagonalization algorithm.
33
"""
44

5-
import sys
65
import logging
76
import typing
87
import dataclasses
@@ -179,9 +178,6 @@ def main(self) -> None:
179178
logging.info("Configuration pool size: %d", configs_size)
180179
writer.add_scalar("rldiag/configs/global", configs_size, data["rldiag"]["global"]) # type: ignore[no-untyped-call]
181180
writer.add_scalar("rldiag/configs/local", configs_size, data["rldiag"]["local"]) # type: ignore[no-untyped-call]
182-
if configs_size == 0:
183-
logging.info("All configurations has been pruned, please start a new configuration pool state")
184-
sys.exit(0)
185181

186182
if last_state is not None:
187183
old_state = last_state[torch.cat([action.nonzero()[:, 0], torch.logical_not(action).nonzero()[:, 0]])]

0 commit comments

Comments
 (0)