forked from joshchea/python-tdm
-
Notifications
You must be signed in to change notification settings - Fork 0
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
New nested choice function added #1
Open
joshchea
wants to merge
33
commits into
osPlanning:master
Choose a base branch
from
joshchea:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
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
BaseUtils is not really needed if Utils is provided as the diff in Utils, which should be easy. So script is updated accordingly. Seems like an older half incorrect version of the function was sitting here.
updated description for flat nested mode choice calculation
Script for OD-matrix estimation with least squares formulation, solution method is via Gradient descent applied with sparse matrices. Distance measure - difference in counts and assigned model flows and OD cells from seed and current adjusted matrix. Requires - numpy and scipy | flow matrix obtained from Visum -> user should construct their own if not using other tool for assignment.
added a TO DO to use executemany instead of calling execute n times...
added matrix estimation (ODME) script description
added two variants - a. commit one line at a time - relatively safe method for cell by cell handling of bad data b. commit the entire db at once from an accululated tuple b. runs in half the time as a
added scripts for logit choice park n ride with capacities and gravity model calibration
All files are text files... > Seed OD matrix > Link counts > Flow matrix
Added trip distribution with shadow pricing to balance trip attractions
remove production side calculations in multi-distribute
Added a more vectorized version of doubly constrained gravity with factor multiplied across friction matrix.
cleaned up a couple of things to use numpy instead of built-ins
some cleaning and update to more Python 3+ compatible usage of loops - replace xrange by range etc.
some cleaning and minor updates for Python 3+ compatibility.
some more updates for Pytnon 3+
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Salut...
I added a new function to compute generic nested choice probs on a flat array instead of a square matrix, this may be useful for implementation in activity based models. Please pull from my repo if you feel it might be useful in your activitysim project.
Thanks,
Chetan