Skip to content

Commit

Permalink
adding missed columns necessary for no school escorting
Browse files Browse the repository at this point in the history
  • Loading branch information
dhensle committed Mar 18, 2024
1 parent 4470dd4 commit d9392f3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions activitysim/abm/models/school_escorting.py
Original file line number Diff line number Diff line change
Expand Up @@ -674,6 +674,8 @@ def school_escorting(
"depart",
"purpose",
"destination",
"escort_participants",
"chauf_tour_id",
]
school_escort_trips = pd.DataFrame(columns=trip_cols)

Expand Down
3 changes: 3 additions & 0 deletions activitysim/abm/models/util/school_escort_tours_trips.py
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,9 @@ def merge_school_escort_trips_into_pipeline(state: workflow.State):

# checking to see if there are school escort trips to merge in
if len(school_escort_trips) == 0:
# if no trips, fill escorting columns with NA
trips[["escort_participants", "school_escort_direction", "school_escort_trip_id",]] = pd.NA
state.replace_table("trips", trips)
return trips

# want to remove stops if school escorting takes place on that half tour so we can replace them with the actual stops
Expand Down

0 comments on commit d9392f3

Please sign in to comment.