Skip to content

Commit

Permalink
Updated microtransit skims to be shared ride 3+ for crossborder model
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeJimFlood committed Apr 19, 2024
1 parent d4035a5 commit 1b215f2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/asim/configs/crossborder/trip_mode_choice.csv
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ util_TNC_SINGLE_IVT,TNC Single - In-vehicle time,c_ivt * s2_time_skims,,,,,,,,,1
util_TNC_SINGLE_wait,TNC Single - Wait time,c_ivt * 1.5 * tnc_single_wait_time,,,,,,,,,1,
util_TNC_SINGLE_cost,TNC Single - Cost,@c_cost * ((tnc_single_base_fare + (df.s2_dist_skims * tnc_single_cost_per_mile) + (df.s2_time_skims * tnc_single_cost_per_minute).clip(lower=tnc_single_cost_minimum)) * 100 + df.s2_cost_skims),,,,,,,,,1,
util_TNC Shared_switch,TNC Shared - switch turn-off (depends on data availability),@((~df.nev_available) & (~df.microtransit_available) & (scenarioYear==2022)),,,,,,,,,,-999
util_TNC_SHARED_IVT,TNC Shared - In-vehicle time,"@df.c_ivt * np.where(df.nev_available, df.nev_time, np.where(df.microtransit_available, df.microtransit_time, df.s2_time_skims)) * tnc_shared_ivt_factor",,,,,,,,,,1
util_TNC_SHARED_IVT,TNC Shared - In-vehicle time,"@df.c_ivt * np.where(df.nev_available, df.nev_time, np.where(df.microtransit_available, df.microtransit_time, df.s3_time_skims)) * tnc_shared_ivt_factor",,,,,,,,,,1
util_TNC_SHARED_wait,TNC Shared - Wait time,"@df.c_ivt * 1.5 * np.where(df.nev_available, nevWaitTime, np.where(df.microtransit_available, microtransitWaitTime, df.tnc_shared_wait_time))",,,,,,,,,,1
util_TNC_SHARED_cost,TNC Shared - Cost,"@c_cost * np.where(df.nev_available, nevCost, np.where(df.microtransit_available, microtransitCost, ((tnc_shared_base_fare + (df.s2_dist_skims * tnc_shared_cost_per_mile) + (df.s2_time_skims * tnc_shared_cost_per_minute).clip(lower=tnc_shared_cost_minimum)))) * 100 + df.s2_cost_skims)",,,,,,,,,,1
util_TNC_SHARED_cost,TNC Shared - Cost,"@c_cost * np.where(df.nev_available, nevCost, np.where(df.microtransit_available, microtransitCost, ((tnc_shared_base_fare + (df.s3_dist_skims * tnc_shared_cost_per_mile) + (df.s3_time_skims * tnc_shared_cost_per_minute).clip(lower=tnc_shared_cost_minimum)))) * 100 + df.s3_cost_skims)",,,,,,,,,,1
#,,,,,,,,,,,,
util_S2_ASC_tour_DA,s2 ASC - Tour Mode DA,@df.tour_mode_is_da * s2_ASC_tour_da,,1,,,,,,,,
util_S3_ASC_tour_DA,s3 ASC - Tour Mode DA,@df.tour_mode_is_da * s3_ASC_tour_da,,,1,,,,,,,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,13 @@ vot-indexed skims,da_dist_skims,((odt_skims['SOV_NT_L_DIST'] * (_vot_bin_da == 1
# Microtransit and NEV,,
microtransit available at origin,microtransit_orig,"reindex(land_use.microtransit, df[orig_col_name])"
microtransit available at destination,microtransit_dest,"reindex(land_use.microtransit, df[dest_col_name])"
microtransit available,microtransit_available,(microtransit_orig > 0) & (microtransit_orig == microtransit_dest) & (od_skims['DIST'] < microtransitMaxDist)
microtransit direct time,microtransit_direct_time,"np.maximum(od_skims['DIST']/microtransitSpeed*60, s2_time_skims)"
microtransit available,microtransit_available,(microtransit_orig > 0) & (microtransit_orig == microtransit_dest) & (s3_dist_skims < microtransitMaxDist)
microtransit direct time,microtransit_direct_time,"np.maximum(s3_dist_skims/microtransitSpeed*60, s3_time_skims)"
microtransit total time,microtransit_time,"np.maximum(microtransit_direct_time + microtransitDiversionConstant, microtransitDiversionFactor*microtransit_direct_time)"
nev available at origin,nev_orig,"reindex(land_use.nev, df[orig_col_name])"
nev available at destination,nev_dest,"reindex(land_use.nev, df[dest_col_name])"
nev available,nev_available,(nev_orig > 0) & (nev_orig == nev_dest) & (od_skims['DIST'] < nevMaxDist)
nev direct time,nev_direct_time,"np.maximum(od_skims['DIST']/nevSpeed*60, s2_time_skims)"
nev available,nev_available,(nev_orig > 0) & (nev_orig == nev_dest) & (s3_dist_skims < nevMaxDist)
nev direct time,nev_direct_time,"np.maximum(s3_dist_skims/nevSpeed*60, s3_time_skims)"
nev total time,nev_time,"np.maximum(nev_direct_time + nevDiversionConstant, nevDiversionFactor*nev_direct_time)"
# Microtransit and NEV egress from transit,,
outbound microtransit egress from premium available,microtransit_local_egress_available_out,df.outbound & (microtransit_dest>0) & (dest_micro_local_dist>maxWalkIfMTAccessAvailable) & (dest_micro_local_dist<microtransitMaxDist)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -453,12 +453,13 @@ Description,Target,Expression
,dest_micro_local_dist,"reindex(land_use.micro_dist_local_bus, destination)"
,dest_micro_prm_dist,"reindex(land_use.micro_dist_premium_transit, destination)"
,dest_micro_mix_dist,"np.minimum(dest_micro_local_dist, dest_micro_prm_dist)"
,s3_dist_skims,((odt_skims['HOV3_L_DIST'] * (_vot_bin_s3 == 1)) + (odt_skims['HOV3_M_DIST'] * (_vot_bin_s3 == 2)) + (odt_skims['HOV3_H_DIST'] * (_vot_bin_s3 == 3)))
microtransit available at origin,microtransit_orig,"reindex(land_use.microtransit, trips.origin)"
microtransit available at destination,microtransit_dest,"reindex(land_use.microtransit, trips.destination)"
microtransit available,microtransit_available,(microtransit_orig > 0) & (microtransit_orig == microtransit_dest) & (od_skims['DIST'] < microtransitMaxDist)
microtransit available,microtransit_available,(microtransit_orig > 0) & (microtransit_orig == microtransit_dest) & (s3_dist_skims < microtransitMaxDist)
nev available at origin,nev_orig,"reindex(land_use.nev, trips.origin)"
nev available at destination,nev_dest,"reindex(land_use.nev, trips.destination)"
nev available,nev_available,(nev_orig > 0) & (nev_orig == nev_dest) & (od_skims['DIST'] < nevMaxDist)
nev available,nev_available,(nev_orig > 0) & (nev_orig == nev_dest) & (s3_dist_skims < nevMaxDist)
outbound microtransit access available,microtransit_access_available_out,trips.outbound & (microtransit_orig>0) & (origin_micro_mix_dist<microtransitMaxDist)
outbound nev access available,nev_access_available_out,trips.outbound & (nev_orig>0) & (origin_micro_mix_dist<nevMaxDist)
outbound microtransit egress available,microtransit_egress_available_out,trips.outbound & (microtransit_dest>0) & (dest_micro_mix_dist>maxWalkIfMTAccessAvailable) & (dest_micro_mix_dist<microtransitMaxDist)
Expand Down

0 comments on commit 1b215f2

Please sign in to comment.