Skip to content

Commit 86b0bf6

Browse files
authored
Merge pull request #4 from RSGInc/asim-core
fix issue in activitysim.abm.models.util.mode where reset_index level…
2 parents ddb7854 + 9133d55 commit 86b0bf6

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

activitysim/abm/models/util/mode.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,9 +128,9 @@ def expand_alternatives(df):
128128
# now concat all the lists
129129
new_alts = sum(alts, [])
130130

131-
df.reset_index("Alternative", inplace=True)
131+
df.reset_index(["Alternative"], inplace=True)
132132
df["Alternative"] = new_alts
133-
# rowid needs to bet set here - we're going to unstack this and we need
133+
# rowid needs to be set here - we're going to unstack this and we need
134134
# a unique identifier to keep track of the rows during the unstack
135135
df = df.set_index(['Rowid', 'Alternative'], append=True)
136136

activitysim/abm/models/util/test/test_cdap.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ def cdap_indiv_and_hhsize1(data_dir):
3030
return read_model_spec(
3131
os.path.join(data_dir, 'cdap_indiv_and_hhsize1.csv'))
3232

33+
3334
@pytest.fixture(scope='module')
3435
def cdap_interaction_coefficients(data_dir):
3536
f = os.path.join(data_dir, 'cdap_interaction_coefficients.csv')

0 commit comments

Comments
 (0)