Repository navigation
2026-03-19 Engineering Team #81
Description
Activity
Following up on something from last week, the test I wrote for the PopulationSim PR is failing and I have no idea why. It appears to be reading the controls configuration file from the correct directory but not the settings file. I'd be fine bringing it up at the meeting or discussing it asynchronously on the pull request.
ActivitySim Development Meeting Notes
Meeting Overview
Agenda
- EET merge status and resolution
- Skip-on-fail households pull request review
- Sharrow memory usage investigation
- Dependabot dependency update policy
- UV acquisition by OpenAI
- Park and ride unit testing (David Hensle)
- Open pull requests and miscellaneous issues
Participants
- Jeff Newman (@jpn--), Driftless
- Joe Castiglione (@joecastiglione), Zephyr Foundation
- David Hensle (@dhensle), RSG
- Bo Wen (@bwentl), TransLink
- Sijia Wang (@i-am-sijia), WSP
- Jan Zill (@janzill), Outer Loop
- Stefan Coe (@stefancoe), PSRC
- Andrew Kay (@andkay), CS
Duration
Approximately 57 minutes
Executive Summary
Jeff Newman resolved a dependency conflict that had blocked the EET branch merge, and the branch is now ready for ongoing work. The Sharrow memory usage investigation showed that the apparent memory leak is isolated to runs where the compiler is active in multi-process mode — not the recommended usage pattern — and overall memory behavior is consistent across model runs. The team agreed to disable Dependabot and instead do periodic, managed dependency updates, given that ActivitySim is not run in public-facing environments. David Hensle presented a new set of self-contained unit tests for the park and ride lot choice model, which the team viewed positively as a template for future component-level testing.
Meeting Notes
EET Branch Merge
Jeff resolved a dependency conflict that had blocked the EET branch from merging. The issue was that the EET branch was installing a version of Larch that pinned Sharrow to the wrong version, causing a downgrade and test failures. Jeff updated Larch to work with the most recent version of Sharrow and pinned it accordingly. All tests passed and the branch has been merged. The EET branch is now available for Outer Loop and others to continue EET-related development.
Skip-on-Fail Households Pull Request
Jeff reviewed the skip-on-fail households pull request and indicated that all prior review comments have been addressed. David agreed to review it by the afternoon. The team agreed not to hold up the merge pending a decision on default parameter values (e.g., the default threshold for the number of failing households before the model is considered a failure) — that can be addressed in a subsequent, small pull request.
Sharrow Memory Usage
Bo Wen shared results from additional memory usage tests. Jeff's analysis of the results indicated that the apparent memory leak pattern — where memory usage rises continuously throughout a run — only occurs when Sharrow's compiler is active during the run, meaning there is no pre-existing cache. This is not the recommended usage pattern; the recommendation is to run Sharrow compilation in single-process mode with a small sample to generate the compiled cache, then use that cache in subsequent multi-process production runs.
Key findings:
- Runs without a pre-existing cache show the "uphill" memory profile due to the numba compiler holding memory.
- Runs with a pre-existing cache show memory being allocated and released in a consistent, expected pattern across components (e.g., trip destination choice spikes and then releases memory).
- Running the compiler in multi-process mode causes processes to compete to compile individual components simultaneously, which worsens both runtime and memory usage.
- Memory release timing ("sporadic memory release") is somewhat inconsistent across platforms, making it difficult to predict peak memory needs. However, the pattern is consistent across repeated model runs.
Bo raised a usability concern: even when single-process compilation is run with a small sample, edge cases (e.g., rare categorical combinations) can still trigger recompilation during multi-process production runs. The Sharrow cache folder in their repository grows over time as new compiled artifacts are committed. Jeff offered to investigate if Bo and David can share input data so he can reproduce the edge case recompilations.
Joe Castiglione noted that the patterns appear generally consistent even if the axes differ across runs (due to different skim sets being used).
David also flagged an older open issue (issue #850) referencing a user team (MW's group) that was experiencing crashes. Jeff noted this may or may not be the same root cause, and will follow up with that team directly.
Dependabot and Dependency Management
Dependabot has been opening a large number of pull requests (six in the past two days). Jeff proposed disabling Dependabot and instead doing periodic, managed dependency updates by unlocking the UV lockfile, running updates, and addressing issues in batch. The rationale is that ActivitySim is not run in public-facing environments, so the security risk from outdated dependencies is low. Andrew Kay noted that Dependabot is most useful when flagging actual security vulnerabilities, but that many of its pull requests are simply version-bump notifications. The team agreed. Jeff will configure the repository to disable Dependabot's automatic pull requests.
UV Acquisition by OpenAI
Jeff flagged that Astral, the company that makes the UV Python package manager, has been acquired by OpenAI. He expressed some concern that development pace on UV may slow, though he noted UV is widely used enough that it is unlikely to disappear. Andrew suggested that OpenAI's stated intention is continued development of the toolchain, and speculated they may be looking to integrate it more directly into Codex and the Python ecosystem. The team agreed no immediate action is needed.
Park and Ride Unit Tests
David Hensle shared a new set of unit tests for the park and ride lot choice model, added under tests/abm/test_misc/. The tests are self-contained, each setting up their own state object, skim matrices, land use, choosers, and spec files rather than relying on shared fixtures.
Tests cover:
- Drive transit and capacity utility calculations using skim wrappers
- Lot selection across a small set of alternatives
- Capacity counting with non-unit sample rates
- Filtering choosers to those with transit-accessible destinations (both from land use and from skims)
- Multinomial mode with shared data buffers across threads (simulating multiprocessing)
- Barrier synchronization testing for the case where some threads have no choosers at capacitated zones
David also added a tour mode choice unit test with a nested logit structure (drive alone, HOV2, walk/transit nest) that includes park and ride, and verifies that enabling the capacity iteration causes one transit mode to be eliminated.
Jeff noted he would review the pull request, and encouraged others to review as well, since this could serve as a template for future component-level testing. Jan Zill agreed that having concrete examples is valuable, and that the self-contained approach (explicit dependencies per test) makes the code easier to understand. David noted AI coding tools (Claude Sonnet 4.6, Codex) were helpful in accelerating the test writing once an initial example existed, though the first iteration required significant back-and-forth to get the tests to actually call the right functions.
Three-Zone Model Removal
David has an open draft pull request to remove all three-zone model code and examples from the repository. The removal touches approximately 300+ files, most of which are three-zone example model files. He noted an additional fix is needed: the SANDAG two-zone example has a residual three-zone setting in its network files that causes a crash, which will be addressed in a separate small pull request targeting the SANDAG example model.
Miscellaneous
- PSRC Sharrow issue: Stefan Coe noted there is a still-open issue regarding Sharrow that has prevented PSRC from using it for some time. Jeff agreed to prioritize it this week.
- Sample rate rounding fix: Sijia Wang noted that a pull request to remove sample rate rounding and update regression test data has not yet been opened. She will open it once the skip-on-fail pull request is merged.
- PopulationSim testing: Jeff noted he will connect with Joe Flood (@JoeJimFlood) separately to work through PopulationSim testing issues.
- Open pull requests: Jeff noted several open pull requests remain and he is working through them.
Action Items
- Jeff Newman: Merge the skip-on-fail households pull request after David's review, assuming no outstanding issues.
- David Hensle: Review the skip-on-fail households pull request this afternoon.
- Jeff Newman: Disable Dependabot automatic pull requests on the ActivitySim repository.
- Jeff Newman: Follow up with the MW team (MWCOG) regarding their crash reports (issue #850) to determine if they are related to running in compilation mode.
- Jeff Newman: Investigate the Sharrow edge case recompilation issue, pending access to TransLink input data.
- David Hensle: Share TransLink input data with Jeff (through David, given contract constraints) to support Sharrow edge case investigation.
- Jeff Newman: Review David's park and ride and tour mode choice unit test pull request.
- David Hensle: Open a small pull request to remove the residual three-zone setting from the SANDAG two-zone example network file.
- Jeff Newman: Prioritize the open PSRC Sharrow issue this week.
- Sijia Wang: Open a pull request to remove sample rate rounding and update regression test data, after the skip-on-fail pull request is merged.
- Jeff Newman: Connect with Joe Flood (@JoeJimFlood) separately regarding PopulationSim testing.
Agenda
@ActivitySim/engineering