Michael Kirk
d76bb3fbbd
update to geo 0.20.1
2022-04-22 18:13:36 +01:00
Dustin Carlino
d141a2a810
Upgrade all geo dependencies! No behavioral difference
2022-02-22 16:45:49 +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
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
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
638e93c36a
Stop re-exporting stuff from synthpop in sim
2022-01-28 13:13:43 +00:00
Dustin Carlino
9f86365cf6
Upgrade to rust 1.56 and cutover to rust edition 2021
2021-10-21 09:38:06 -07:00
Dustin Carlino
1d7149c18b
Don't crash in the activity model generators if a map has no borders. This currently happens with Overpass imports. #717
2021-07-25 10:30:06 -07:00
Rémi Lauzier
1a4b997818
Fix some clippy warnings
2021-06-16 16:21:35 -07:00
Dustin Carlino
5aa00955f9
Clean up the timer.parallelize API, getting rid of the weird enum to
...
toggle how many CPUs to thrash. We always use all of them, except for
one case, where a separately named method is more clear. Also make that
variation use all but 1 CPU, instead of just half.
2021-05-27 17:47:22 -07:00
Dustin Carlino
9fc79b1089
Use explicit start/endpoints for trips in scenarios. This is necessary
...
for people that leave one border, then re-enter a different one. #664
Alternative considered: insert a dummy remote trip between the two
borders. We used to do something like this at non-trivial code
complexity expense and having to explain the trip in the UI.
Regenerated all scenarios and prebaked data.
- Modest file size increase, as expected. Montlake scenario goes from
1.3MB to 1.5, downtown from 37MB to 43MB, all Seattle scenarios from
280MB to 327MB
- Eyeballed a few of the previously broken trips; they work now!
- Montlake goes from 3127 cancelled trips to just 302!
- No new gridlock, except in Rainier Valley -- disabling that for now
- I discovered missing validation in Poundbury for no-op trips between
the same building. I'll filter those out and restore prebaked results
there in a followup.
2021-05-26 14:30:01 -07:00
Vinzent Steinberg
a1899e29f8
Update dependencies ( #656 )
...
* Update dependencies
* Use github for polylabel, to make all dependencies use geo 0.18, not a mix of 0.18 and 0.17
* Downgrade lyon to avoid a crash
Co-authored-by: Dustin Carlino <dabreegster@gmail.com>
2021-05-22 16:23:06 -07:00
Vinzent Steinberg
9d17faa878
Prefer slices over reference to owned type
2021-05-15 14:24:08 -07:00
Dustin Carlino
1edbca6509
Refactor most of the places extracting polygons from geojson files ( #644 )
2021-05-15 09:05:28 -07:00
Vinzent Steinberg
fd3b0e2a14
Fix compilation failures and most clippy warnings ( #642 )
...
* abstutil: Fix compilation failure
* map_gui: Fix compilation
* traffic_signal_data: Fix compilation failure
* map_model: Fix compilation failure
* abstutil: Fix doctests
* abstio: Fix most clippy warnings
* abstutil: Fix most clippy warnings
* collisions: Fix clippy warning
* convert_osm: Fix clippy warnings
* sim: Fix most clippy warnings
* geom: Fix clippy warnings
* kml: Fix clippy warnings
* map_model: Fix most clippy warnings
* fifteen_min: Fix clippy warnings
* game: Fix many clippy warnings
* Disable some noisy clippy warnings
* headless: Fix clippy warnings
* importer: Fix clippy warnings
* map_editor: Fix clippy warnings
* map_gui: Fix clippy warnings
* osm_viewer: Fix clippy warnings
* parking_mapper: Fix most clippy warnings
* popdat: Fix clippy warnings
* santa: Fix clippy warnings
* sumo: Fix clippy warnings
* traffic_seitan: Fix clippy warning
* updater: Fix clippy warnings
* widgetry: Fix clippy warnings
* tests: Fix some clippy warnings
* Fix compilation on stable Rust
* Simplify unwrapping
* Make use of `Entry` more readable
* Fix formatting
* Fix code that was broken in the refactoring
* Apply cargo +stable fmt
* Fix code that was broken in the refactoring, second try
* Remove `Default` impls that are equivalent to `new`
* Remove obsolete clippy wrapper
* Avoid turbofish
* Prefer `unwrap_or_else` over allowing `clippy::or_fun_call`
* Remove redundant `into_iter`
* Fix typo
* Prefer `&& false` over commenting code out
* Fix some clippy warnings
Co-authored-by: Dustin Carlino <dabreegster@gmail.com>
2021-05-14 08:32:56 -07:00
Dustin Carlino
0357ae0a23
Tidy up the new UK census gen code. #556
2021-03-05 16:51:02 -08:00
Dustin Carlino
8ffd249558
Get the new UK scenario generation working everywhere. #556
...
If a study area exists for the map, make a copy of the base/active
scenarios with the background traffic mixed in. Also remove people
living in the site, since they're redundant.
Ran it like this: for city in `ls data/system/gb/`; do ./import.sh
--scenario --city=gb/$city || break; done
2021-03-05 16:26:29 -08:00
Dustin Carlino
14ccddf15e
Create people that live or work (or both) off-map. #556
2021-03-05 15:50:56 -08:00
Dustin Carlino
9610b69de4
Remove zones without homes or shops. Found one in London. This can
...
happen when the overlap with the map is tiny. #556
2021-03-05 14:53:29 -08:00
Dustin Carlino
d2b25f9340
Use choose_weighted to sample homes/workplaces proportionally, instead of worrying about how many employees per store there might be. #556
2021-03-05 12:33:04 -08:00
Dustin Carlino
89f317c79d
Add in normal distributions for trip departure times. #556
2021-03-05 12:24:17 -08:00
Dustin Carlino
c7042eda06
Create simple people for UK scenarios. #556
...
Can't quite debug yet, because for Poundbury, the matching zones (like
E02004277) have no entries in the census data...
2021-03-05 11:59:20 -08:00
Dustin Carlino
1f33916502
Match houses/workplaces to zones. #556
2021-03-05 11:27:25 -08:00
Dustin Carlino
aa59677ad2
Transform the UK OD and zone data from raw input into a clean structure. #556
2021-03-05 10:47:48 -08:00
Michael Kirk
4b665c871d
update geo related deps. ( #508 )
...
geo-types to 0.7
geo to 0.17 which removes redundant old geo used by polylabel
geojson to 0.22
2021-02-08 16:34:56 -08:00
Michael Kirk
7cd4329866
fix census driven activity model ( #507 )
...
It was failing because the version of flatgeobuf we were using was not
compatible with the recent tokio update. Now we point to the unreleased
flatgeobuf which is compatible.
2021-02-08 14:15:58 -08:00
Dustin Carlino
73e405e382
Upgrade most dependencies
2021-02-03 18:13:06 -08:00
Dustin Carlino
d49c6c5d7d
Refactor the logic of distributing N people to K buildings. This was
...
duplicated between the Berlin importer and the new census-based popdat
crate, and I suspect some form of it might get used for the actdev
integration. #424
2021-01-13 11:18:51 -08:00
Dustin Carlino
e99def9124
Switch all error handling to anyhow. Nothing consumes our code as a
...
library yet, so this is a step forward from string errors. Manually
tested how errors show up (including the nice with_context bit).
2021-01-05 11:35:03 -08:00
Dustin Carlino
d529ae2e5c
Upgrade usvg and rand
2021-01-04 09:19:54 -08:00
Dustin Carlino
965d999199
Upgrade misc other dependencies
2021-01-03 20:01:27 -08:00
Dustin Carlino
2945913fb3
Upgrade rand
2021-01-03 19:48:03 -08:00
Michael Kirk
147c36d8fe
remove broken popdat main ( #441 )
...
I broke this in acadad8bd
We could fix this by making main async and fetching CensusAreas and
passing them into the generate function... but it doesn't seem like
we're using this any longer anyway.
2021-01-01 21:37:45 -08:00
Michael Kirk
acadad8bdf
fetch US census data from a hosted FlatGeoBuf ( #432 )
2020-12-31 16:20:32 -08:00
Dustin Carlino
32a3159d19
Express AmenityType as a proper enum.
2020-12-28 12:18:29 -08:00
Dustin Carlino
2b4b92664e
Much needed refactor: map.pathfind() returns a Result, stating the failed request. Many call sites were cloning the request and doing this anyway.
2020-12-16 10:06:12 -08:00
Michael Kirk
375e0caeb8
integrate census scenario ( #426 )
...
#424
2020-12-14 20:27:57 -08:00
Michael Kirk
8b9b3ce2b1
census areas import ( #425 )
...
#424
2020-12-14 17:48:47 -08:00
Michael Kirk
5c09e24225
Correlate some more activities with OSM tags. ( #423 )
...
Thanks to Tom Skinner (@trskinner) for the patch!
2020-12-10 21:55:56 -08:00
Dustin Carlino
634b6ad375
Get more pieces of popdat working: ( #421 )
...
- adapt the Berlin logic for disaggregating people to buildings
- start some person -> activity -> schedule mappings
- clean up all the unused var warnings
2020-12-10 16:44:42 -08:00
Dustin Carlino
fb9635e8c8
Copy some pieces of the proletariat robot model into the new popdat pipeline: ( #419 )
...
- mode choice
- going off-map when there's no building on-map to satisfy a particular
activity
2020-12-10 14:51:36 -08:00
Dustin Carlino
7e376de03f
Start transforming an abstract schedule into a specific list of trips
2020-12-10 12:28:12 -08:00
Michael Kirk
d445ca386a
fix typo ( #418 )
2020-12-10 09:41:14 -08:00
Dustin Carlino
77a37f897b
Wire together a UI to generate census-based scenarios
2020-12-10 09:35:50 -08:00
Dustin Carlino
f23dacbde7
Start some skeleton code for tomorrow's hackathon
2020-12-09 22:11:05 -08: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
dd1c9f936d
plumb through exact off-map locations from popdat->scenario
2020-04-24 22:05:33 -07:00
Dustin Carlino
a25751ea43
add more sanity checks for schedules, because every other map is
...
crashing
and fix the problem -- SpawnTrip -> TripSpec MUST succeed. auto-abort
some trips, to still warp the person to the right spot.
2020-04-23 13:20:25 -07:00