Private
Public Access
1
0
This commit is contained in:
Sander Roosendaal
2019-03-07 14:27:40 +01:00
parent 9f73e37297
commit f53a2a22ee
5 changed files with 38 additions and 18 deletions

View File

@@ -415,9 +415,9 @@ def createc2workoutdata(w):
p = np.clip(p,0,3600)
if w.workouttype == 'bike':
p = 2.0*p
t = t.astype(int)
d = d.astype(int)
p = p.astype(int)
# t = t.astype(int)
# d = d.astype(int)
# p = p.astype(int)
spm = row.df[' Cadence (stokes/min)'].astype(int)
spm[0] = spm[1]
try:
@@ -425,12 +425,19 @@ def createc2workoutdata(w):
except ValueError:
hr = 0*d
stroke_data = []
t = t.tolist()
d = d.tolist()
p = p.tolist()
spm = spm.tolist()
hr = hr.tolist()
for i in range(len(t)):
thisrecord = {"t":t[i].astype(int),
"d":d[i].astype(int),
"p":p[i].astype(int),
"spm":spm[i].astype(int),
"hr":hr[i].astype(int)}
thisrecord = {"t":t[i],
"d":d[i],
"p":p[i],
"spm":spm[i],
"hr":hr[i]}
stroke_data.append(thisrecord)
try: