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

Make graphviz colors consistent and fix color bug #9

Merged
merged 3 commits into from
Nov 9, 2023

Conversation

saulshanabrook
Copy link
Member

This PR makes the colors assigned to different types consistent across multiple e-graphs with the same types. Previously, they could differ, which would lead to harder to understand diffs.

It also fixes a bug where if there were more types than the max number of colors, it would assign an incorrect color ID.

Currently, if you have two graphs which use the same types, the colors
per type might be different, depending on which type comes first.

This makes comparing similar graphs harder visually.

This resolves that by using a sorted map for mapping types to values,
so that if the same set of types are used by two graphs, they will
have the same colors.
@mwillsey mwillsey merged commit 3ca6da9 into egraphs-good:main Nov 9, 2023
2 checks passed
@saulshanabrook saulshanabrook deleted the consistant-olors branch November 10, 2023 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants