no consistency checks on data fusion
This commit is contained in:
@@ -398,7 +398,8 @@ def save_workout_database(f2,r,dosmooth=True,workouttype='rower',
|
|||||||
notes='',totaldist=0,totaltime=0,
|
notes='',totaldist=0,totaltime=0,
|
||||||
summary='',
|
summary='',
|
||||||
makeprivate=False,
|
makeprivate=False,
|
||||||
oarlength=2.89,inboard=0.88):
|
oarlength=2.89,inboard=0.88,
|
||||||
|
consistencychecks=True):
|
||||||
message = None
|
message = None
|
||||||
powerperc = 100*np.array([r.pw_ut2,
|
powerperc = 100*np.array([r.pw_ut2,
|
||||||
r.pw_ut1,
|
r.pw_ut1,
|
||||||
@@ -417,9 +418,12 @@ def save_workout_database(f2,r,dosmooth=True,workouttype='rower',
|
|||||||
for key,value in checks.iteritems():
|
for key,value in checks.iteritems():
|
||||||
if not value:
|
if not value:
|
||||||
allchecks = 0
|
allchecks = 0
|
||||||
a_messages.error(r.user,'Failed consistency check: '+key+', autocorrected')
|
if consistencychecks:
|
||||||
|
a_messages.error(r.user,'Failed consistency check: '+key+', autocorrected')
|
||||||
|
else:
|
||||||
|
a_messages.error(r.user,'Failed consistency check: '+key+', not corrected')
|
||||||
|
|
||||||
if not allchecks:
|
if not allchecks and consistencychecks:
|
||||||
row.repair()
|
row.repair()
|
||||||
|
|
||||||
|
|
||||||
@@ -780,7 +784,8 @@ def new_workout_from_df(r,df,
|
|||||||
oarlength=oarlength,
|
oarlength=oarlength,
|
||||||
inboard=inboard,
|
inboard=inboard,
|
||||||
makeprivate=makeprivate,
|
makeprivate=makeprivate,
|
||||||
dosmooth=False)
|
dosmooth=False,
|
||||||
|
consistencychecks=False)
|
||||||
|
|
||||||
|
|
||||||
return (id,message)
|
return (id,message)
|
||||||
|
|||||||
Reference in New Issue
Block a user