nptscot / nptscot.github.io

Network Planning Tool for Scotland: front end.
https://www.npt.scot
GNU Affero General Public License v3.0
7 stars 5 forks source link

Level of Service section on UI #175

Closed Robinlovelace closed 1 month ago

Robinlovelace commented 2 months ago

Finally we have some details on this after good work by @joeytalbot to classify the infrastructure and conversation with @anguscalder.

With reference to the image below, the main (possibly only) element in this section will be:

We can always change this, e.g. to have 2 dropdowns one with level of compliance and another with associated infrastructure.

This where we're at currently, need to collapse the 6 current categories into 3:

image

Robinlovelace commented 2 months ago

With reference to this, we need to get this done on backend before sending data you way Martin: https://github.com/nptscot/npt/issues/324

Robinlovelace commented 2 months ago

Also from Angus:

[11:51] Angus Calder

 

Existing Context
Infrastructure
  Traffic Volumes
  Speeds
   
Infrastructure Existing CBD Compliance Layer
  CBD Compliant Infra

 

[11:52] Angus Calder

Also need % network complaint

mvl22 commented 2 months ago

As usual let me know when some data is on the server and I can put in a UI to read it and test against it.

Robinlovelace commented 2 months ago

:+1: thanks Martin, on it.

Robinlovelace commented 1 month ago

Heads-up @mvl22 we have some data for you: https://nptscot.blob.core.windows.net/pmtiles/cbd_layer.pmtiles

mvl22 commented 1 month ago

This is normally known as the Cycling Level of Service (or CLoS for short). Can I check whether this is known as LoS instead in Scotland?

mvl22 commented 1 month ago

You requested these layers:

  • Current LoS [default view] with the following colours:
  • Existing infrastructure (baseline)
  • Compliant infrastructure scenario (minimum)
  • Compliant infrastructure scenario (best practice)
  • Current traffic volume
  • Current speed limit

However, the fields in the data are:

I will assume for now the latter fields are what should be used.

Could I request these are given updated fieldnames without spaces please, ideally lower-cased.

mvl22 commented 1 month ago

The main sublayer is now implemented; I'll work on the others next.

Screenshot 2024-05-17 at 00 30 21

Robinlovelace commented 1 month ago

Looking great as 1st pass

Robinlovelace commented 1 month ago

Here's some more feedback @mvl22:

Will aim to check in with @anguscalder on this later today.

Robinlovelace commented 1 month ago

Source: https://nptscot.github.io/#/clos/#11.16/55.9345/-3.2017

image

Also, other layers not yet working.

joeytalbot commented 1 month ago
  • We should also put the darker high LoS lines 'on top' so they are not partly hidden behind less relevant low LoS lines

The low LoS lines are mostly main roads, and many high LoS lines will be small service or residential roads, so I'd put the low LoS on top.

Robinlovelace commented 1 month ago
  • We should also put the darker high LoS lines 'on top' so they are not partly hidden behind less relevant low LoS lines

The low LoS lines are mostly main roads, and many high LoS lines will be small service or residential roads, so I'd put the low LoS on top.

Are you able to do that on the .JS side or do we need to tweak the code that generates the .pmtiles file?

Cc @wangzhao0217 FYI.

Robinlovelace commented 1 month ago

@mvl22 please do prioritise this. See here for 'viridis' colour scheme I recommend for road traffic volumes:

image

mvl22 commented 1 month ago

Also, other layers not yet working.

These are now in place.

'viridis' colour scheme I recommend for road traffic volumes

This is now in place, though I couldn't quite work out from the image what the colour stops are.

You can adjust the colour definitions in the src/datasets.js values, in the new 'sublayers' definitions (present on the 175-los branch):

https://github.com/nptscot/nptscot.github.io/blob/175-los/src/datasets.js#L143

These will shortly also be used for the legend.

mvl22 commented 1 month ago

Legends are now in place, generated automatically from the same definitions as the colour values.

Screenshot 2024-05-26 at 21 46 50

mvl22 commented 1 month ago

I believe this is all now implemented, pending you updating the colours/stops to whatever you want, at:

https://github.com/nptscot/nptscot.github.io/blob/175-los/src/datasets.js#L143

Note that you can assign more than one style, e.g. line-color and line-width.

Robinlovelace commented 1 month ago

Looking really good, closing for now.