Skip to content
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

Print info about no alternative found #404

Closed
bstabler opened this issue Mar 30, 2021 · 1 comment
Closed

Print info about no alternative found #404

bstabler opened this issue Mar 30, 2021 · 1 comment

Comments

@bstabler
Copy link
Contributor

bstabler commented Mar 30, 2021

Idea Level-of-effort Notes Priority
Print info about no alternative found Hours When no alternative is found in a choice model, log which terms in the utility turn off all alternatives since this is really helpful info in debugging. High
@bstabler
Copy link
Contributor Author

bstabler commented Jun 3, 2021

Often times a choice model cannot select an alternative since all alternatives are unavailable. This is usually due to a data and/or expression issue/inconsistency. For example, school location choice may not be able to select a school location zone for a student if the school location must be within X miles of the home zone and there is no school enrollment in the zonal land use data for zones within X miles of the household and therefore no valid school zones. In this case, the model throws an exception that no school location can be found. It would be helpful in this situation to log which expressions turn off alternatives since this is typically a big clue in figuring out what the problem might be. In the example above there are two relevant expressions: school enrollment > 0 and school distance < X. Together, these two expressions return -999 (or similar) for all alternatives, thereby making no alternative available. If no alternative can be found, then ActivitySim should log the expressions that turn off alternatives. I think we can specify turning off an alternative as returning something like -999 or -9999 or < -100. I think ActivitySim could log something like "No alternative found. Note expressions 'school enrollment > 0' and 'school distance < X' turned off alternatives."

@bstabler bstabler mentioned this issue Jun 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant