Skip to content

Commit 54e6f08

Browse files
committed
use_simple_model argument (faster but no muscles or flexible spine)
1 parent cdd80ec commit 54e6f08

File tree

4 files changed

+4
-5
lines changed

4 files changed

+4
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -446,7 +446,7 @@ sports2d --help
446446
'do_ik': ["", "do inverse kinematics. false if not specified"],
447447
'use_augmentation': ["", "Use LSTM marker augmentation. false if not specified"],
448448
'feet_on_floor': ["", "offset marker augmentation results so that feet are at floor level. true if not specified"],
449-
'use_contacts_muscles': ["", "Use model with contact spheres and muscles. false if not specified"],
449+
'use_simple_model': ["", "IK 10+ times faster, but no muscles or flexible spine. false if not specified"],
450450
'participant_mass': ["", "mass of the participant in kg or none. Defaults to 70 if not provided. No influence on kinematics (motion), only on kinetics (forces)"],
451451
'close_to_zero_speed_m': ["","Sum for all keypoints: about 50 px/frame or 0.2 m/frame"],
452452
'tracking_mode': ["", "'sports2d' or 'deepsort'. 'deepsort' is slower, harder to parametrize but can be more robust if correctly tuned"],

Sports2D/Demo/Config_demo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ filter_type = 'butterworth' # butterworth, gaussian, LOESS, median
152152
do_ik = false # Do scaling and inverse kinematics?
153153
use_augmentation = false # true or false (lowercase) # Set to true if you want to use the model with augmented markers
154154
feet_on_floor = false # true or false (lowercase) # Set to false if you want to use the model with feet not on the floor (e.g. running, jumping, etc.)
155-
use_contacts_muscles = true # true or false (lowercase) # If true, contact spheres and muscles are added to the model
155+
use_simple_model = false # true or false # >10 times faster IK if true. No muscles, no constraints (eg stiff spine and shoulders, no patella)
156156
participant_mass = [55.0, 67.0] # kg # defaults to 70 if not provided. No influence on kinematics (motion), only on kinetics (forces)
157157
right_left_symmetry = true # true or false (lowercase) # Set to false only if you have good reasons to think the participant is not symmetrical (e.g. prosthetic limb)
158158

Sports2D/Sports2D.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@
243243
'kinematics':{'do_ik': False,
244244
'use_augmentation': False,
245245
'feet_on_floor': False,
246-
'use_contacts_muscles': True,
246+
'use_simple_model ': True,
247247
'participant_mass': [55.0, 67.0],
248248
'right_left_symmetry': True,
249249
'default_height': 1.70,
@@ -297,7 +297,7 @@
297297
'do_ik': ["", "do inverse kinematics. false if not specified"],
298298
'use_augmentation': ["", "Use LSTM marker augmentation. false if not specified"],
299299
'feet_on_floor': ["", "offset marker augmentation results so that feet are at floor level. true if not specified"],
300-
'use_contacts_muscles': ["", "Use model with contact spheres and muscles. false if not specified"],
300+
'use_simple_model ': ["", ">10 times faster IK if true. No muscles, no constraints (eg stiff spine and shoulders, no patella). false if not specified"],
301301
'participant_mass': ["", "mass of the participant in kg or none. Defaults to 70 if not provided. No influence on kinematics (motion), only on kinetics (forces)"],
302302
'close_to_zero_speed_m': ["","Sum for all keypoints: about 50 px/frame or 0.2 m/frame"],
303303
'tracking_mode': ["", "'sports2d' or 'deepsort'. 'deepsort' is slower, harder to parametrize but can be more robust if correctly tuned"],

Sports2D/process.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1735,7 +1735,6 @@ def process_fun(config_dict, video_file, time_range, frame_rate, result_dir):
17351735
all_frames_scores_homog = all_frames_scores_homog[...,new_keypoints_ids]
17361736

17371737
frame_range = [0,frame_count] if video_file == 'webcam' else frame_range
1738-
print(frame_range)
17391738
all_frames_time = pd.Series(np.linspace(frame_range[0]/fps, frame_range[1]/fps, frame_count-frame_range[0]), name='time')
17401739
if load_trc_px:
17411740
selected_persons = [0]

0 commit comments

Comments
 (0)