RSGInc / SOABM

ODOT Southern Oregon ABM
https://github.com/RSGInc/SOABM/wiki
6 stars 5 forks source link

Clarification on Network Setting Capacity Factors #69

Closed bettinardi closed 5 years ago

bettinardi commented 6 years ago

Item 14 on page - https://github.com/RSGInc/SOABM/wiki/Networks-and-Zone-Data - describes that the user can edit the period capacity factors in network settings. The table at the bottom of the page implies the same: https://github.com/RSGInc/SOABM/wiki/Networks-and-Zone-Data#time-of-day-periods-and-link-capacities

However, the defined function on line 640 of - https://github.com/RSGInc/SOABM/blob/master/template/scripts/SOABM.py

@bstabler - can I please get a clarification on this. And if the code is overwritting the user setting, can we please have the code updated to no longer set these factors.

I believe the fix is trusting that the user has to establish these factors in Visum in the input file and so we would be removing or commenting out lines - 645-646. Changing 647 to get the capacity factors from Visum, and then getting rid of 652-656.

bstabler commented 6 years ago

You are correct. The fix is trusting that the user has to establish these factors in Visum in the input file and so we would be removing or commenting out lines - 645-646. Changing 647 to get the capacity factors from Visum, and then getting rid of 652-656. The user's guide describes the setup before the SANDAG VDFs.

I just added a link to the capacity lookup table under item 14 in the wiki. The new code that is needed is below.

  capFac = Visum.Net.GetAttValue("TOD_FACTOR_" + tp.upper())
binnympaul commented 5 years ago

This function does not exist - Visum.Net.GetAttValue Implementing this as: attName = "Network\TOD_FACTOR_" + tp.upper() capFac = VisumPy.helpers.GetMulti(Visum.Net.Links, attName)

VisumPy.helpers.SetMulti(Visum.Net.Links, "vdf_int_cap", numpy.multiply(numpy.array(vdf_int_cap), numpy.array(capFac)))

bettinardi commented 5 years ago

Why are you pulling a network attribute off the links? This value is stored in Network settings, not on the links

bstabler commented 5 years ago

@binnympaul's solution will work - it uses a link indirect attribute back up to the Network level to get the attribute.

binnympaul commented 5 years ago

This issue has been addressed under Contingency work