Skip to content

Commit

Permalink
Minor patch required for model run
Browse files Browse the repository at this point in the history
2050_TM151_PPA_BF_00 had some transit skim paths which were previously not found but are long paths and resulted in div by zero
  • Loading branch information
lmz committed Mar 28, 2019
1 parent dba4214 commit d806643
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
13 changes: 10 additions & 3 deletions model-files/scripts/nonres/HsrTransitSubmodeChoice.job
Original file line number Diff line number Diff line change
Expand Up @@ -228,9 +228,16 @@ loop tpnum=1,5
exp_wlk = exp(utility_wlk)
exp_drv = exp(utility_drv)

; compute the probability
prob_wlk = exp_wlk/(exp_wlk + exp_drv)
prob_drv = 1.0 - prob_wlk
; this can happen if the ivt is too high -- avoid div by zero errors
if ((exp_wlk + exp_drv)==0)
prob_wlk = 1.0
prob_drv = 0.0
else
; compute the probability
prob_wlk = exp_wlk/(exp_wlk + exp_drv)
prob_drv = 1.0 - prob_wlk
endif

else
prob_wlk = 0.0
prob_drv = 1.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ F_INPUT_SURVEY_DIR = "M:/Data/OnBoard/Data and Reports/_data Standardized"
F_INPUT_LEGACY_RDATA = file.path(F_INPUT_SURVEY_DIR, "survey_legacy.RData")
F_INPUT_STANDARD_RDATA = file.path(F_INPUT_SURVEY_DIR, "survey_standard.RData")

F_VALIDATION_DIR = "M:/Development/Travel Model One/Calibration/Version 1.5.0/2015_TM150_calib13/OUTPUT/validation"
F_VALIDATION_DIR = "M:/Development/Travel Model One/Calibration/Version 1.5.0/2015_TM151_PPA_00/OUTPUT/validation"
F_INPUT_RIDERSHIP = "M:/Data/Transit/2015 Ridership/transit ridership growth database.xlsx"
F_INPUT_ESTIMATED = "M:/Development/Travel Model One/Calibration/Version 1.5.0/2015_TM150_calib13/OUTPUT/validation/trnline.csv"
F_INPUT_ESTIMATED = "M:/Development/Travel Model One/Calibration/Version 1.5.0/2015_TM151_PPA_00/OUTPUT/validation/trnline.csv"

F_INPUT_MUNI_APC = "M:/Data/Transit/Muni APC Through Time/consolidated-database.csv"

Expand Down

0 comments on commit d806643

Please sign in to comment.