activitysim icon indicating copy to clipboard operation
activitysim copied to clipboard

Location choice logsum overwritten with mode choice logsum in estimation mode

Open dhensle opened this issue 1 year ago • 0 comments

Describe the bug The location choice logsum gets overwritten by the mode choice logsum in location choice when running in estimation mode.

To Reproduce Run the estimation example with the DEST_CHOICE_LOGSUM_COLUMN_NAME set in the workplace or school location yaml.

Expected behavior The location choice logsum should be the location choice logsum, not the mode choice logsum.

Screenshots workplace location and modechoice logsums are the same, as seen in the below trace image

Additional context This only occurs in estimation mode. The previous code unnecessarily overwrote the location choice logsum with the mode choice logsum of the selected alternative. Based on the code, it seems this was done because the previous coder did not fully comprehend the difference between the location and modechoice logsums, thus treating them as the same. This was also likely complicated by the fact that we now allow the user to return both the modechoice and location choice logsums separately.

dhensle avatar Oct 02 '24 17:10 dhensle