Skip to content

Commit

Permalink
if PLive in name, dont split
Browse files Browse the repository at this point in the history
  • Loading branch information
peterdudfield committed Feb 16, 2024
1 parent 5f5fd56 commit 827ce61
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/plots/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def get_colour_from_model_name(model_name, opacity=1.0):
# get colour from model, some models have a space and a datetime
model_name_only = model_name.split(" ")[0]
colour = colour_per_model.get(model_name_only, "#FFFFFF")
if "PVLive" in model_name:
colour = colour_per_model.get(model_name, "#FFFFFF")

# change opacity to hex
rgb = hex_to_rgb(colour)
Expand Down

0 comments on commit 827ce61

Please sign in to comment.