Skip to content

Commit

Permalink
show_events
Browse files Browse the repository at this point in the history
  • Loading branch information
Ipuch committed Jun 28, 2024
1 parent 96a9aea commit 8adebe5
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion pyorerun/rrc3d.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ def rrc3d(
show_floor: bool = True,
show_force_plates: bool = True,
show_forces: bool = True,
show_events: bool = True,
down_sampled_forces: bool = False,
video: str | tuple[str, ...] = None,
video_crop_mode: str = "from_c3d",
Expand All @@ -35,6 +36,8 @@ def rrc3d(
If True, show the force plates.
show_forces: bool
If True, show the forces.
show_events: bool
If True, show the events, as log entries.
down_sampled_forces: bool
If True, down sample the force data to align with the marker data.
If False, the force data will be displayed at their original frame rate, It may get slower when loading the data.
Expand Down Expand Up @@ -113,7 +116,12 @@ def rrc3d(
multi_phase_rerun = MultiFrameRatePhaseRerun(phase_reruns)
multi_phase_rerun.rerun(filename, notebook=notebook)

set_event_as_log(c3d_file)
if show_events:
try:
set_event_as_log(c3d_file)
except:
raise NotImplementedError("The events feature is still experimental and may not work properly. "
"Set show_events=False.")

if marker_trajectories:
# todo: find a better way to display curves but hacky way ok for now
Expand Down

0 comments on commit 8adebe5

Please sign in to comment.