Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
32 changes: 16 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,24 +19,24 @@ jobs:
- env: TEST_SUITE=activitysim/core

- stage: Examples
name: "MTC Example"
env: TEST_SUITE=activitysim/examples/example_mtc/test
- name: "MTC Extended Example"
env: TEST_SUITE=activitysim/examples/example_mtc_extended/test
name: "Prototype MTC"
env: TEST_SUITE=activitysim/examples/prototype_mtc/test
- name: "Prototype MTC (Extended)"
env: TEST_SUITE=activitysim/examples/prototype_mtc_extended/test
- name: "Multizone Example"
env: TEST_SUITE=activitysim/examples/example_multiple_zone/test
env: TEST_SUITE=activitysim/examples/placeholder_multiple_zone/test
- name: "Marin Example"
env: TEST_SUITE=activitysim/examples/example_marin/test
env: TEST_SUITE=activitysim/examples/prototype_marin/test
- name: "ARC Example"
env: TEST_SUITE=activitysim/examples/example_arc/test
env: TEST_SUITE=activitysim/examples/prototype_arc/test
- name: "SEMCOG Example"
env: TEST_SUITE=activitysim/examples/example_semcog/test
env: TEST_SUITE=activitysim/examples/prototype_semcog/test
- name: "PSRC Example"
env: TEST_SUITE=activitysim/examples/example_psrc/test
env: TEST_SUITE=activitysim/examples/placeholder_psrc/test
- name: "SANDAG Example"
env: TEST_SUITE=activitysim/examples/example_sandag/test
env: TEST_SUITE=activitysim/examples/placeholder_sandag/test
- name: "SANDAG Cross-Border Example"
env: TEST_SUITE=activitysim/examples/example_sandag_xborder/test
env: TEST_SUITE=activitysim/examples/prototype_sandag_xborder/test

- stage: Estimation Mode
name: "Larch Test"
Expand Down Expand Up @@ -94,12 +94,12 @@ install:
script:
# This is the "default" script used for each test suite, unless overridden with a "script" in the jobs above.
# build 2 and 3 zone test data twice since the Python test code on Linux sees these as different locations
- python activitysim/examples/example_multiple_zone/scripts/two_zone_example_data.py
- python activitysim/examples/example_multiple_zone/scripts/three_zone_example_data.py
- python /home/travis/miniconda/envs/asimtest/lib/python$TRAVIS_PYTHON_VERSION/site-packages/activitysim/examples/example_multiple_zone/scripts/two_zone_example_data.py
- python /home/travis/miniconda/envs/asimtest/lib/python$TRAVIS_PYTHON_VERSION/site-packages/activitysim/examples/example_multiple_zone/scripts/three_zone_example_data.py
- python activitysim/examples/placeholder_multiple_zone/scripts/two_zone_example_data.py
- python activitysim/examples/placeholder_multiple_zone/scripts/three_zone_example_data.py
- python /home/travis/miniconda/envs/asimtest/lib/python$TRAVIS_PYTHON_VERSION/site-packages/activitysim/examples/placeholder_multiple_zone/scripts/two_zone_example_data.py
- python /home/travis/miniconda/envs/asimtest/lib/python$TRAVIS_PYTHON_VERSION/site-packages/activitysim/examples/placeholder_multiple_zone/scripts/three_zone_example_data.py
# pycodestyle
- pycodestyle activitysim
# run specific TEST_SUITE job on travis to avoid job max time
- travis_wait 50 py.test $TEST_SUITE --cov activitysim --cov-report term-missing --durations=0
- coveralls
# coveralls # disable coveralls service, which errors frequently
6 changes: 3 additions & 3 deletions HOW_TO_RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@
regular test suite takes some time to run, between about half an hour and
two hours depending on the specs of your machine.
```sh
python activitysim/examples/example_multiple_zone/scripts/two_zone_example_data.py
python activitysim/examples/example_multiple_zone/scripts/three_zone_example_data.py
python activitysim/examples/placeholder_multiple_zone/scripts/two_zone_example_data.py
python activitysim/examples/placeholder_multiple_zone/scripts/three_zone_example_data.py
pytest .
```

