noi-techpark / webcomp-mobility-traffic

GNU Affero General Public License v3.0
2 stars 2 forks source link

As an end-user I would like to see the stretches coloured according to the real-time travel times #10

Open rcavaliere opened 3 years ago

rcavaliere commented 3 years ago

Following logic has to be implemented, for each LinkStation (so to let users see where a traffic jam is located) if travel times < threshold_1 -> green if travel times >= threshold_1 AND travel times < threshold_2 -> yellow if travel times > threshold_2 -> red In case travel times are not updated (i.e. timestamps are not of the current day) -> "not active" colour (e.g. gray) In case thresholds are not defined -> default coloration (e.g. BrennerLEC blue) Threshold values have to be mapped in specific config file(s).

The user story includes following tasks:

etomsen commented 3 years ago
{
  "1853-1854": [350, 600]
}

I've added a jams.json config file. Once we have the geometry for A22 we could then colour the trace as described. The structure is following: <link-station-id>: Array<threshold1, threshhold2>

rcavaliere commented 3 years ago

@etomsen in the meantime, you can find here the updated geometries in SHP format, which includes also the ones for the stretch Bolzano South - Bolzano North (and viceversa)

https://cloud.opendatahub.bz.it/index.php/s/zfGLREeJAKcWQng

rcavaliere commented 3 years ago

@etomsen can you please indicate me the exact path in the source code where I can find the jams.json config file?

etomsen commented 3 years ago

Its under the data folder

On Wed, Nov 11, 2020, 00:22 rcavaliere notifications@github.com wrote:

@etomsen https://github.com/etomsen can you please indicate me the exact path in the source code where I can find the jams.json config file?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/noi-techpark/webcomp-mobility-traffic/issues/10#issuecomment-724974502, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIGGYXKAWJ32LBULATFYCDSPGVKPANCNFSM4S4WSBLA .

etomsen commented 3 years ago
Screenshot 2020-11-13 at 13 25 54

I've added also a highway geometry info (from the provided files), but noticed that the path is slightly longer than A22 segment (see the screenshot)

rcavaliere commented 3 years ago

@etomsen it's correct, the travel times are calculated at the toll booth level

rcavaliere commented 3 years ago

@etomsen I think that the coloring of the stretches does not work properly. On the alternative roads, I don't see all stretches colored even if I configured them and we have real-time data values. Can you please analyze this as well?

etomsen commented 3 years ago

hey @rcavaliere! I've just checked the stretches jams colouring both for highway and urban roads. It seems to be working for jams (pls see the attached screen where I've changed the jam colour to different yellow #B0B400). Maybe you refer to the colouring of segments WITHOUT any traffic. This was always mapped to main colour.

For this, I've also just added a --noi-jam-none attribute to let you colour the segments without traffic ( before it was always corresponding to the main colour). the variables you are looking for are following:

--noi-jam-none: #339966; // for no-jam segments --noi-jam-light: #B0B400; // for segments with light traffic --noi-jam-strong: #B4001F; // for segments with heavy traffic

Please, let me know

image