Commit Graph

131 Commits

Author SHA1 Message Date
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
Dustin Carlino
42ea64a680 changing parking seeding to fill in private spots first. makes progress
in larger maps. i made sure the optimize challenge is still interesting
after this change.
2020-06-13 15:14:23 -07:00
Dustin Carlino
aceadef79f refactoring some trip spawning stuff from importer, using it in the new agent spawner too 2020-06-01 17:37:54 -07:00
Dustin Carlino
42a35c736a starting a city region picker 2020-05-28 14:11:34 -07:00
Dustin Carlino
ddf6de5f59 stop dependending directly on serde_derive 2020-05-19 15:06:32 -07:00
Dustin Carlino
ee35ff79b9 dont needlessly load files in importer 2020-05-17 14:19:45 -07:00
Dustin Carlino
e082082c32 try again to bundle importer in release for oneshot. disable gdal.
[rebuild]
2020-05-17 09:25:44 -07:00
Dustin Carlino
a362c73689 plumb trips per parcel tooand add more queries, make a kml chooser 2020-05-16 13:24:58 -07:00
Dustin Carlino
20f8548634 debug association between soundcast parcels and buildings 2020-05-16 12:36:10 -07:00
Dustin Carlino
0fa4b30521 turn soundcast parcels into extrashapes / kml to understand skipped
parcels
2020-05-16 10:26:59 -07:00
Dustin Carlino
1c3073d0e2 work on getting the udistrict to run better. add options to handle
outliers in the heatmap
2020-05-15 16:46:12 -07:00
Dustin Carlino
9f66c38f69 optionally skip building CH during importing 2020-05-15 09:30:24 -07:00
Dustin Carlino
95a0f2f620 working on west seattle 2020-05-14 12:03:19 -07:00
Dustin Carlino
f6bd936c53 grab fresh osm. also keep some intermediate files, to make some binary
format changes less of a disruption
2020-05-13 22:55:05 -07:00
Dustin Carlino
dd99936fa0 also scrape amenities from buildings themselves. make an 'other'
category
2020-05-13 13:58:15 -07:00
Dustin Carlino
510e75b043 include importer in release [rebuild] 2020-05-12 11:04:18 -07:00
Dustin Carlino
d7df50ab37 make a one-command version of the importer. remove barranquilla and LA,
since they can just be handled by the oneshot tool, and arent being
actively used yet
2020-05-12 10:27:07 -07:00
Dustin Carlino
c6f34de3d7 add udistrict map. lots of work before this will run reasonably 2020-05-10 22:01:52 -07:00
Dustin Carlino
5ae94168f6 fix mt baker a little, at least get the north half of i90 included. lots
of jams along rainier.
2020-05-10 15:49:24 -07:00
Dustin Carlino
182f5139a5 rip out old mapfixes code. pure OSM is more maintainable. keep map_editor for drawing synthetic maps and debugging raw maps 2020-05-10 10:39:08 -07:00
Dustin Carlino
b756edb36f grab fresh OSM and enable smarter border matching. few fixes to keep
lakeslice working
2020-05-09 19:51:48 -07:00
Javed Nissar
0af34e9e01
Resolve #50 by parallelizing raw->map jobs using std::thread (#55) 2020-05-09 18:32:42 -07:00
Dustin Carlino
42dd5c9657 match trips to borders using a path from huge_seattle. initial results
seem reasonable, but not enabling yet
2020-05-09 13:15:21 -07:00
Dustin Carlino
819aa179d7 add map to study mt baker area. extending lakeslice had some problems.
updated blockface, so some other spurious little changes
2020-05-08 13:52:19 -07:00
Dustin Carlino
ce0c5d4d04 update osm. stop crashing when switching to map without weekday scenario 2020-05-04 13:25:06 -07:00
Dustin Carlino
7d2fa77323 grab turn restrictions across roads from OSM, plumb into RawMap 2020-05-03 10:41:00 -07:00
Dustin Carlino
f1ac0dccc0 new city: Barranquilla 2020-05-02 15:43:19 -07:00
Dustin Carlino
02c5b6617b dismantle importing for neighborhoods. long unused. just retain a simple
osmosis polygon editor.
2020-05-01 14:11:41 -07:00
Dustin Carlino
01bd4aec6f clean up some fallout from the grand data refreshening. mostly
robustifying tutorials/challenges by using IDs stable across map updates
2020-05-01 10:54:43 -07:00
Dustin Carlino
734c06418a It is 5 am
And you are listening
To Los Angeles
2020-04-28 14:31:23 -07:00
Dustin Carlino
18779c10ad organizing data/input by city. (I tried organizing everything in data/,
but it's too big a change. small steps.)
2020-04-28 12:28:37 -07:00
Dustin Carlino
b93f96628f hackily add a second city to the importer. remove the per-map
.gitignore; MANIFEST covers this better
2020-04-27 20:36:04 -07:00
Dustin Carlino
193ff2344a require a particular directed road for spawning from borders 2020-04-26 12:35:07 -07:00
Dustin Carlino
725e9e4532 generate a scenario purely with off-map trips. problems running it, but
good start.
2020-04-25 15:18:27 -07:00
Dustin Carlino
8be319300b fold the popdat crate into importer; nothing else should have any dependencies on it 2020-04-25 13:14:48 -07:00
Dustin Carlino
7eba721145 decide extra offstreet parking by an option in convert_osm. remove the old standalone binary in favor of just using importer 2020-04-25 10:36:49 -07:00
Dustin Carlino
dd1c9f936d plumb through exact off-map locations from popdat->scenario 2020-04-24 22:05:33 -07:00
Dustin Carlino
0f2962094f dont filter out any parcels from psrc. plumb through oob points, match to borders a little later. also pick up school bus as transit 2020-04-20 17:14:30 -07:00
Dustin Carlino
0574d4316c add some stuff to match people in scenarios with the raw input 2020-04-20 16:52:54 -07:00
Dustin Carlino
bf8c35788b moving popdat+precompute into the new unified importer 2020-03-26 10:26:01 -07:00
Dustin Carlino
0133685eb7 converted the import.sh shell script into Rust. towards #27
as part of this, wound up grabbing fresh OSM and GTFS. but actually cant
reimport OSM right now, because fixes reference old OSM IDs and things
break. so sticking with old OSM, but new GTFS. urgh.
2020-03-25 19:54:33 -07:00