-
Notifications
You must be signed in to change notification settings - Fork 22
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
Adding fares functionality #51
Merged
Changes from 1 commit
Commits
Show all changes
76 commits
Select commit
Hold shift + click to select a range
6021058
Merge pull request #31 from MetropolitanTransportationCommission/develop
lmz 1cb8f4d
Initial fare implementation
1c82f3e
Fare lookup bug fix
4249653
Output fare and include it in python calculate_cost
083758e
Start implementing stop zones
fcb4dcd
Addendum to last commit
7e8ecd2
Zone-based fares in c++ extension
416bfdd
Add zone-based fares to python
24073fb
Add fare_class to pathset links as well
3e5e9d0
Doc fix
74a42e7
Bug fix: fare_rules suffix so we don't lose route_id
101aed5
Split transit links: fare/fare period only on first
3fed8d7
Merge branch 'develop' into fares
ff7ec9d
Merge branch 'develop' into fares
943032b
Fix fare bug -- set stop zone ids once
bd1e1bb
Apply fare transfers in python
b7af997
Update fare transfer col names, values
11d2743
Add fare to StopState and return to python
bf92f04
Add fare transfer disounts to c++ extension
5f007dc
Update example: add a couple more local bus stops
38d9b21
Fares (python): handle transfers, transfer_duration
3ffe289
apply_free_transfers() missed with last commit
14751ae
Handle free transfer/transfer_duration in c++ ext
f4a080f
Fix walk_access error and make fasttrips complain
c333a24
Merged develop and addressed conflicts
b36e382
Finish merging develop into fares
f92d7ac
Bug fix: somehow this got dropped
22089b4
Bump wait needs trip id num
aee87c8
Keep fare transfer rules columns in output
03e9d8f
Update doc, comment
cdcb005
Bug fix: shape_dist_traveled is cumulative
75852ab
Add probability to StopState
028f3fd
Warn and enforce a minimum value of time
aac6ae6
Links with cost>max_cost are invalid for choosing
3a78924
In StopState, add a pointer to the FarePeriod
9e02040
Don't send lot/stop transfers to c++ extension
2702faa
Shorten some fare period names
7f77cbb
Add fare transfer logic to pathfinding
c260af0
Implement option to transfer_fare_ignore
b07131f
Pass initial cost/fare back to python
cc92111
Updated doc notes
9119a53
One more doc update
8ea4cc6
I can count
22a61f7
Merge develop into fares
9b26033
Fix merge error
2b0bc35
Assess fare attribute-based free transfers in pathfinding
933d964
Hyperlink::setupProbabilities() gets path so far
77eca46
Implemented fare transfers for path enumeration
5aded05
Fix crashing bugs
1fa664e
Rename column according to spec (transfer_fare)
451abd8
Add options to ignore transfer logic for path enum
465016c
Merge pull request #37 from MetropolitanTransportationCommission/develop
lmz 6a7040e
Add transfer fare ignore options to runTest.py
3cbe04f
Merge branch 'fares' of https://github.com/MetropolitanTransportation…
ef3c67e
Add option to output debug columns
5ace663
Fare test script
8db74e9
Fix develop test in testFares.bat
d8c947b
testFares.bat bug fix
39ea190
Option to assume zone-to-zone fare symmetry
459515e
Merge branch 'fares' of https://github.com/MetropolitanTransportation…
30b2e8e
Handle null dist in transfers_ft.txt (assume zero)
8d3fac4
Direction is now a column in walk_access_ft.txt
1cb9b05
Merge develop into fares
0079106
Add direction column to test_network's walk_access_ft.txt
08f0f72
Merge develop into fares
7131be1
Merge branch 'develop' into fares
214064d
Bug fix: handle single large cost valid link
0174f18
Debug: widen mode field in debug trace log
967b698
Merge pull request #41 from MetropolitanTransportationCommission/develop
lmz 5da4048
Create overlap example test
b4242be
Fix trace so it triggers
1118dd9
Handle allowed missing network fields
d953b13
Bug fix: split links have fare on first only
fd058d2
Bug fix: overlap penalty
7461fa1
Update fare test for network 1.10
457a7cd
create_tableau_path_map.py: Handle no trip_ids
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -509,7 +509,10 @@ def setup_passenger_pathsets(self, iteration, stops, trip_id_df, trips_df, modes | |
`pf_iteration` int64 iteration in which these paths were found | ||
`pathnum` int64 the path number for the path within the pathset | ||
`pf_cost` float64 the cost of the entire path | ||
`pf_fare` float64 the fare of the entire path | ||
`pf_probability` float64 the probability of the path | ||
`pf_initcost` float64 the initial cost of the entire path | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "INIT" something in this case is sort of like "FINAL" before "FINAL FINAL". It might be good at some point to change this { and its siblings } to be named after their stage. I.e. "Cost for Pathfinding" rather than "initial cost". |
||
`pf_initfare` float64 the initial fare of the entire path | ||
`description` object string representation of the path | ||
================== =============== ===================================================================================================== | ||
|
||
|
@@ -608,7 +611,10 @@ def setup_passenger_pathsets(self, iteration, stops, trip_id_df, trips_df, modes | |
iteration, | ||
pathnum, | ||
pathset.pathdict[pathnum][PathSet.PATH_KEY_COST], | ||
pathset.pathdict[pathnum][PathSet.PATH_KEY_PROBABILITY] | ||
pathset.pathdict[pathnum][PathSet.PATH_KEY_FARE], | ||
pathset.pathdict[pathnum][PathSet.PATH_KEY_PROBABILITY], | ||
pathset.pathdict[pathnum][PathSet.PATH_KEY_INIT_COST], | ||
pathset.pathdict[pathnum][PathSet.PATH_KEY_INIT_FARE] | ||
]) | ||
|
||
link_num = 0 | ||
|
@@ -689,7 +695,10 @@ def setup_passenger_pathsets(self, iteration, stops, trip_id_df, trips_df, modes | |
Passenger.PF_COL_PF_ITERATION, | ||
Passenger.PF_COL_PATH_NUM, | ||
PathSet.PATH_KEY_COST, | ||
PathSet.PATH_KEY_PROBABILITY ]) | ||
PathSet.PATH_KEY_FARE, | ||
PathSet.PATH_KEY_PROBABILITY, | ||
PathSet.PATH_KEY_INIT_COST, | ||
PathSet.PATH_KEY_INIT_FARE]) | ||
|
||
pathset_links_df = pandas.DataFrame(linklist, columns=[\ | ||
Passenger.TRIP_LIST_COLUMN_PERSON_ID, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
The difference of "cost" and "fare" is not initially obvious.
Perhaps we should use Util instead of cost? Other thoughts?