Closed aheld84 closed 4 years ago
Converted to draft since the solution suggested so far is not correct (see #18 )
I have changed the PR such that it does not change the default behavior any more.
An additional penalty for edges without any transit lines can be added by setting routing_no_lines_punish_fac
to a positive value in the config. The punishment is only active when no explicit transit line name/from/to was requested in the routing attrs.
Great, thank you very much. Merged.
This relates to #18
Currently, if no transit line is given, all edges get penalty factor 0 regardless of whether there are transit lines following the edge or not. The change introduced in this commit will give penalty factor 0 if there is at least one transit line following the edge and penalty factor 1 if there are no transit lines at all following the edge. Behavior in the case when a transit line is given is untouched.
This should improve routing results by preferring edges with associated transit lines. This used to be the behavior before some refactoring. Maybe it was broken unintentionally.