| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
There was a problem hiding this comment.
This pull request modernizes the project’s Python dependency stack (notably moving to NumPy v2) and adds two uv-runnable scripts to run the Prototype MTC model with Sharrow enabled, improving ease of execution and reproducibility via a lockfile.
Changes:
Copilot reviewed 4 out of 6 changed files in this pull request and generated 4 comments.
Show a summary per file| File | Description |
|---|---|
| uv.lock | Locks updated dependency set (NumPy v2 ecosystem, ActivitySim from git, Sharrow 2.15.0, etc.) for reproducible installs. |
| pyproject.toml | Updates declared requirements (NumPy v2, newer Pandera) and configures ActivitySim to come from the git main branch via tool.uv.sources. |
| scripts/run-small-sharrow.py | New uv script to run a small-sample Sharrow-enabled model run. |
| scripts/run-large-sharrow.py | New uv script to download/unpack full data and run a large-sample Sharrow-enabled model run. |
| .python-version | Sets default local Python version to 3.10 (within project’s >=3.10,<3.12 constraint). |
| .gitignore | Ensures data_full/ is ignored by git. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Sorry, something went wrong.
| Run the MTC example model with sharrow enabled, on the small test sample. | ||
|
|
||
| The metadata in the header above allows this script to be run with `uv` without | ||
| needing to set up a separate virtual environment or install dependencies manually. | ||
| """ |
| import platformdirs | ||
| import activitysim.abm # register components # noqa: F401 | ||
| from activitysim.core import workflow | ||
| from activitysim.examples.external import download_external_example, download_asset |
| # do not allow full data to enter Git repo | ||
| working_dir.joinpath(".gitignore").write_text("**\n") | ||
|
|
||
| out_dir = Path(str(__file__).replace(".py", "-output")) | ||
| out_dir.mkdir(exist_ok=True) |
| sha256 = "b402506a61055e2d38621416dd9a5c7e3cf7517c0a9ae5869f6d760c03284ef3", | ||
| link = Path(platformdirs.user_cache_dir(appname="ActivitySim")) / "External-Data", | ||
| base_path=str(working_dir), | ||
| unpack = "data_full", | ||
| ) |
| Back | FazBrowse Home | New Git URL |
This pull request introduces two new scripts for running the MTC example model with Sharrow enabled and updates several core dependencies to more current versions. The changes improve reproducibility, simplify environment setup, and modernize dependency requirements.
New scripts for Sharrow-enabled model runs:
Dependency updates in pyproject.toml: