BikeNetKit / BikeNetKit/superblockify

feat: Map coloring

Open
#130 2 comments 0 reactions 0 assignees View on GitHub
enhancement good first issue
Dominant language
Python
Stars
33
Forks
4
Avg merge
3h 15m
Merged PRs (30d)
1

Description

**Is your feature request related to a problem?**
After a call with @MoritzStefaner on how to visualize sb's output nicely, we agreed that it would be nice if the map coloring problem was already solved by sb. (I am though not sure if it is already solved? If so, sorry and please close this issue!)

**Proposed Solution**
For example, an int parameter num_colors >= 4, (4 because of https://en.wikipedia.org/wiki/Four_color_theorem) that would give each superblock its own color class, such that all adjacent superblocks have a different class. Adjacency would be defined by the rook contiguity, if we think about the blocks as polygons.

**Alternative Solutions**
This feature could be handy especially in succession with #106 , after too small or too big superblocks have been merged/split or discarded.

**Use Cases**
Describe specific use cases for this feature:

1. As someone who wants to visualize the output of sb, I want to ensure that all adjacent superblocks have a different color, and that I can regulate how many colors to use, because the aesthetically best number might depend on the size of the city or blocks.

**Additional Context**
Some Python map coloring package might already exist.

**Willing to Contribute?**
Unfortunately I don't have enough time to develop it, and this feature suggestion is definitely not a request! More a nice to have. Happy to help test/document.

- [ ] I'm willing to submit a PR for this feature
- [X] I can help test this feature
- [X] I can help document this feature

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.