Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
189 commits
Select commit Hold shift + click to select a range
ab7b0c7
adding estimation configs
dhensle Jan 16, 2026
066a475
Merge branch 'initial_model_setup' into estimation
americalexander Jan 20, 2026
75202ac
Fix school location model spec
americalexander Jan 26, 2026
732eb96
adding missing occupation segment in wlc
dhensle Jan 26, 2026
89f1223
adding missing occup to shadow pricing
dhensle Jan 26, 2026
6f5f5bb
Merge remote-tracking branch 'origin/new_synthetic_pop' into estimation
americalexander Feb 4, 2026
becafb2
Remove hard-coded alt # from ext worker ident model
americalexander Feb 4, 2026
2229159
Fix jtf composition spec
americalexander Feb 10, 2026
b62c9be
Fix dupl. label in nm tour destination spec
americalexander Feb 16, 2026
74a57dd
updated nm size terms
americalexander Feb 16, 2026
37e5185
Merge branch 'initial_model_setup' into estimation
americalexander Feb 17, 2026
75492fd
ISO timestamp format
americalexander Feb 17, 2026
d23e483
more dest size terms updates
americalexander Feb 19, 2026
5f1e2a5
update trace label for Ext NMT Ident
americalexander Feb 19, 2026
2b2e4ce
Destination choice size terms made nonzero
americalexander Feb 19, 2026
be6c07e
Merge branch 'initial_model_setup' into estimation
dhensle Feb 20, 2026
867f5ba
preprocessor adds TAZ column to landuse
dhensle Feb 20, 2026
d97f584
fixing logging file
dhensle Feb 23, 2026
290af20
active acres size term
dhensle Feb 23, 2026
c5b94ec
Fix logging config
americalexander Feb 23, 2026
59682f3
Fix typo in previous commit
americalexander Feb 23, 2026
6a3ba21
clean up labels, knr skims for bnr, school trip size terms
dhensle Feb 24, 2026
04cfdd3
Merge branch 'estimation' of https://github.com/RSGInc/SimOR into est…
dhensle Feb 24, 2026
4aac9b3
One more logging fix
americalexander Feb 24, 2026
18c6803
allowing FT workers to go to univ
dhensle Feb 25, 2026
cb38524
shopping to HCS employment
americalexander Feb 25, 2026
04fb248
Actually lets just make it all employment
americalexander Feb 25, 2026
b7d73d0
estimation specific size terms
dhensle Feb 25, 2026
80172a3
Merge branch 'estimation' of https://github.com/RSGInc/SimOR into est…
dhensle Feb 25, 2026
327ebe5
adding missing alts for estimation
dhensle Feb 26, 2026
2597171
turn availability conditions off for trip mode choice
dhensle Mar 3, 2026
e5d13e1
Add one weird NMT frequency alt
americalexander Mar 10, 2026
0734d10
Update trip mode choice spec unavail conds for estimation
americalexander Mar 11, 2026
668da65
Merge remote-tracking branch 'origin/initial_model_setup' into estima…
americalexander Apr 28, 2026
2371298
Fix mismatched parens in annotate persons
americalexander Apr 28, 2026
978f781
Ensure consistent number of fields
americalexander Apr 28, 2026
a8b8eaf
define KNR_available
americalexander Apr 28, 2026
99e0234
Merge remote-tracking branch 'origin/maz_col_check' into estimation
americalexander Apr 29, 2026
f9115b4
Bugfix in pstudent annotation
americalexander May 1, 2026
cb43357
Trip mode choice bugfixes
americalexander May 1, 2026
841334e
remove hard-coded external alternative
americalexander May 6, 2026
63da533
Transit pass subsidy spec changes
americalexander May 7, 2026
547655c
Compatibility fixes for previous commit
americalexander May 7, 2026
2c57edc
Fix auto sufficiency condition
americalexander May 7, 2026
615f553
Fix transit pass subsidy availability cond
americalexander May 7, 2026
29354e4
Update escortee age limit
americalexander May 14, 2026
d581a66
Merge remote-tracking branch 'origin/main' into estimation
americalexander May 18, 2026
fd33457
Updated Readme
dhensle May 19, 2026
8b75664
Adding TRANSIT_FF
dhensle May 20, 2026
6a5ae68
missed quotes
dhensle May 20, 2026
6371c81
NMT scheduling fixes
americalexander May 20, 2026
01511ec
Trip mode choice spec changes
americalexander May 21, 2026
6bc3337
More trip mode choice spec changes
americalexander May 21, 2026
991fc99
Updated destination size terms
americalexander May 21, 2026
53a21b5
add lcog configs
ednaaguilar Jun 2, 2026
9ca2f3f
update git ignore
ednaaguilar Jun 2, 2026
af21000
Code and procedure modifications
lukegordon333 Jun 5, 2026
a40369f
Sequences saved
lukegordon333 Jun 5, 2026
dac4a7b
Merge remote-tracking branch 'origin/main' into lcog
ednaaguilar Jun 5, 2026
8f11032
Filters fixed, procedure sequences saved
lukegordon333 Jun 12, 2026
d2dc699
Moved graphic package files out of repo
lukegordon333 Jun 12, 2026
5a7c954
edited land-use preprocessor to remove references to fields that shou…
jfdman Jun 16, 2026
1b47839
bug fixes
jfdman Jun 16, 2026
8b0bff5
Rebuild cropped dataset
americalexander Jun 17, 2026
0d9814a
Rebuild SKATS cropped data
americalexander Jun 17, 2026
c5545f9
Remove stray commas from land use
americalexander Jun 17, 2026
1bbadc5
Add launch configs
americalexander Jun 17, 2026
795f03a
Rebuild cropped dataset
americalexander Jun 17, 2026
5f1a64d
Rebuild SKATS cropped data
americalexander Jun 17, 2026
499cd24
Remove stray commas from land use
americalexander Jun 17, 2026
29380c5
Add launch configs
americalexander Jun 17, 2026
01932e5
Merge remote-tracking branch 'origin/main' into estimation
americalexander Jun 17, 2026
5e355a9
Merge remote-tracking branch 'origin/main' into lcog
ednaaguilar Jun 17, 2026
c912def
update lcog launch
ednaaguilar Jun 17, 2026
73918fc
Merge branch 'lcog' of https://github.com/RSGInc/SimOR into lcog
ednaaguilar Jun 17, 2026
a8344a9
update exp parking costs col names
ednaaguilar Jun 17, 2026
0329ebb
Merge branch 'main' into lcog
ednaaguilar Jun 17, 2026
3f973c7
change exp parking col names, ensure int index
ednaaguilar Jun 18, 2026
46cffdf
add lcog ci and cropped data
ednaaguilar Jun 18, 2026
4cf7df3
change exp parking col names, ensure int index
ednaaguilar Jun 18, 2026
2ebbd39
rename external size term
americalexander Jun 18, 2026
459acb8
update Metro CI test
americalexander Jun 20, 2026
da40da3
Merge branch 'main' of https://github.com/RSGInc/SimOR
americalexander Jun 20, 2026
5aa9714
update SKATS CI test
americalexander Jun 20, 2026
514677e
Merge branch 'main' into estimation
americalexander Jun 20, 2026
2d26de6
Fixed SKATS land use
americalexander Jun 22, 2026
b62af8d
Update SKATS CI test again
americalexander Jun 22, 2026
e2e8818
Merge remote-tracking branch 'origin/main' into estimation
americalexander Jun 22, 2026
f4df952
Fix size term formatting breaking CI test
americalexander Jun 22, 2026
650b89f
Reset destination size terms for non-estimation
americalexander Jun 22, 2026
b098496
Pull preprocessor.py from main
americalexander Jun 22, 2026
fa4e846
Reset new coefficients to 0
americalexander Jun 22, 2026
b25391d
Revert preprocessor reversion
americalexander Jun 22, 2026
25ea633
Merge pull request #18 from RSGInc/TO2_memo_responses
americalexander Jun 22, 2026
c8c6556
Merge remote-tracking branch 'origin/main' into fix_modechoice
americalexander Jun 22, 2026
6ff9918
CSV file length fixes
americalexander Jun 22, 2026
29251bc
Remove pseudomsa attribute
americalexander Jun 22, 2026
a588e30
Fix dest size term for park attractiveness
americalexander Jun 22, 2026
07b6098
Bugfix in tour mode choice preprocessor
americalexander Jun 22, 2026
4a06069
One more tour mode choice preprocessor fix
americalexander Jun 22, 2026
b1a4caf
And another
americalexander Jun 22, 2026
2854c14
Merge remote-tracking branch 'origin/main' into lcog
americalexander Jun 22, 2026
83a0bca
Merge branch 'main' into fix_modechoice
americalexander Jun 22, 2026
8644092
Tour MC preprocessor fixes
americalexander Jun 22, 2026
27ed993
Merge branch 'fix_modechoice' of https://github.com/RSGInc/SimOR into…
americalexander Jun 22, 2026
9cfd939
Add bike logsums to cropped dataset
americalexander Jun 22, 2026
af2311f
Merge remote-tracking branch 'origin/main' into estimation
americalexander Jun 23, 2026
a50626f
Rogue nmtf alts
americalexander Jun 23, 2026
9a61eaf
fixed bugs
jfdman Jun 29, 2026
932a8ea
fix more bugs
jfdman Jun 29, 2026
299c86a
fix df error in walk transit
jfdman Jun 29, 2026
d557647
more df errors
jfdman Jun 29, 2026
26fe78b
even more df bug fixes
jfdman Jun 29, 2026
d8a2ac9
knr fixes
jfdman Jun 29, 2026
686b2f4
fix unbalanced paren
jfdman Jun 29, 2026
f7aef21
replace household_density with duden in VTC model. Note: model needs …
jfdman Jun 29, 2026
6b2b7e7
added density variables to land-use preprocessor
jfdman Jun 29, 2026
e170fdc
Fix True False
jfdman Jun 29, 2026
e57ca6f
first attempt at fixing trip mode choice, plus assorted fixes to tour…
jfdman Jun 30, 2026
1dc4c7c
fix divide by zero error?
jfdman Jun 30, 2026
8427abf
fixing minor config typos
dhensle Jun 30, 2026
68a0d98
fixing micromobility, del unused PNR trip mode utils
dhensle Jul 1, 2026
870d6de
Update Metro skims in cropped dataset
americalexander Jul 1, 2026
5b21d89
Add bike logsums to metro cropped example
americalexander Jul 1, 2026
b42d9ae
Add MAZ bike logsums for Metro
americalexander Jul 2, 2026
5687a79
Add bike logsums to crop script
americalexander Jul 2, 2026
e28a03f
Merge branch 'main' into fix_modechoice
dhensle Jul 2, 2026
8034ae2
Update telecommute frequency alternatives to differentiate 2 days per…
jfdman Jul 3, 2026
d43fd6a
fillna for ebike and escooter access times tmc
dhensle Jul 6, 2026
4e0e981
Updated vehicle type choice model to option 2 (op2)
jfdman Jul 6, 2026
f4edfdb
fixed spec
jfdman Jul 7, 2026
395513f
added back fuel_type dimensions to yaml
jfdman Jul 7, 2026
69ea893
fixing workplace shadow pricing bug
dhensle Jul 9, 2026
383ed15
filling na micromobility access times
dhensle Jul 9, 2026
fa90c41
vehicle type expr fixing
dhensle Jul 9, 2026
18e3b75
availability conditions for av
dhensle Jul 9, 2026
68827e5
Fixed some FIXME's
jfdman Jul 9, 2026
5c4ac9e
fixed error in parking location
jfdman Jul 10, 2026
4dd4069
revised work_segment based on survey
jfdman Jul 10, 2026
852d664
fix problems with work location choice segments in yamls
jfdman Jul 12, 2026
c86ab20
changed work segment from occupation to work_segment.
jfdman Jul 12, 2026
3c193b3
add script to create maz/taz connectors
ednaaguilar Jul 16, 2026
fb0e4a1
Update .gitignore
lukegordon333 Jul 20, 2026
942f595
Merge branch 'main' of https://github.com/RSGInc/SimOR
lukegordon333 Jul 20, 2026
cfc3fb9
add lcog/skats specific vars
ednaaguilar Jul 22, 2026
4d6612a
add bike code
ednaaguilar Jul 27, 2026
99b4434
config cleanup
dhensle Jul 28, 2026
452ccee
work segment to string
dhensle Jul 28, 2026
f1e43ab
update to maz taz connector creation
ednaaguilar Jul 29, 2026
69ee83d
add turn attribution script
ednaaguilar Jul 29, 2026
339435f
Add cropped SKATS bike logsum data
americalexander Aug 4, 2026
4136b15
Merge branch 'main' of https://github.com/RSGInc/SimOR
americalexander Aug 4, 2026
1731b48
Add LCOG bike logsums
americalexander Aug 4, 2026
a17c149
Update Metro bike logsums
americalexander Aug 4, 2026
5fc7bc4
Merge branch 'main' into fix_modechoice
dhensle Aug 4, 2026
9788a73
adding bike logsums to los and mc
dhensle Aug 4, 2026
35f9ad3
fixing bugs in trip mc bike logsum
dhensle Aug 5, 2026
f8f123a
Add externals to LCOG bike logsum skims
americalexander Aug 5, 2026
07e88b0
Merge branch 'fix_modechoice' into estimation
americalexander Aug 6, 2026
70aa4ff
Merge branch 'main' into estimation
americalexander Aug 6, 2026
22660bc
Update SKATS bike logsums
americalexander Aug 7, 2026
167ce49
Update SKATS bike logsums
americalexander Aug 7, 2026
0acc140
add ext stations to bike connectors
ednaaguilar Aug 8, 2026
dbc7ef7
Merge remote-tracking branch 'refs/remotes/origin/main'
ednaaguilar Aug 8, 2026
35b9a9e
Merge branch 'main' into fix_modechoice
dhensle Aug 12, 2026
30cb780
Add externals to LCOG bike logsum skims
americalexander Aug 5, 2026
5e77128
Update SKATS bike logsums
americalexander Aug 7, 2026
b5cca41
Merge branch 'fix_modechoice' of https://github.com/RSGInc/SimOR into…
americalexander Aug 12, 2026
7f92ae3
Rename misnamed files
americalexander Aug 12, 2026
b6df289
Fix SKATS MAZ logsums
americalexander Aug 13, 2026
0604929
filling na logsums
dhensle Aug 17, 2026
9e0e863
fixing nan expressions
dhensle Aug 17, 2026
abff2d2
Merge pull request #19 from RSGInc/fix_modechoice
dhensle Aug 17, 2026
08fd348
Merge branch 'main' into estimation
dhensle Aug 17, 2026
4f37679
including age 19 in highschool ptype if student
dhensle Aug 17, 2026
ac57cf5
Update estimation configs
americalexander Aug 22, 2026
fdaca7c
change external tour alt
americalexander Aug 26, 2026
14a3cac
Add visualizer setup to batch script
americalexander Sep 2, 2026
1cc45c0
Add metro cropped example to batch and CI scripts
americalexander Sep 2, 2026
595bd08
Add visualizer setup to CI
americalexander Sep 2, 2026
8acbb6c
Replace visualizer config
americalexander Sep 2, 2026
36188ae
Fix output dir
americalexander Sep 2, 2026
dfa8850
Fix path again
americalexander Sep 2, 2026
b9fe490
More path fixes
americalexander Sep 2, 2026
03765cf
Update metro cropped visualizer config
americalexander Sep 2, 2026
5c7c7af
various path bugfixes, add missing cropped file
americalexander Sep 2, 2026
b0e457e
More visualizer fixes
americalexander Sep 2, 2026
90f7834
minor readme edits
dhensle Sep 4, 2026
d2f4570
Merge pull request #17 from RSGInc/estimation
dhensle Sep 4, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 54 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,15 @@ jobs:
uv pip install -e . --no-deps
uv pip list

