fix get_duration
This commit is contained in:
parent
c08a3a4f4e
commit
90bd98c0fa
1 changed files with 2 additions and 2 deletions
|
@ -545,9 +545,9 @@ class RouterWayType:
|
||||||
|
|
||||||
def get_duration(self, edge, walk_factor):
|
def get_duration(self, edge, walk_factor):
|
||||||
if edge.rise > 0:
|
if edge.rise > 0:
|
||||||
duration = edge.distance / (float(self.speed_up) * walk_factor)
|
duration = edge.distance / (float(self.speed_up if self.src else 1) * walk_factor)
|
||||||
else:
|
else:
|
||||||
duration = edge.distance / (float(self.speed) * walk_factor)
|
duration = edge.distance / (float(self.speed if self.src else 1) * walk_factor)
|
||||||
duration += self.extra_seconds
|
duration += self.extra_seconds
|
||||||
return duration
|
return duration
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue