Average Speed for every roadsection

77 views
Skip to first unread message

Casper Wassar Skourup

unread,
Mar 18, 2022, 10:56:56 AM3/18/22
to road.digitraffic.fi
Hello Guys
I am currently working on creating a database with information about roads in Finland and im trying to use your api to do so. I want the following to my database (every row in the database is a road or a roadsection with the following columns):

roadMaintenanceClass 
freeFlowSpeed1 
roadTemperature 
daylight
weatherSymbol
averageSpeed

I can see that i properbly need to use the following 
but it does not seem like there is data on every road/roadsections.

Also, I can see that some of the road ID's and road section ID's does not correspond in 

How do i get information for every road/roadsection, and how do I ensure that all the information corresponds?

Thank you in advance.

With best regards
Casper

Digitraffic support / Solita / Jouni

unread,
Mar 21, 2022, 10:03:56 AM3/21/22
to road.digitraffic.fi
Hi and thanks for the question.

We don't have TMS stations on every roads/sections so you can't get information for each of them. To get an idea how they are located on map, you can use some map service ie. this: https://geojson.tools/?url=https://tie.digitraffic.fi/api/v3/metadata/tms-stations 

The road conditions are coming from different source and are only forecasts (not measurements from stations), so they don't map directly to TMS-stations as there is no stations for them.

Also Digitraffic doesn't include information of the road network so you need to get the data elsewhere ie. from Digiroad https://vayla.fi/en/transport-network/data/digiroad/documents. You can also use 

From road conditions api https://tie-test.digitraffic.fi/swagger/#/Data%20v3/roadConditionsUsingGET_4 you can take road, section and distance. Ie for https://tie.digitraffic.fi//api/v3/data/road-conditions/78 "id": "00078_119_00000_0_0"
Road number 5 characters ie. 78,
Road section 3 characters ie. 119,
Start distance 5 characters ie. 0

And use it on https://vayla.fi/en/transport-network/data/open-data/api Viitekehysmuunnin (VKM) https://avoinapi.vaylapilvi.fi/viitekehysmuunnin/swagger-ui.html#/viitekehysmuunnin-palvelu-controller/yleisRajapintaUsingGET 
Like https://geojson.tools/?url=https://avoinapi.vaylapilvi.fi/viitekehysmuunnin/muunna?tie=78&osa=119&etaisyys=0&valihaku=false&palautusarvot=5 You get geometry in ETRSTM35FIN coordinates. 
"coordinates": [
  530107.672,
  7226828.252
]


I hope this helps you forward. Don't hesitate to ask if there is something more you need to know.


Ystävällisin terveisin / Best regards
– Digitraffic asiakastuki / Digitraffic support –

Casper Wassar Skourup

unread,
Apr 25, 2022, 10:10:37 AM4/25/22
to road.digitraffic.fi
Hello Again 

So I'm having some trouble using the VKM API, and I would like to know how you would approach this task. 
I want to get the speed limit on for example id:" 00078_119_00000_0_0". 

Right now I have downloaded the bucket with speed limits and has a CSV with the following column names: 
OBJECTID, S_NOPRAJ, NOPRALA, S_NOPRALA, NOPTAAJA, S_NOPTAAJA, ID, MUUTOSPVM, UALUE, S_UALUE, LIVA, KUNTAKOODI, KUNTA, MAAKUNTAKO, MAAKUNTA, LAANI, ELY, TIE, LAKKAUTPVM, AJR, AOSA, AET, LOSA, LET,PUOLI, ALKUPVM, LOPPUPVM, NOPRAJ. But i do not know how to couple the CSV with the id: 00078_119_00000_0_0?

Is there a better way to do this? 
Also, do you know if there is some English documentation? 

Best regards Casper

road.digitraffic.fi

unread,
Apr 26, 2022, 8:25:57 AM4/26/22
to road.digitraffic.fi
Hi,

can you provide link to CSV file, so we can look in to it? It seems like you could use ROAD number 78 to match TIE-column and ROAD SECTION 119 to match between start road section = AOSA-column and end road section = LOSA-column, but I can be wrong :)

Ystävällisin terveisin / Best regards
– Digitraffic asiakastuki / Digitraffic support –

Casper Wassar Skourup

unread,
Apr 28, 2022, 9:41:33 AM4/28/22
to road.digitraffic.fi
Hello,

Yes it could look like it has a connection there. Here is the csv-file. I have deleted a lot of lines, since the file was too large. But this will give an idea of how it looks.

Best Regards Casper

SmallSpeedlimit.csv

road.digitraffic.fi

unread,
May 9, 2022, 9:46:35 AM5/9/22
to road.digitraffic.fi
Hi,

sorry for the late answer. I checked the file and I think what I said earlier should be correct and then you could pick up the speed limit from column NOPRAJ. You can go to the Väylä's Road Register -page (only in Finnish) and open the PDF-document of Road Register Content Description (Tietosisällön kuvaus). There is "168 NOPEUSRAJOITUS" on pages 54-56 that explains the meaning of the speed limit columns. You can find others columns there too. Unfortunately those are in Finnish only, but I think translate works pretty good for the texts.

It seems that the csv-file has integers as decimal numbers and those should be converted to integers to make it easier to look and filter the data. Can you provide link etc. how you fetch the that data? I assume you got it from the tierekisteri (road register)?

Ystävällisin terveisin / Best regards
– Digitraffic asiakastuki / Digitraffic support –

Reply all
Reply to author
Forward
0 new messages