Commit Graph

7409 Commits

Author SHA1 Message Date
Dustin Carlino
b62954ef30 Add procgen houses for Levenshulme, since parts of the map are just missing buildings.
Regenerate the scenario in S3 now. Comparison with traffic counts barely
changed, so this didn't make much of a difference, but it can't hurt.
2022-02-03 14:40:57 +00:00
Dustin Carlino
9323b4dc37 Count throughput at border intersections #848 2022-02-03 14:29:50 +00:00
Dustin Carlino
ba5bf26072 Overhasty push on the last commit 2022-02-03 14:22:03 +00:00
Dustin Carlino
f22590ae0c Refactor MapBorders, used to snap trips starting/ending off-map to a
border. Try weighting by road classification. #848

No behavioral change for anything except UK scenarios. Still not
regenerating those.
2022-02-03 14:20:03 +00:00
Dustin Carlino
b93850406f Revive efforts on the generic desire line -> scenario pipeline. Include desire lines for zones that don't intersect the map boundary at all, with very simple border intersection snapping.
Note this changes all UK scenarios, but I'm not going to regenerate any
of them and put in S3 until I'm getting decent results at least in
Manchester.
2022-02-02 16:28:49 +00:00
Dustin Carlino
b9872f6a46 Quickly compare Levenshulme sensor data to generated scenarios, from the console (I guess the UI isn't as useful as I expected yet) 2022-02-02 14:55:53 +00:00
Dustin Carlino
487e1ba870 Move traffic counting code into synthpop. In the short-term, I want to quickly check a generated demand model against sensor data. Eventually some kind of calibration may live in this crate. Regardless, counts aren't just a UI concept. 2022-02-02 14:24:02 +00:00
Dustin Carlino
7509d0fa11 Don't draw border intersection outlines when they're filtered 2022-02-02 10:03:50 +00:00
Dustin Carlino
a7ded378e1 Apply the auto-LTN heuristics to the whole map with one click 2022-02-02 10:01:36 +00:00
Dustin Carlino
d6dc9de221 Add a mode to show quietness / rat runs for all neighborhoods at once 2022-02-02 09:51:01 +00:00
Dustin Carlino
635f508540 At really low zoom levels, draw modal filters using the scale-invariant
circles. Otherwise they're just impossible to see. Since they're the
most important thing to show in the LTN tool, seems worth it.

This helps proceed on #851
2022-02-02 09:20:10 +00:00
Dustin Carlino
067fdb8649 Parse GeoJSON data as ExtraShapes, to debug UK zones 2022-02-01 15:40:23 +00:00
Dustin Carlino
428451478c Conveniently open OSM objects from LTN tool. #851 2022-02-01 14:58:03 +00:00
Dustin Carlino
c5d022d7be Prevent traffic count tool from crashing when one dataset is mostly not filled out 2022-02-01 10:52:57 +00:00
Dustin Carlino
e3bdc086ac Add road search tool to per-neighborhood states. #848 2022-02-01 10:27:45 +00:00
Dustin Carlino
e0b6e94f26 In the LTN browse and connectivity tool, draw the areas after the map
background and water/parks, but before everything else. It's much easier
to understand the actual basemap this way -- you can see roads clearly.
2022-02-01 09:31:28 +00:00
Dustin Carlino
e5704f4a6d Prevent many cases of blocks with overlapping geometry or that extend
too far, by not trying to trace near railways or cycle-only
bridges/tunnels. This is an imperfect heuristic, but it makes
significant progress in most maps.
2022-01-31 16:03:21 +00:00
Dustin Carlino
060decbdd3 Put a minimal UI around saving/loading LTN proposals 2022-01-31 13:30:55 +00:00
Dustin Carlino
f8dfe32c04 Save LTN edits to files and load from CLI. No proper UI yet, and the
format isn't future-proof at all.
2022-01-31 13:30:55 +00:00
Dustin Carlino
942c3ecdaf Make SimpleApps all manage their own CLI parsing, so they can add their own overrides. 2022-01-31 13:30:55 +00:00
Dustin Carlino
eda9ff20bd new release 2022-01-30 19:30:52 +00:00
Dustin Carlino
0058f99da2 Mechanical rename of TripEndpoint::Bldg to ::Building, mostly to kick off a [rebuild] [release] 2022-01-30 18:27:36 +00:00
Dustin Carlino
3d33d2743b Document the new synthpop crate.
I regenerated some scenarios; no diff. The prebaked summaries change a
bit, but not the prebaked results -- not sure, but going to proceed.
2022-01-28 13:13:43 +00:00
Dustin Carlino
638e93c36a Stop re-exporting stuff from synthpop in sim 2022-01-28 13:13:43 +00:00
Dustin Carlino
f171ddcb73 Get everything to build again... 2022-01-28 13:13:43 +00:00
Dustin Carlino
9845d9cae1 Implement the two public TripEndpoint methods in synthpop, but without needing to drag in SidewalkSpot and DrivingGoal 2022-01-28 13:13:43 +00:00
Dustin Carlino
3f8689b9ea Rearrange methods defined on Scenario that're only for the sim crate 2022-01-28 13:13:43 +00:00
Dustin Carlino
231acf47a2 Step 2: try to get the sim crate to build again
Scenario and TripEndpoint have some methods defined on them that're
specific to sim. Do we rearrange these methods entirely or make some
kind of wrapper types?
2022-01-28 13:13:43 +00:00
Dustin Carlino
e45a5181db Split the "input" layer of the sim crate into a synthetic population
crate, in preparation for future focus on travel demand models that
incorporate more per-person info.

Note: I'm also a bit tempted to try to further split sim into a
"high-level" layer that orchestrates spawning and different legs of a
trip, from the "low-level" layer that moves pedestrians and vehicles.
That could _possibly_ pave the way for someday using a different traffic
simulation backend with more realistic movement mechanics.

Step 1: just get the synthpop crate to build
2022-01-28 13:13:43 +00:00
Dustin Carlino
6c2a581be5 Simplify traffic count code -- directly deal in Counters 2022-01-28 10:40:56 +00:00
Dustin Carlino
921228b7bf Add a headless API command to load a map with an empty simulation. #838 2022-01-28 09:37:25 +00:00
Dustin Carlino
47962cfdbd Add a headless API command to snap a point to the nearest road, for https://github.com/dabreegster/urban_observatory_abst 2022-01-27 17:44:48 +00:00
Dustin Carlino
fefe8f5be2 Swap the traffic counts in the UI 2022-01-27 15:21:21 +00:00
Dustin Carlino
e542011614 More fluid UI for comparing traffic counts -- hotkeys
Had to change the API of on_click...
2022-01-27 15:13:24 +00:00
Dustin Carlino
e21c57b70a When calculating traffic volumes, deduplicate path requests first.
Around 2x less paths to calculate.

Even though the deduplication throws away some info, the net effect for
measuring traffic volumes is practically equivalent, so it's a
worthwhile optimization. Used the new comparison UI to verify that!
2022-01-27 14:26:36 +00:00
Dustin Carlino
edfd320908 A new generic UI to compare counts from two files.
Also moving some of the counts stuff to map_gui, accordingly
2022-01-27 14:26:36 +00:00
Dustin Carlino
c33ba85cfe Make LTN impact prediction use the new common code 2022-01-27 14:26:36 +00:00
Dustin Carlino
a6b4f8879a Refactor parts of the LTN impact prediction into a separate UI just for
comparing count data.

Don't use it yet
2022-01-27 14:26:36 +00:00
Dustin Carlino
ee8c8d8611 Simplify impact results plumbing 2022-01-27 09:44:13 +00:00
Dustin Carlino
be57975a91 Start to shape the LTN impact tool into something more general to plug a
demand model into routing and compare throughput before/after some
change.

Add in a bunch of filters for trips. (Most even work!)
2022-01-26 14:17:24 +00:00
Dustin Carlino
e318f2733b Import Wokingham 2022-01-26 12:09:37 +00:00
Dustin Carlino
cabffc7f47 Similar refactor for ColorDiscrete. Anywhere separately managed a zoomed
and unzoomed batch should just migrate to this.
2022-01-26 11:35:40 +00:00
Dustin Carlino
5dfb8f26f0 Refactor ColorNetwork to use ToggleZoomed 2022-01-26 11:31:33 +00:00
Dustin Carlino
ec0fd1b94d Stop running out of video memory in the LTN impact prediction tool.
- One batch for all neighborhoods
- One batch for all roads/intersections
- No pre-built tooltips

This all comes at more repetitive code. Need to make World generate some
stuff dynamically (#763)
2022-01-26 11:26:03 +00:00
Dustin Carlino
deffc35fd7 Optionally generate a scenario for one-shot imported UK maps. #842 2022-01-26 10:31:38 +00:00
Dustin Carlino
0203de046d Don't repeatedly try to merge blocks in the select boundary UI. An optimization to workaround new sanity checks introduced for #841 2022-01-26 10:15:31 +00:00
Dustin Carlino
dfbd9785f3 While merging adjacent perimeters for the LTN tool, don't proceed if
intermediate results can't be turned into a polygon. It'll break
something later. #841

There's a particular bug where a perimeter can be turned into a polygon,
but after collapsing internal dead-ends, it can't.

If we don't do this, the LTN select boundary UI crashes, and reasoning
about block -> neighborhood mappings gets very hairy. I'd like to
address all the root causes of failing to make a polygon, but until
then...

TRADE-OFF: it _really_ slows down the select boundary UI.
2022-01-25 18:12:15 +00:00
Dustin Carlino
eba579dbd1 Adjust the definition of cycleway roads to include sidewalks. Any road
with only bike lanes and any walkable lane counts as a cycleway, for
rendering purposes. So if you change a road with sidewalks to only allow
bikes on the road, it shows up green in the unzoomed layer.

There's lots of nuance with footways that doesn't matter yet, because
we're mostly not importing those yet.
2022-01-25 14:10:39 +00:00
Dustin Carlino
9192c6364b Avoid crash in the blockfinder when merging partitions manually 2022-01-25 14:01:24 +00:00
Dustin Carlino
847ca07bc6 Add the quick-select feature to the blockfinder debugging too 2022-01-25 13:54:30 +00:00