added physics dept note taking
This commit is contained in:
@@ -1585,13 +1585,13 @@ def interactive_cpchart(rower,thedistances,thesecs,theavpower,
|
||||
background_fill_color='white',
|
||||
text_color='black')
|
||||
)
|
||||
plot.add_layout(
|
||||
Label(x=100,y=120,x_units='screen',y_units='screen',
|
||||
text='Stayer Score (6min) '+str(stayerscore2)+'%',
|
||||
background_fill_alpha=0.7,
|
||||
background_fill_color='white',
|
||||
text_color='black')
|
||||
)
|
||||
# plot.add_layout(
|
||||
# Label(x=100,y=120,x_units='screen',y_units='screen',
|
||||
# text='Stayer Score (6min) '+str(stayerscore2)+'%',
|
||||
# background_fill_alpha=0.7,
|
||||
# background_fill_color='white',
|
||||
# text_color='black')
|
||||
# )
|
||||
|
||||
cpdata = dataprep.fetchcperg(rower, theworkouts)
|
||||
|
||||
@@ -1640,25 +1640,26 @@ def interactive_cpchart(rower,thedistances,thesecs,theavpower,
|
||||
plot.line('duration','power',source=sourcepaul,legend="Paul's Law")
|
||||
plot.line('duration','power',source=sourcecomplex,legend="CP Model",
|
||||
color='green')
|
||||
plot.line('duration','fitpowerwc',source=sourcecomplex,
|
||||
legend="World Class",
|
||||
color='Maroon',line_dash='dotted')
|
||||
if p1wc is not None:
|
||||
plot.line('duration','fitpowerwc',source=sourcecomplex,
|
||||
legend="World Class",
|
||||
color='Maroon',line_dash='dotted')
|
||||
|
||||
plot.line('duration','fitpowerexcellent',source=sourcecomplex,
|
||||
legend="90% percentile",
|
||||
color='Purple',line_dash='dotted')
|
||||
plot.line('duration','fitpowerexcellent',source=sourcecomplex,
|
||||
legend="90% percentile",
|
||||
color='Purple',line_dash='dotted')
|
||||
|
||||
plot.line('duration','fitpowergood',source=sourcecomplex,
|
||||
legend="75% percentile",
|
||||
color='Olive',line_dash='dotted')
|
||||
plot.line('duration','fitpowergood',source=sourcecomplex,
|
||||
legend="75% percentile",
|
||||
color='Olive',line_dash='dotted')
|
||||
|
||||
plot.line('duration','fitpowerfair',source=sourcecomplex,
|
||||
legend="50% percentile",
|
||||
color='Gray',line_dash='dotted')
|
||||
plot.line('duration','fitpowerfair',source=sourcecomplex,
|
||||
legend="50% percentile",
|
||||
color='Gray',line_dash='dotted')
|
||||
|
||||
plot.line('duration','fitpoweraverage',source=sourcecomplex,
|
||||
legend="25% percentile",
|
||||
color='SkyBlue',line_dash='dotted')
|
||||
plot.line('duration','fitpoweraverage',source=sourcecomplex,
|
||||
legend="25% percentile",
|
||||
color='SkyBlue',line_dash='dotted')
|
||||
|
||||
|
||||
script, div = components(plot)
|
||||
|
||||
@@ -422,11 +422,16 @@ def handle_otwsetpower(self,f1, boattype, weightvalue,
|
||||
|
||||
progressurl += "/rowers/record-progress/"
|
||||
progressurl += job_id
|
||||
|
||||
# determine cache file name
|
||||
physics_cache = 'media/'+str(boattype)+'_'+str(int(weightvalue))
|
||||
|
||||
|
||||
rowdata.otw_setpower_silent(skiprows=5, mc=weightvalue, rg=rg,
|
||||
powermeasured=powermeasured,
|
||||
progressurl=progressurl,
|
||||
secret=secret
|
||||
secret=secret,
|
||||
usetable=True,storetable=physics_cache,
|
||||
)
|
||||
|
||||
# save data
|
||||
|
||||
@@ -7306,7 +7306,7 @@ def workout_stats_view(request,id=0,message="",successmessage=""):
|
||||
# Normalized power & TSS
|
||||
duration = datadf['time'].max()-datadf['time'].min()
|
||||
duration /= 1.0e3
|
||||
pwr4 = datadf['power']**(4)
|
||||
pwr4 = datadf['power']**(4.0)
|
||||
normp = (pwr4.mean())**(0.25)
|
||||
if not np.isnan(normp):
|
||||
ftp = float(r.ftp)
|
||||
|
||||
Reference in New Issue
Block a user