activitysim icon indicating copy to clipboard operation
activitysim copied to clipboard

Make sharrow work for school escorting

Open jpn-- opened this issue 1 year ago • 1 comments
trafficstars

  • [x] don't crash on Sharrow-test
  • [ ] pass sharrow-test
  • [ ] remove string comparisons

jpn-- avatar Feb 29 '24 16:02 jpn--

Just wanted to make sure you knew that the string removal work was performed already here: https://github.com/ActivitySim/activitysim-prototype-mtc/pull/4

dhensle avatar Feb 29 '24 17:02 dhensle

@dhensle you make a good point. Also, while I'm pushing fastmath through all the components, I realized its convenient to wrap all component level sharrow controls together (i.e., also skip) to ensure a consistent user interface.

jpn-- avatar Apr 01 '24 03:04 jpn--

@dhensle this PR is ready for your re-review. I believe I addressed your concerns, and then some.

jpn-- avatar Apr 15 '24 16:04 jpn--

In thinking about the solution for #842, I realized we probably want these controls to be more general that "sharrow_settings", something more like "compute_settings". The reason we are seeing the overflow in #842 seems to be because we are using bottleneck for the computations, but if we activate compute.use_numexpr instead the problem goes away. If we make these controls more general, we can trigger this pandas setting here as well. This allows us to change compute settings in a consistent component-specific manner for non-sharrow compute. For now, that includes settings the pandas options compute.use_bottleneck, compute.use_numexpr, and compute.use_numba (see pandas.set_option).

jpn-- avatar Apr 17 '24 21:04 jpn--

@dhensle Will you have time to finish a (re)review of this PR this morning so we can merge it? It is now blocking progress on #833 as we want to coordinate the settings.

jpn-- avatar Apr 18 '24 14:04 jpn--