Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Increase range of colors in "by series" color scheme #6969

Open
cpinflux opened this issue Jun 25, 2024 · 0 comments
Open

Increase range of colors in "by series" color scheme #6969

cpinflux opened this issue Jun 25, 2024 · 0 comments
Labels
proposal Proposal or RFC

Comments

@cpinflux
Copy link

Background

By my understanding there are about 50 different colours that can be assigned when using the "Classic palette (by series name)" scheme. On my dashboards I've a few situations where the same colour is being picked for multiple series. These series are mostly hostnames, with a few hundred different clusters of 2 to 4 hosts. Clashes are likely over that range, and are happening, and I've no good way to change that whilst still using this "by series" functionality

Proposal

I've been playing around with some logic for picking HSV colours deterministically from a much larger range and converting to RGB, but don't know if there would be any potential interest in coding it up for a PR.

I believe that picking any colour with S > 0.75 & V > 0.3 gives a usable colour, and further stylistic tuning to avoid more "primary" colours on certain degrees of Hue should hopefully give many thousands of modern, appealing colours.

Of course, given how the code works, it's impossible to create a coherent colour scheme across series, but this should make clashes exceptionally unlikely.

@cpinflux cpinflux added the proposal Proposal or RFC label Jun 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
proposal Proposal or RFC
Projects
None yet
Development

No branches or pull requests

1 participant