Expand All @@ -83,7 +83,7 @@
python ../activitysim/examples/scan_examples_for_errors.py .
```

00. Test the notebooks in `activitysim/examples/example_mtc/notebooks`.
00. Test the notebooks in `activitysim/examples/prototype_mtc/notebooks`.
There are also demo notebooks for estimation, but their functionality
is completely tested in the unit tests run previously.

Expand Down
2 changes: 1 addition & 1 deletion activitysim/abm/models/util/vectorize_tour_scheduling.py
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@ def _schedule_tours(
if not RUN_ALTS_PREPROCESSOR_BEFORE_MERGE:
# Note: Clint was running alts_preprocessor here on tdd_interaction_dataset instead of on raw (unmerged) alts
# and he was using logsum_tour_purpose as selector, although logically it should be the spec_segment
# It just happened to work for example_arc.mandatory_tour_scheduling because, in that model, (unlike semcog)
# It just happened to work for prototype_arc.mandatory_tour_scheduling because, in that model, (unlike semcog)
# logsum_tour_purpose and spec_segments are aligned (both logsums and spec are segmented on work, school, univ)
# In any case, I don't see any benefit to doing this here - at least not for any existing implementations
# but if we do, it will require passing spec_segment to schedule_tours and _schedule_tours
Expand Down
2 changes: 1 addition & 1 deletion activitysim/abm/test/test_misc/setup_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@


def example_path(dirname):
resource = os.path.join('examples', 'example_mtc', dirname)
resource = os.path.join('examples', 'prototype_mtc', dirname)
return pkg_resources.resource_filename('activitysim', resource)


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@


def example_path(dirname):
resource = os.path.join('examples', 'example_mtc', dirname)
resource = os.path.join('examples', 'prototype_mtc', dirname)
return pkg_resources.resource_filename('activitysim', resource)


Expand Down
2 changes: 1 addition & 1 deletion activitysim/abm/test/test_pipeline/test_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@


def example_path(dirname):
resource = os.path.join('examples', 'example_mtc', dirname)
resource = os.path.join('examples', 'prototype_mtc', dirname)
return pkg_resources.resource_filename('activitysim', resource)


Expand Down
2 changes: 1 addition & 1 deletion activitysim/benchmarking/benchmarks/mtc1full.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
template_setup_cache,
)

EXAMPLE_NAME = "example_mtc_full"
EXAMPLE_NAME = "prototype_mtc_full"
CONFIGS_DIRS = ("configs",)
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data"
Expand Down
2 changes: 1 addition & 1 deletion activitysim/benchmarking/benchmarks/mtc1mp4.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import numpy as np

PRETTY_NAME = "MTC1_MP4"
EXAMPLE_NAME = "example_mtc_full"
EXAMPLE_NAME = "prototype_mtc_full"
NUM_PROCESSORS = int(np.clip(multiprocessing.cpu_count() - 2, 2, 4))
CONFIGS_DIRS = ("configs_mp", "configs")
DYNAMIC_CONFIG_DIR = "bench_configs_mp"
Expand Down
4 changes: 2 additions & 2 deletions activitysim/benchmarking/benchmarks/sandag1example.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from .sandag_example import *

EXAMPLE_NAME = "example_sandag_1_zone"
CONFIGS_DIRS = ("configs_1_zone", "example_mtc/configs")
EXAMPLE_NAME = "placeholder_sandag_1_zone"
CONFIGS_DIRS = ("configs_1_zone", "prototype_mtc/configs")
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data_1"
OUTPUT_DIR = "output_1"
Expand Down
4 changes: 2 additions & 2 deletions activitysim/benchmarking/benchmarks/sandag1full.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from .sandag_full import *

EXAMPLE_NAME = "example_sandag_1_zone_full"
CONFIGS_DIRS = ("configs_benchmarking", "configs_1_zone", "example_mtc/configs")
EXAMPLE_NAME = "placeholder_sandag_1_zone_full"
CONFIGS_DIRS = ("configs_benchmarking", "configs_1_zone", "prototype_mtc/configs")
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data_1"
OUTPUT_DIR = "output_1"
Expand Down
4 changes: 2 additions & 2 deletions activitysim/benchmarking/benchmarks/sandag2example.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from .sandag_example import *

EXAMPLE_NAME = "example_sandag_2_zone"
CONFIGS_DIRS = ("configs_2_zone", "example_psrc/configs")
EXAMPLE_NAME = "placeholder_sandag_2_zone"
CONFIGS_DIRS = ("configs_2_zone", "placeholder_psrc/configs")
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data_2"
OUTPUT_DIR = "output_2"
Expand Down
4 changes: 2 additions & 2 deletions activitysim/benchmarking/benchmarks/sandag2full.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from .sandag_full import *

EXAMPLE_NAME = "example_sandag_2_zone_full"
CONFIGS_DIRS = ("configs_benchmarking", "configs_2_zone", "example_psrc/configs")
EXAMPLE_NAME = "placeholder_sandag_2_zone_full"
CONFIGS_DIRS = ("configs_benchmarking", "configs_2_zone", "placeholder_psrc/configs")
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data_2"
OUTPUT_DIR = "output_2"
Expand Down
4 changes: 2 additions & 2 deletions activitysim/benchmarking/benchmarks/sandag3example.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from .sandag_example import *

EXAMPLE_NAME = "example_sandag_3_zone"
CONFIGS_DIRS = ("configs_3_zone", "example_mtc/configs")
EXAMPLE_NAME = "placeholder_sandag_3_zone"
CONFIGS_DIRS = ("configs_3_zone", "prototype_mtc/configs")
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data_3"
OUTPUT_DIR = "output_3"
Expand Down
4 changes: 2 additions & 2 deletions activitysim/benchmarking/benchmarks/sandag3full.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from .sandag_full import *

EXAMPLE_NAME = "example_sandag_3_zone_full"
CONFIGS_DIRS = ("configs_benchmarking", "configs_3_zone", "example_mtc/configs")
EXAMPLE_NAME = "placeholder_sandag_3_zone_full"
CONFIGS_DIRS = ("configs_benchmarking", "configs_3_zone", "prototype_mtc/configs")
DYNAMIC_CONFIG_DIR = "bench_configs"
DATA_DIR = "data_3"
OUTPUT_DIR = "output_3"
Expand Down
5 changes: 2 additions & 3 deletions activitysim/cli/test/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,14 @@ def test_create_list():
cp = subprocess.run(['activitysim', 'create', '--list'], capture_output=True)

assert 'Available examples' in str(cp.stdout)
assert "name: example_mtc" in str(cp.stdout)
assert "name: example_test" in str(cp.stdout)
assert "name: prototype_mtc" in str(cp.stdout)


def test_create_copy():

target = os.path.join(os.path.dirname(__file__), 'test_example')
cp = subprocess.run(['activitysim', 'create',
'--example', 'example_test',
'--example', 'prototype_mtc',
'--destination', target], capture_output=True)

assert 'copying data ...' in str(cp.stdout)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,19 @@ MTC_SF_DATA_DIR=/Users/jeff.doyle/work/activitysim-data/mtc_tm1_sf/data
MTC_FULL_DATA_DIR=/Users/jeff.doyle/work/activitysim-data/mtc_tm1/data

EXAMPLES_DIR=$ACTIVITYSIM_BASE_DIR/activitysim/examples
MTC_EXAMPLE_DIR=$EXAMPLES_DIR/example_mtc
MTC_EXAMPLE_DIR=$EXAMPLES_DIR/prototype_mtc
ESTIMATION_DIR=$EXAMPLES_DIR/example_estimation
BUILD_DIR=$ESTIMATION_DIR/build_example_data

# build example using example_mtc test data set (25 zones)
# build example using prototype_mtc test data set (25 zones)
# TAG=test
# BUILD_DATA=$MTC_EXAMPLE_DIR/data

# build example using example_mtc sf data set (190 zones)
# build example using prototype_mtc_sf data set (190 zones)
# data not in activitysim repo/distro
TAG=sf
BUILD_DATA=$MTC_SF_DATA_DIR

# build example using example_mtc sf data set (190 zones)
# data not in activitysim repo/distro
# TAG=full
# BUILD_DATA=$MTC_FULL_DATA_DIR

# output dirs for run to create fake survey data
BUILD_OUTPUT=$BUILD_DIR/output_build_$TAG

Expand Down Expand Up @@ -77,7 +72,7 @@ cp $BUILD_OUTPUT/trace/school_location*university*.csv $BUILD_DIR/scratch/$TAG/b
cp $BUILD_OUTPUT/log/activitysim.log $BUILD_DIR/scratch/$TAG/build

TAG=sf
python simulation.py -c override_configs -c configs -c ../example_mtc/configs -d data_$TAG -o output_$TAG
python simulation.py -c override_configs -c configs -c ../prototype_mtc/configs -d data_$TAG -o output_$TAG


EST_OUTPUT=output_$TAG
Expand Down
Loading