# Clone the ActivitySim visualizer and build its virtual environment
- name: Set up ActivitySim visualizer
run: |
mkdir -p $GITHUB_WORKSPACE/ext_dependencies
cd $GITHUB_WORKSPACE/ext_dependencies
git clone --branch main https://github.com/RSGInc/activitysim_visualizer.git
cd activitysim_visualizer
uv sync

# Run the test
- name: Run Metro cropped example test
run: |
Expand Down Expand Up @@ -97,3 +106,48 @@ jobs:
run: |
cd ../activitysim
uv run python $GITHUB_WORKSPACE/resident/test/test_cropped_dataset_skats.py

lcog_cropped_example:
strategy:
matrix:
python-version:
- "3.10"
fail-fast: false

name: lcog-cropped-example-py${{ matrix.python-version }}
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

# Clone ActivitySim from SimOR_pnr branch
- name: Clone ActivitySim
run: |
cd ..
git clone --branch SimOR_pnr https://github.com/RSGInc/activitysim.git
pwd
ls -la

# Install UV
- name: Install UV
uses: astral-sh/setup-uv@v4
with:
version: "latest"

# Set up Python with UV
- name: Set up Python
run: uv python install ${{ matrix.python-version }}

# Install dependencies using UV and the lock file from ActivitySim
- name: Install dependencies with UV
run: |
cd ../activitysim
uv sync --frozen
uv pip install -e . --no-deps
uv pip list

