Change traffic CSV field value from weight to rate

and make the value required.

If the weight name is 'duration' than the rate value
can be computed as speed / 3.6

Issue: https://github.com/Project-OSRM/osrm-backend/issues/3823
This commit is contained in:
Michael Krasnyk
2017-04-10 16:44:48 +02:00
committed by Patrick Niklaus
parent a88fef2937
commit 37794a5e8a
6 changed files with 68 additions and 56 deletions
+2 -2
View File
@@ -49,9 +49,9 @@ struct Segment final
struct SpeedSource final
{
SpeedSource() : speed(0), weight(std::numeric_limits<double>::quiet_NaN()) {}
SpeedSource() : speed(0), rate(std::numeric_limits<double>::quiet_NaN()) {}
unsigned speed;
double weight;
double rate;
std::uint8_t source;
};