Skip to content

Commit

Permalink
fixing the fix
Browse files Browse the repository at this point in the history
  • Loading branch information
DanPuzzuoli committed Jan 22, 2024
1 parent 1ef6cc2 commit 90b5284
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions qiskit_dynamics/perturbation/solve_lmde_perturbation.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,9 @@ def solve_lmde_perturbation(
else:
# validate perturbation_labels
perturbations_len = len(perturbation_labels)
perturbation_labels_reduced = _clean_multisets(perturbation_labels)
if len(perturbation_labels_reduced) != perturbations_len:
perturbation_labels = [Multiset(x) for x in perturbation_labels]
cleaned_perturbation_labels = _clean_multisets(perturbation_labels)
if len(cleaned_perturbation_labels) != perturbations_len:
raise QiskitError("perturbation_labels argument contains duplicates as multisets.")

expansion_labels = _merge_multiset_expansion_order_labels(
Expand Down

0 comments on commit 90b5284

Please sign in to comment.