Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Starter project: Improve traffic signal heuristics #8

Open
dabreegster opened this issue Nov 25, 2019 · 6 comments
Open

Starter project: Improve traffic signal heuristics #8

dabreegster opened this issue Nov 25, 2019 · 6 comments
Labels
good first issue Good for newcomers

Comments

@dabreegster
Copy link
Collaborator

I can't find data about how Seattle traffic signals are actually timed right now. So for the moment, I'm automatically generating a policy for every intersection. There are a bunch of different policies for different types of intersections (for a 4-way, should there be 2 phases with no protected left turn or 4 phases with protected left turns?). Every phase is hardcoded to 30 seconds right now. A nice project contained to one layer of the code (just the map model) would be to improve these heuristics. For example, roads have a rank (primary > secondary > residential) from OpenStreetMap, so probably bigger roads should have longer durations.

Ex policy: https://github.com/dabreegster/abstreet/blob/573edbd13e5aa4bedba0bd819d3d7b32dba11b59/map_model/src/traffic_signals.rs#L247

@dabreegster dabreegster added the good first issue Good for newcomers label Nov 25, 2019
@jraymakers
Copy link
Contributor

In the absence of specific data about traffic signals in Seattle, perhaps some techniques from a standard manual could be implemented. For example, the "Signal Timing Manual - Second Edition" (http://www.trb.org/Publications/Blurbs/173121.aspx). I've only skimmed this, but Chapters 5-7 appear to have lots of useful data.

@JavedNissar
Copy link
Contributor

Wouldn't this be resolved by #91 ?

@dabreegster
Copy link
Collaborator Author

Partly. Signal configuration seems to be at least two orthogonal problems:

  • what movements are allowed concurrently, aka, the number of phases. is there a protected left turn phase for road1->2, or is it an unprotected turn?
  • the timing and sequencing of each phase. this can be fixed or actuated, like Advanced Traffic Light Control #91

Both of these bugs kind of conflate these two things. Help needed on both.

dabreegster added a commit that referenced this issue Jul 4, 2020
dabreegster added a commit that referenced this issue Jul 4, 2020
try to synchronize them better. towards #8. not regenerating screenshots
because it's late and there'll be more screenshot churn tomorrow anyway
dabreegster added a commit that referenced this issue Jul 4, 2020
intersections to make the downtown map make more progress. make it
easier to copy OSM node IDs.
dabreegster added a commit that referenced this issue Jul 15, 2020
dabreegster added a commit that referenced this issue Dec 30, 2020


Previously, dual carriageways (pairs of one-way roads in opposite
directions) mostly didn't get any signal templates successfully applied.
This change ignores outbound-only roads when applying the templates. In
one fell swoop, lots of previously broken signals along places like
Aurora Ave suddenly work reasonably.
@dabreegster
Copy link
Collaborator Author

Still relevant, and hopefully a good starter project. We've gotten much better at grouping movements into stages, but we're still always hardcoding the timing to 30s.

@ciphx
Copy link

ciphx commented Jul 26, 2024

Hello @dabreegster , is this issue still open and can I pick it up? What would be a good starting point?

@dabreegster
Copy link
Collaborator Author

Sure, still open. There hasn't been active development on A/B Street in a while, but this is still a reasonably self-contained area. The code is at https://github.com/a-b-street/abstreet/blob/main/map_model/src/make/traffic_signals/mod.rs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants