Skip to content

Duplicate column names within parking location choice model #633

@jpn--

Description

@jpn--

The parking location choice model is making two passes through the logit.interaction_dataset function.

The first is here:

destination_sample = logit.interaction_dataset(

The second is embedded in the interaction_sample_simulate function called here:

parking_locations = interaction_sample_simulate(

The logit.interaction_dataset function is hard-coded to add a "_chooser" suffix as needed the chooser side of the interaction merge, to disambiguate column names when there are duplicates. However, this can causes clashes when the duplicate is found twice, as then there are duplicate columns named "x_chooser".

After a cursory review and testing, I believe these columns that are created with duplicate names actually contain duplicate data, but the flow of data in the parking location model is complicated and an addition review is warranted (@i-am-sijia since you've recently been working on fixing this model you may be the best positioned to check this). If the data is indeed systematically duplicated, for memory efficiency we should avoid creating the duplicate columns. If not, this is a serious problem that should be fixed. A more careful review (and testing regime) is needed to confirm for former is sufficient.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugSomething isn't working/bug f

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions