Skip to content

Commit b2905cd

Browse files
authored
Fix index error by repeated lambda updates (#45)
Update constraints.py Reset list of constraint penalty functions to avoid endless additions. Signed-off-by: Henri Karhula <[email protected]>
1 parent 5f4c2a8 commit b2905cd

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Diff for: src/mqt/qao/constraints.py

+1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ def translate_constraints(self, var: Variables) -> tuple[bool, Variables]:
5555
bool -- for identifying eventual errors or issue in the conversion
5656
auxiliary_variables -- variable added for writing constraints
5757
"""
58+
self.constraints_penalty_functions = []
5859
auxiliary_variables = Variables()
5960
i = 0
6061
j = 0

0 commit comments

Comments
 (0)