Skip to content

Commit 136a1f0

Browse files
committed
poetry fixes
1 parent 246a029 commit 136a1f0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/axiomatic/pic_helpers.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import re
2-
from typing import Dict, List, Optional, Set, Tuple
2+
from typing import Dict, List, Optional, Set, Tuple, Union
33

44
import iklayout # type: ignore
55
import matplotlib.pyplot as plt # type: ignore
@@ -98,7 +98,7 @@ def plot_single_spectrum(
9898

9999

100100
def plot_interactive_spectra(
101-
spectra: List[List[List[float]]] | Dict[str, List[List[float]]],
101+
spectra: Union[List[List[List[float]]], Dict[str, List[List[float]]]],
102102
wavelengths: List[float],
103103
spectrum_labels: Optional[List[str]] = None,
104104
vlines: Optional[List[float]] = None,
@@ -121,7 +121,7 @@ def plot_interactive_spectra(
121121

122122
# Defaults
123123
if spectrum_labels is None and isinstance(spectra, dict):
124-
spectrum_labels = [f"T {port_in[0]} -> {port_out[0]}" for port_in, port_out in spectra.keys()]
124+
spectrum_labels = [f"T {port_in} -> {port_out}" for port_in, port_out in spectra.keys()]
125125
elif spectrum_labels is None:
126126
spectrum_labels = [f"Spectrum {i}" for i in range(len(spectra))]
127127
if vlines is None:

0 commit comments

Comments
 (0)