# Run the test
- name: Run LCOG cropped example test
run: |
cd ../activitysim
uv run python $GITHUB_WORKSPACE/resident/test/test_cropped_dataset_lcog.py
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
.vscode/*
resident/model_data/metro/data_full/*
resident/model_data/skats/data_full/*
resident/model_data/lcog/data_full/*
resident/outputs/*

# Unit test / coverage reports
Expand Down
131 changes: 129 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,92 @@
]
},
{
"name": "Run Cropped Example",
"name": "Metro Estimation Mode",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_estimation", // check the settings.yaml file for run settings!
"-c", "configs",
"-d", "model_data/metro/data_full",
"-o", "outputs/estimation_metro",
]
},
{
"name": "SKATS Estimation Mode",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_skats",
"-c", "configs_estimation", // check the settings.yaml file for run settings!
"-c", "configs",
"-d", "model_data/skats/data_full",
"-o", "outputs/estimation_skats",
]
},
{
"name": "LCOG Estimation Mode",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_estimation", // check the settings.yaml file for run settings!
"-c", "configs",
"-d", "model_data/lcog/data_full",
"-o", "outputs/estimation_lcog",
]
},
{
"name": "CALM Estimation Mode",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_estimation", // check the settings.yaml file for run settings!
"-c", "configs",
"-d", "model_data/calm/data_full",
"-o", "outputs/estimation_calm",
]
},
{
"name": "Bend Estimation Mode",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_estimation", // check the settings.yaml file for run settings!
"-c", "configs",
"-d", "model_data/bend/data_full",
"-o", "outputs/estimation_bend",
]
},
{
"name": "Rogue Estimation Mode",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_estimation", // check the settings.yaml file for run settings!
"-c", "configs",
"-d", "model_data/rogue/data_full",
"-o", "outputs/estimation_rogue",
]
},
{
"name": "Run Cropped Metro Example",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
Expand All @@ -27,7 +112,21 @@
"args": [
"-c", "configs", // check the settings.yaml file for run settings!
"-d", "model_data/metro/data_cropped",
"-o", "outputs/cropped",
"-o", "outputs/metro_cropped",
]
},
{
"name": "Run Cropped SKATS Example",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_skats",
"-c", "configs", // check the settings.yaml file for run settings!
"-d", "model_data/skats/data_cropped",
"-o", "outputs/skats_cropped",
]
},
{
Expand Down Expand Up @@ -94,5 +193,33 @@
"-o", "outputs/skats_cropped",
]
},
{
"name": "Run LCOG",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_lcog",
"-c", "configs", // check the settings.yaml file for run settings!
"-d", "model_data/lcog/data_full",
"-o", "outputs/lcog",
]
},
{
"name": "Run LCOG Cropped",
"type": "debugpy",
"request": "launch",
"cwd": "${workspaceFolder}/resident",
"program": "simulation.py",
"console": "integratedTerminal",
"args": [
"-c", "configs_lcog",
"-c", "configs", // check the settings.yaml file for run settings!
"-d", "model_data/lcog/data_cropped",
"-o", "outputs/lcog_cropped",
]
},
]
}
89 changes: 81 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,39 @@
Simulate Oregon (SimOR) - Oregon's Jointly Estimated ActivitySim Model
![image](SimOR.png)

> [!WARNING]
> This model is under active development, and the following instructions are subject to change.

Please see this repo's Wiki page for more detailed information on this model.

## Repository structure

The repository is organized into the following major components:

| Path | Purpose |
|------|---------|
| `runSIMOR.bat` | Top-level batch script that runs environment setup, skimming, preprocessing, and the current ActivitySim example run |
| `setup_environment.bat` | Installs UV if needed, clones and updates external dependencies, creates Python environments, and installs required Visum Python packages |
| `ext_dependencies/` | Cloned external repositories and their virtual environments, including ActivitySim, maz_skimming, and optionally sandag_parking |
| `resident/` | ActivitySim model code, configurations, test cases, model input data, and outputs |
| `resident/configs/` | Shared ActivitySim settings used across regions |
| `resident/configs_*` | Region-specific ActivitySim settings, constants, and overrides such as `configs_skats`; additional region folders such as `configs_metro` or `configs_lcog` may be added over time |
| `resident/model_data/` | Region-specific model inputs, including cropped example datasets and full datasets |
| `skimming_and_assignment/visum/` | Visum runner scripts, procedure sequences, and version files used to build motorized skims and export network inputs |
| `skimming_and_assignment/maz_maz_stop_skims/` | Non-motorized skim preprocessor and skim settings |
| `misc/` | Miscellaneous analysis and support scripts |

## Running the model

### Prerequisites

Before running the model, make sure the following are available:

1. PTV Visum 2026 with its bundled Python installation
2. Git available on your system PATH or installed in a standard Windows location
3. PowerShell with permission to run the UV installer invoked by `setup_environment.bat`
4. Local write access to the Visum Python `site-packages` directory, or Administrator privileges if package installation there is restricted

### Setup

1. **Configure `setup_environment.bat`**
Expand All @@ -12,27 +43,38 @@ Simulate Oregon (SimOR) - Oregon's Jointly Estimated ActivitySim Model

| Variable | Description | Default |
|----------|-------------|---------|
| `VISUM_PYTHON_DIR` | Folder containing your Visum 2026 Python interpreter | `C:\Program Files\PTV Vision\PTV Visum 2026\Exe\Junction_Preview\Python` |
| `INSTALL_PARKING` | Clone and install sandag_parking (`Y` or `N`) | `Y` |
| `VISUM_PYTHON_DIR` | Folder containing your Visum 2026 Python interpreter | `C:\Program Files\PTV Vision\PTV Visum 2026\Exe\Python` |
| `INSTALL_PARKING` | Clone and install sandag_parking (`Y` or `N`) | `N` |

You can run this script on its own to install all dependencies without running the model:
```
setup_environment.bat
```
It will install UV (if needed), clone and build the required repositories into `ext_dependencies/`, create the MAZ skimming Python environment from `ext_dependencies/maz_skimming/pyproject.toml`, and install the necessary Python packages into Visum's Python environment. On subsequent runs it detects existing installs and pulls the latest changes instead of re-cloning.
It will install UV (if needed), verify Git is available, clone and build the required repositories into `ext_dependencies/`, create the ActivitySim and MAZ skimming Python environments, and install the necessary Python packages into Visum's Python environment. On subsequent runs it detects existing installs and pulls the latest changes instead of re-cloning.

`sandag_parking` is not required for a typical model run. It is only needed when preparing land use inputs that require expected parking costs. In that workflow, it can be run once to generate the parking cost input file used by the preprocessor.

**If permissions errors arise, try running the setup with Administrator privileges. The Visum Python package install in particular may require elevated permissions.**

2. **Place the Visum version file**

Copy your Visum network version file (`.ver`) into `skimming_and_assignment/visum/`.

3. **Update configuration files**

Edit the following files to match your local data paths and project settings:
Edit the following files to match your local data paths, region, and project settings:

| File | Purpose |
|------|---------|
| `skimming_and_assignment/maz_maz_stop_skims/2zoneSkim_params.yaml` | Non-motorized skim settings and file paths |
| `resident/preprocessor_settings.yaml` | Land use preprocessor input/output paths and network settings |
| `skimming_and_assignment/maz_maz_stop_skims/2zoneSkim_params.yaml` | Non-motorized skim settings, Visum export locations, network inputs, and skim outputs |
| `resident/preprocessor_settings.yaml` | Land use preprocessor input/output paths, network shapefiles, skim inputs, and optional parking or fare inputs |

At minimum, confirm that these files point to the correct local locations for:

1. Household, person, and land use CSV inputs
2. MAZ, node, and link shapefiles
3. Non-motorized skim inputs and outputs
4. Optional expected parking cost and transit fare inputs

4. **Set user-defined variables in `runSIMOR.bat`**

Expand All @@ -42,6 +84,22 @@ Simulate Oregon (SimOR) - Oregon's Jointly Estimated ActivitySim Model
|----------|-------------|
| `VISUM_VERSION_FILE` | Filename of the Visum version file |
| `PROCEDURE_SEQ` | Path to the Visum procedure sequence XML |
| `VISUM_PED_VERSION_FILE` | Optional pedestrian network Visum version file used when a separate pedestrian export is needed |
| `PED_PROCEDURE_SEQ` | Optional Visum procedure sequence for the pedestrian network export |

### ActivitySim configuration layout

ActivitySim settings are split into a shared configuration folder and optional region-specific configuration folders.

- `resident/configs/` contains shared settings used across model regions.
- Region-specific folders such as `resident/configs_skats/`, and future folders such as `resident/configs_metro/` or `resident/configs_lcog/`, contain region-specific constants and overrides.
- When running a region-specific model, pass the region-specific config directory first and then the shared config directory so region overrides are applied before shared settings.

For example:

```bat
python resident\simulation.py -c resident\configs_skats -c resident\configs -d resident\model_data\skats\data_cropped -o resident\outputs\test
```

### Running the Pipeline

Expand All @@ -52,8 +110,23 @@ runSIMOR.bat

The script automatically calls `setup_environment.bat` to ensure all dependencies are installed and Python paths are set, then runs the following steps in sequence:

1. **Motorized skims** — Using Visum `Visum_Runner.py`. Automatically outputs required files to run non-motorized skims.
1. **Motorized skims** — Using Visum `Visum_Runner.py`. Automatically outputs required files to run non-motorized skims.
2. **Non-motorized skim preprocessor** — Prepares walk network inputs via `2zoneSkim_preprocessor.py`.
3. **Non-motorized skims** — Computes MAZ-to-MAZ and MAZ-to-stop walk skims via `2zoneSkim.py`.
4. **Land use preprocessor** — Builds ActivitySim-ready land use table via `preprocessor.py`.
5. **Run ActivitySim** -- Runs ActivitySim -- (not yet implemented)
5. **Run ActivitySim** — Runs the current ActivitySim example configured in `runSIMOR.bat`.

At present, the ActivitySim command in `runSIMOR.bat` runs the Metro cropped example dataset:

```bat
python resident\simulation.py -c resident\configs -d resident\model_data\metro\data_cropped -o outputs\cropped
```

This is a smoke-test style example run, not yet a generalized full-region launcher for all supported scenarios.

### Expected inputs and outputs

- Visum produces the motorized skims and exported network files consumed by the non-motorized skim workflow.
- The non-motorized skim tools produce files such as `maz_maz_walk.csv` and `maz_stop_walk.csv` for use by the land use preprocessor and ActivitySim.
- The land use preprocessor reads the configured raw model inputs and writes updated ActivitySim-ready tables to the configured output directory.
- ActivitySim writes model outputs to the output folder passed on the command line.
Loading
Loading