Private
Public Access
1
0
This commit is contained in:
2023-08-25 08:35:07 +02:00
parent 6dda955115
commit 64043efe69
2 changed files with 7 additions and 3 deletions

View File

@@ -359,7 +359,7 @@ def uploadactivity(access_token, filename, description='',
with gzip.GzipFile(fileobj=data_gz, mode="w") as gzf:
gzf.write(s)
except FileNotFoundError:
return 0
return 0, 0, 0, 0
headers = {
'Content-Type': 'application/json',
@@ -2644,8 +2644,12 @@ def handle_makeplot(f1, f2, t, hrdata, plotnr, imagename,
nr_rows = len(row.df)
if (plotnr in [1, 2, 4, 5, 8, 11, 9, 12]) and (nr_rows > 1200): # pragma: no cover
bin = int(nr_rows / 1200.)
df = row.df.groupby(lambda x: x / bin).mean()
row.df = df
try:
df = df.select_types(['number'])
df = row.df.groupby(lambda x: x / bin).mean()
row.df = df
except TypeError:
pass
nr_rows = len(row.df)
if (plotnr == 1):
fig1 = row.get_timeplot_erg(t, pacerange=oterange, **kwargs)

Binary file not shown.