Skip to content

Commit

Permalink
Fix plotting bug
Browse files Browse the repository at this point in the history
  • Loading branch information
utf committed Sep 30, 2024
1 parent b39b8b2 commit 40f405f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/ifermi/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -1341,8 +1341,14 @@ def get_isosurface_colors(
raise ValueError(
"colors dict must have same number of spin channels as spins to plot"
)
if isinstance(fermi_object, FermiSurface):
return [
colors[s]
for s in spins
for _ in range(fermi_object.n_surfaces_per_spin[s])
]
return [
colors[s] for s in spins for _ in range(fermi_object.n_surfaces_per_spin[s])
colors[s] for s in spins for _ in range(fermi_object.n_lines_per_spin[s])
]

elif isinstance(colors, str):
Expand Down

0 comments on commit 40f405f

Please sign in to comment.