Skip to content

Commit

Permalink
Update Colors()
Browse files Browse the repository at this point in the history
  • Loading branch information
glenn-jocher committed May 5, 2021
1 parent b18ca31 commit ab45b69
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion utils/plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@
class Colors:
# Ultralytics color palette https://ultralytics.com/
def __init__(self):
self.palette = [self.hex2rgb(c) for c in matplotlib.colors.TABLEAU_COLORS.values()]
# hex = matplotlib.colors.TABLEAU_COLORS.values()
hex = ('FF3838', 'FF9D97', 'FF701F', 'F3D09A', 'FFF172', 'FFC804', 'B8E45A', '5AE499', '1A9334', '80FFF0',
'2C99A8', 'CCF3FF', '344593', '6473FF', '0018EC', '8438FF', '520085', 'CB38FF', 'FF95C8', 'FF37C7')
self.palette = [self.hex2rgb('#' + c) for c in hex]
self.n = len(self.palette)

def __call__(self, i, bgr=False):
Expand Down

0 comments on commit ab45b69

Please sign in to comment.