NREL / routee-compass

An energy-aware routing engine
https://nrel.github.io/routee-compass/
BSD 3-Clause "New" or "Revised" License
10 stars 5 forks source link

edge rtree will explore entire graph in degenerate cases #180

Closed robfitzgerald closed 7 months ago

robfitzgerald commented 7 months ago

i'm seeing this with MEP runs. i have some hex that's in northeast alaska. i have the edge_rtree accepting only road classes [4,5,6,7] within 1 kilometer (can you see the problem already? i didn't 😸 ).

... ... ... ... ...

ok, here's what happens:

  1. no links are found within 1 kilometer that have [4,5,6,7] road class
  2. every link outside 1 kilometer is outside 1 kilometer (yay, a tautology)

result: plugin iterates over every edge in in the graph and returns an error not found.

the solution is a re-write to the search method in edge_rtree_input_plugin.rs.