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

added transit level to connectivity map #4082

Merged
merged 4 commits into from
Apr 25, 2023
Merged

Conversation

nilsnolde
Copy link
Member

@nilsnolde nilsnolde commented Apr 22, 2023

To compare colors for transit, we look at level 3 colors but within transit_start_end_max_distance meters of correlated edges, which are still missing the transit connection edges. We wanted to eventually add support for that for multiple reasons anyways: start the journey on such an edge and also to return departure info for /locate. For the connectivity map it's not so bad, at least with the default transit_start_end_max_distance.

Also lets us determine whether transit tiles are loaded with less resources than currently in #4062.

if (!connectivity_map) {
continue;
}
auto colors = connectivity_map->get_colors(TileHierarchy::levels().back().level, correlated, 0);
auto colors = connectivity_map->get_colors(connectivity_level, correlated, connectivity_radius);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pass the full TileLevel, we need access to level 2 or 3 tiles and need to know which level it was

EXPECT_NE(conn.get_color({a2, 2, 0}), conn.get_color({d0, 2, 0})) << "a is disjoint from d";

filesystem::remove_all(tile_dir);
for (const auto& level : {TileHierarchy::levels()[2], TileHierarchy::GetTransitLevel()}) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just added the for loop, nothing else

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah and passing the level to the touch_tile function

@nilsnolde nilsnolde merged commit db07e91 into master Apr 25, 2023
@nilsnolde nilsnolde deleted the nn-transit-connectivity-map branch April 25, 2023 11:45
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.

None yet

2 participants