Private
Public Access
1
0
This commit is contained in:
Sander Roosendaal
2018-07-12 12:59:26 +02:00
parent 24aef2c92a
commit 3ddac6573a

View File

@@ -206,9 +206,16 @@ def summaryfromsplitdata(splitdata,data,filename,sep='|'):
maxhr = data['heart_rate']['max']
except KeyError:
maxhr = 0
avgpace = 500.*totaltime/totaldist
restpace = 500.*resttime/restdistance
try:
avgpace = 500.*totaltime/totaldist
except (ZeroDivisionError,OverflowError):
avgpace = 0.
try:
restpace = 500.*resttime/restdistance
except (ZeroDivisionError,OverflowError):
restpace = 0.
velo = totaldist/totaltime
avgpower = 2.8*velo**(3.0)