Spaces:
Runtime error
Runtime error
Commit ·
cf90a22
1
Parent(s): d744c30
update mark thresh
Browse files
app.py
CHANGED
|
@@ -52,7 +52,7 @@ def sigmoid(x):
|
|
| 52 |
@spaces.GPU()
|
| 53 |
def inference(x, count_only_api, api_key,
|
| 54 |
img_size=288, seq_len=64, stride_length=32, stride_pad=3, batch_size=4,
|
| 55 |
-
miss_threshold=0.8, marks_threshold=0.
|
| 56 |
api_call=False,
|
| 57 |
progress=gr.Progress()):
|
| 58 |
progress(0, desc="Starting...")
|
|
@@ -259,7 +259,7 @@ def inference(x, count_only_api, api_key,
|
|
| 259 |
'event_type': per_frame_event_types,
|
| 260 |
'jumps': full_marks,
|
| 261 |
'jumps_size': (full_marks + 0.05) * 10,
|
| 262 |
-
'miss_size': np.clip((1 - periodicity) * 0.9 + 0.1, 1,
|
| 263 |
'seconds': np.linspace(0, seconds, num=len(periodLength))})
|
| 264 |
event_type_tick_vals = np.linspace(0, 1, num=7)
|
| 265 |
event_type_colors = ['red', 'orange', 'green', 'blue', 'purple', 'pink', 'black']
|
|
@@ -270,7 +270,7 @@ def inference(x, count_only_api, api_key,
|
|
| 270 |
#symbol_map={'frame': 'circle', 'miss': 'circle-open', 'jump': 'triangle-down'},
|
| 271 |
color='event_type',
|
| 272 |
size='jumps_size',
|
| 273 |
-
size_max=
|
| 274 |
color_continuous_scale=[(t, c) for t, c in zip(event_type_tick_vals, event_type_colors)],
|
| 275 |
range_color=(0,1),
|
| 276 |
title="Jumping speed (jumps-per-second)",
|
|
|
|
| 52 |
@spaces.GPU()
|
| 53 |
def inference(x, count_only_api, api_key,
|
| 54 |
img_size=288, seq_len=64, stride_length=32, stride_pad=3, batch_size=4,
|
| 55 |
+
miss_threshold=0.8, marks_threshold=0.5, median_pred_filter=True, center_crop=True, both_feet=True,
|
| 56 |
api_call=False,
|
| 57 |
progress=gr.Progress()):
|
| 58 |
progress(0, desc="Starting...")
|
|
|
|
| 259 |
'event_type': per_frame_event_types,
|
| 260 |
'jumps': full_marks,
|
| 261 |
'jumps_size': (full_marks + 0.05) * 10,
|
| 262 |
+
'miss_size': np.clip((1 - periodicity) * 0.9 + 0.1, 1, 8),
|
| 263 |
'seconds': np.linspace(0, seconds, num=len(periodLength))})
|
| 264 |
event_type_tick_vals = np.linspace(0, 1, num=7)
|
| 265 |
event_type_colors = ['red', 'orange', 'green', 'blue', 'purple', 'pink', 'black']
|
|
|
|
| 270 |
#symbol_map={'frame': 'circle', 'miss': 'circle-open', 'jump': 'triangle-down'},
|
| 271 |
color='event_type',
|
| 272 |
size='jumps_size',
|
| 273 |
+
size_max=8,
|
| 274 |
color_continuous_scale=[(t, c) for t, c in zip(event_type_tick_vals, event_type_colors)],
|
| 275 |
range_color=(0,1),
|
| 276 |
title="Jumping speed (jumps-per-second)",
|