Commit Graph

90 Commits

Author SHA1 Message Date
Dustin Carlino
4a07164394 Add the concept of trip purpose. Seed it from Soundcast data, or assign
it for the prolet robot model. Expose it in the trip info panel.

Total scenario size from 385MB to 412MB, but that's not so bad, and this
seems worth it.
2020-09-19 13:02:36 -07:00
Michael Kirk
08f330cfad track worker capacity of commercial buildings 2020-09-16 16:43:11 -07:00
Dustin Carlino
edbc674970 Fix stop sign placement for left-handed maps. #311 2020-09-11 11:03:59 -07:00
Dustin Carlino
5be4c2ca84 Add an API to add a new trip in the middle of the simulation. Fixes #313
[rebuild]
2020-09-06 13:53:31 -07:00
Dustin Carlino
4367c03a7d Add a tool to generate a random proletariat robot scenario given an RNG seed, for the forecasting group. #313 2020-09-04 11:10:38 -07:00
Dustin Carlino
65e07d9cc7 Read/write scenarios in JSON, so people can manipulate them in any language. #313 2020-09-04 10:57:52 -07:00
Dustin Carlino
4576e9c1d0 Start importing a tiny slice of London, to start working on left-hand driving again 2020-09-03 16:09:17 -07:00
Dustin Carlino
b13f5b0f4a Move iotool things into the importer package, but keep separate binaries 2020-09-03 11:49:53 -07:00
Dustin Carlino
6a9d55b7f5 Since the first line of the osmosis file doesn't matter, more clearly rename it 2020-09-02 22:12:43 -07:00
Michael Kirk
6482f8b0a4
util to convert geojson to osmosis polygon (#309) 2020-09-02 15:29:25 -07:00
Dustin Carlino
651b4f5ec9 Some code style cleanups after #296 2020-08-27 09:10:39 -07:00
Kyle Huston
90cf38a522
Fail importer immediately if dependencies are missing and make gunzip etc. configurable (#296)
* Read ImporterConfiguration from .toml file if present. Also check for presence of dependency programs.

* Actually use config.osmconvert instead of hard-coded 'osmconvert'

* Add curl to checked dependencies

* Don't require all fields to be present in importer.toml configuration. Fill in defaults.

* Remove unneeded slice

* Use json for importer config and use serde(default) attribute to simplify application of defaults

* Extract re_dependencies_callable from main.rs and remove dependency on Job

* Revert change to abstutil, use struct-level default attribute

* Add importer.json to .gitignore

* Make gunzip_args string instead of Option<string>
2020-08-27 09:06:14 -07:00
Dustin Carlino
4e25a22cd0 actually, tel aviv has lots of street parking, so randomly assign 50% [rebuild] 2020-08-26 10:33:29 -07:00
Dustin Carlino
8b7ad86647 Regularly import Tel Aviv! 2020-08-26 10:25:45 -07:00
Dustin Carlino
5528f19f87 Split pathfinder struct into an enum to make room for a variation that
just does Dijkstra's. This has a few uses:

- When you import with --skip_ch, the resulting map will still work,
  just more slowly
- For congestion capping experiments, we sometimes want to route around
  a zone. Regenerating the contraction hierarchy for every combination
  of zone being open/closed is likely more complex and expensive than
  just falling back to A* for trips that cut through at least one closed
  zone.

Not regenerating yet
2020-08-22 09:54:02 -07:00
Dustin Carlino
9a350b7568 Regularly import Xi'an 2020-08-17 19:37:34 -07:00
Dustin Carlino
49ea9f2d54 Faster London:
- wire up the flag to skip building contraction hierarchies in one-shot
  importer. 406s to import london without, 230s by skipping CH
- lazily render zoomed parking lot details. 72s and laggy X11 mouse
  before, 42s and no GPU melting after
- add my script for stress-testing the importer
2020-08-14 20:50:22 -07:00
Dustin Carlino
843d24b6ed Refactor: OriginalBuilding should just be OsmID. The purpose of
OriginalBuilding was to refer to buildings in a stable way across
different maps and across OSM updates. Recently, OsmID and friends
appeared. The double layer of wrapping is an annoying API.

Not regenerating map data yet; about to do the same thing for
OriginalIntersection
2020-08-13 11:37:06 -07:00
Dustin Carlino
d1e9e38e82 refactor for #231: use typed OSM IDs everywhere, dedupe URL code
have to regen, the binary format has changed
2020-08-08 16:09:36 -07:00
Dustin Carlino
3c24b7aa5a pull in spawn times for seattle from gtfs. looks wrong, but it's a
start.
2020-08-05 14:46:37 -07:00
Dustin Carlino
22afb60421 woops, parcels.bin wasnt deterministic. kept seeing a diff in data/MANIFEST. 2020-08-03 11:31:56 -07:00
Dustin Carlino
d22aa87139 rearrange Building internals for #176. edits can affect building
connections to driving/biking. just store the immutable stuff -- whether
there's parking in the building, the connection to the sidewalk, and the
physical driveway line. compute all the rest dynamically, so it responds
to edits without effort.

shouldn't be major behavior changes yet (besides maybe fixing some bugs
involving edits)
2020-07-31 12:49:33 -07:00
Dustin Carlino
e1e265db14 tighten up Polygon constructors to enforce an outer ring... in most
cases now.
2020-07-27 14:03:55 -07:00
Dustin Carlino
7a00839553 ditch osm-xml, make a new osm parser from scratch based on roxmltree.
skip unreferenced objects, make the output extremely easy to consume.
also fix timers in importer. this helps with #212, although the actual
problem there is weird.

regen everything. some parking lots change a bit, but not horribly, and
that code needs some attention anyway.
2020-07-25 13:52:41 -07:00
Dustin Carlino
fc761ae032 stop bringing in railway=rail for seattle. it's cosmetic only, and it messes up some geometry in south seattle and causes gridlock. not worth it yet. 2020-07-24 20:22:33 -07:00
Dustin Carlino
328cbcd1f1 stop melting my laptop when generating scenarios 2020-07-23 09:15:25 -07:00
Dustin Carlino
0f0860b4b5 make the importer depend less on external unix commands for #119. still need to handle unzip and curl. 2020-07-22 22:51:45 -07:00
Dustin Carlino
4fb7e008c0 scale num_residents for polygons near the map boundary, for #119 2020-07-22 13:24:56 -07:00
Dustin Carlino
bbe06c6075 randomly distribute residents to buildings in the planning area for #119 2020-07-21 14:00:59 -07:00
Dustin Carlino
82dd1fd01a spawn a new bus for every route every hour 2020-07-16 11:58:09 -07:00
Dustin Carlino
1d89d4b85f tie population count to planning areas in berlin, for #119 [rebuild] 2020-07-16 11:34:46 -07:00
Dustin Carlino
e2d478340b bring in planning area KML for berlin, #119 2020-07-16 11:15:22 -07:00
Dustin Carlino
4a118c8103 import berlin city centre for #119 2020-07-15 09:42:45 -07:00
Dustin Carlino
7341c0189a plumb through which trips (and people) are affected by an experiment. no
UI exposure yet.
2020-07-14 14:49:04 -07:00
Dustin Carlino
b4b8556f46 just get a few new traffic signals and add parking to south seattle, to
try to make progress
2020-07-13 16:07:35 -07:00
Dustin Carlino
0f82c21560 - manually fix a few crazy signals downtown.
- interpret tags to make 3rd Ave bus-only. cars technically allowed
  sometimes, but bus-only is more accurate for now.
- also remove austin from bundled maps. maintaining it has a cost, and
  the point was just to have at least one non-seattle city kept up to
  date.  krakow now satisfies that.
2020-07-13 13:40:46 -07:00
Dustin Carlino
b058d5d926 cargo fmt and regenerate map data 2020-07-13 10:11:48 -07:00
Mateusz Konieczny
885fdefb5d
playing with processing modifications (#183)
* WIP set up plumbing for calculating building info in the Raw layer and using it later for #154

* WIP playing with processing modifications

* experiment with some possibilities for tag processing

* fix an embarassing typo

* enable busses in work-home traffic

* refactor, add multiuse

* seed more parking in Kraków

* parse integers properly - thanks for a help!

* rebalance generated trips

* add hack providing some background traffic

more realistic traffic

even mess realistic people

* attempt to further reduce parking deficit

* add TODO

Co-authored-by: Dustin Carlino <dabreegster@gmail.com>
2020-07-13 09:56:05 -07:00
Dustin Carlino
0dd3199f7a cut down variations of pt2d<->gps. mostly we want to forcibly convert.
possible semantic change: soundcast border matching now includes ALL
borders, even if the center is slightly OOB
2020-07-11 12:02:12 -07:00
Dustin Carlino
f8ace3c0ab per-city config to let bikes use bus lanes, for #184
while I'm regenerating maps anyway, grab fresh seattle osm with more
lane fixes. and parallelize a slow point matching step -- 10x speedup
for austin
2020-07-11 11:08:23 -07:00
Dustin Carlino
3639379313 importer option to assume onstreet parking on some residential roads, if OSM doesnt say anything. give 50% of residential roads in krakow some parking. fixes #171
also clean up the seattle sidewalks dataset for now; the matching code
is quite bad, and not planning to use this anytime soon
2020-07-09 15:14:08 -07:00
Dustin Carlino
19409dfc8c add krakow as an optional city. need to specify more customization for #171, and given how much work is focused here, using the one-shot importer no longer makes sense 2020-07-09 14:33:39 -07:00
Dustin Carlino
9f72b3dd51 cleanup after the relative dir fix, and add support for hardcoding the
data dir, for #137
2020-07-07 12:14:02 -07:00
Dustin Carlino
6919c24bf8 detect the data/ dir more intelligently. fixes #73. still need to
- consider collapsing the directory structure in the releases
- fix wasm

[rebuild]
2020-07-07 11:09:35 -07:00
Dustin Carlino
c1f752730c woops, needed to regenerate scenarios a few commits ago, the laneids are off 2020-07-06 16:47:41 -07:00
Dustin Carlino
56cb59c3ac rip out gtfs code, cutover to osm. will revisit this later; gtfs and osm probably disagree on routes and stops, and gtfs has schedule. but for now, just osm. 2020-07-03 17:33:32 -07:00
Dustin Carlino
c97bd0fe4b some cleanup after #106. unbreak importer 2020-06-28 11:13:35 -07:00
Dustin Carlino
a6b90d00d8 very simple modifier to cancel all trips for some percentage of people 2020-06-27 14:20:25 -07:00
Dustin Carlino
455b17faef start playing around with manchester 2020-06-27 12:32:03 -07:00
Dustin Carlino
16bc96c401 try adjusting the offstreet spots in downtown to be a fraction of the
initial demand
2020-06-13 15:38:04 -07:00