-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Transit group priority - Part 1 #4999
Transit group priority - Part 1 #4999
Conversation
I tested all test cases in issue #3665: Test ResultsCase 1
Case 2
Case 3
Case 4
Case 5
Case 6
Case 7
Case 8
Case 9
Case 10
Case 11 Case 12 |
72a0ad5
to
38a0c34
Compare
This enables us to pass in the relax function to use with transit-group-priority (model not implemented jet).
38a0c34
to
04f721d
Compare
I want to merge this to avoid falling to fare behind, I will make a second PR - Part 2 to fix the reminding tasks. |
Please format. |
src/main/java/org/opentripplanner/standalone/config/routerequest/RouteRequestConfig.java
Outdated
Show resolved
Hide resolved
...rg/opentripplanner/routing/algorithm/raptoradapter/transit/request/PriorityGroupMatcher.java
Outdated
Show resolved
Hide resolved
src/main/java/org/opentripplanner/standalone/config/framework/json/NodeInfoBuilder.java
Show resolved
Hide resolved
src/main/java/org/opentripplanner/standalone/config/routerequest/RouteRequestConfig.java
Outdated
Show resolved
Hide resolved
...main/java/org/opentripplanner/standalone/config/routerequest/TransitPriorityGroupConfig.java
Outdated
Show resolved
Hide resolved
...main/java/org/opentripplanner/standalone/config/routerequest/TransitPriorityGroupConfig.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are a few tiny suggestions.
...nner/routing/algorithm/raptoradapter/transit/cost/grouppriority/TransitPriorityGroup32n.java
Outdated
Show resolved
Hide resolved
...nner/routing/algorithm/raptoradapter/transit/cost/grouppriority/TransitPriorityGroup32n.java
Outdated
Show resolved
Hide resolved
...rg/opentripplanner/routing/algorithm/raptoradapter/transit/request/PriorityGroupMatcher.java
Outdated
Show resolved
Hide resolved
...entripplanner/routing/algorithm/raptoradapter/transit/request/PriorityGroupConfigurator.java
Outdated
Show resolved
Hide resolved
src/main/java/org/opentripplanner/routing/api/request/request/TransitRequest.java
Outdated
Show resolved
Hide resolved
.../routing/algorithm/raptoradapter/transit/cost/grouppriority/TransitPriorityGroup32nTest.java
Outdated
Show resolved
Hide resolved
src/main/java/org/opentripplanner/standalone/config/framework/json/NodeInfo.java
Outdated
Show resolved
Hide resolved
Co-authored-by: Johan Torin <jtorin@users.noreply.github.com> Co-authored-by: Leonard Ehrenfried <mail@leonard.io>
61128c8
to
db846ce
Compare
db846ce
to
f0bf669
Compare
Please resolve the conflicts. |
…c_criteria # Conflicts: # src/main/java/org/opentripplanner/raptor/api/request/SearchParams.java
2ef7013
to
5083681
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found some minor question-marks.
private final RoutingTripPattern railA = routeA.getTripPattern().getRoutingTripPattern(); | ||
private final RoutingTripPattern busB = routeB.getTripPattern().getRoutingTripPattern(); | ||
private final RoutingTripPattern railC = routeC.getTripPattern().getRoutingTripPattern(); | ||
private final RoutingTripPattern ferryC = routeD.getTripPattern().getRoutingTripPattern(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be ferryD
?
private final TripPattern bus = b1.getTripPattern(); | ||
private final TripPattern ferry = f1.getTripPattern(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't matter that much, but maybe these two should be bus1
and ferry1
to be consistent. Or just rail
.
@jtorin I will cleanup the test in the next PR... |
Summary
Transit group priority enable routing search where the transit services can be grouped and given mutual priority over other groups. By "mutual priority" we mean that both groups are is prioritised and end up in the result. A relax function is used to say how much worse a group may be before it is dropped. Within the group, only the best options are kept.
Issue
This build on top of PR #4996.
Fixes most of #3665
Unit tests
TODO
reluctanceForMode
uses route mode, not Trip/pattern #5248Documentation
TODO