Skip to content

Commit bb01cdc

Browse files
committed
repair landuse check
1 parent 4a2b2f2 commit bb01cdc

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

activitysim/examples/prototype_mtc_extended/data_model/input_checks.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,8 @@ def check_pop_per_zone(cls, land_use: pd.DataFrame):
232232
persons_per_household.rename("persons_per_household"), on="household_id"
233233
)
234234
pop = hh.groupby(households.home_zone_id)["persons_per_household"].sum()
235-
return (pop == land_use.set_index("zone_id").TOTPOP).reindex(land_use.index)
235+
lu = land_use.set_index("zone_id")
236+
return pop.reindex(lu.index) == lu.TOTPOP
236237

237238

238239
class NetworkLinks(pa.DataFrameModel):

0 commit comments

Comments
 (0)