Video Annotator guide
The Video Annotator is used to mark when each movement in a test video starts and ends (for example stand, pour water or drink) and saves those times in a YAML file. Each time is saved as real clock time, so it can be matched to the sensor recordings.
Overview
The annotator is a web page: open continuum-tools.pages.dev/annotator in Chrome or Edge. It is part of the same website as the Clinical Log, and there is nothing to install.
- Works with one video (for example an iPhone clip) or with a folder of synchronized cameras.
- Pick the test (the Condition) and the annotator offers the right movement labels for that test.
- Mark each movement frame by frame, or live while the video plays.
- Saves two YAML files per video:
subject_XX_cond_YY_run_ZZ_events.yaml(the movements) and…_Info.yaml(Rec. start and fps).
The screen
On a narrow window the right-hand panels (4 and 5) move below the video.
Opening a video
Data folder (the one with VIDEOS_SPLIT and EUROBENCH_DATA_SPLIT).
It is remembered, also by the Offset Detector. Then Single video… and Load folder…
open in Data/VIDEOS_SPLIT (the clips made by the Video Cutter), the sensor data of the run is found by itself,
and Export YAML saves into Data/EUROBENCH_DATA_SPLIT/SUBJECT_XX/SESSION_YY (Chrome / Edge).One video (for example an iPhone clip)
- Click Single video… and choose the file (
.mov,.mp4…). - The file name appears in the grey pill above the video, Recording is filled with the file name, and Rec. start is read from the video itself when the file has it (see Rec. start).
- Check the fps box (top right of the video). It is 30 by default; change it if the video was recorded at another frame rate.
A folder of synchronized cameras
- Click Load folder… and choose the recording's folder: the
synchronized_videosfolder of a freemocap recording, or a multi-camera recording folder named by its start time such asVIDEOS/SUBJECT_1001/SESSION_01/2026-10-13 12-07-14(withcam0.mp4,cam1.mp4, …). Chrome asks to confirm uploading the folder: this only lets the page read it, nothing is sent anywhere. - Every
Camera_XXX_synchronized.mp4orcamN.mp4becomes a camera. If the folder also has the…_timestamps_human_readable.csvfiles, the cameras are kept frame-synced and the fps is set from them (shown on the right, under the controls: synced · 3 cam · … fps). - Session and Recording are filled from the folder path.
- Switch camera with the Cam 1 Cam 2… tabs or the keys 1–9. ▦ all cameras shows them all side by side; click one to make it the main camera.
To close the video (for example to open the next clip), click the ✕ in its top-right corner. The segments stay.
Recording details
Fill in the Recording metadata panel before exporting. Subject, Condition and Run give the file its name, shown under the panel (Files export as subject_96_cond_09_run_01_events.yaml + _Info.yaml).
| Field | What to enter |
|---|---|
| Subject (XX) | Subject number, e.g. 96. Numbers are padded to two digits (7 → 07). Filled in automatically when the video comes from Data/VIDEOS/SUBJECT_XX/… (or has SUBJECT_XX in its folder or file name). |
| Run (ZZ) | Which repetition of the test this video is, 01 for the first. |
| Condition (COND) | The test shown in the video. Pick it first: it decides which labels you can choose under Mark a segment (see Labels) and the colour of the segments. |
| Session / visit, Recording | Filled automatically when possible; edit if needed. |
| Rater | Your initials. |
| Rec. start, Offset (s) | The clock time of the first frame. See the next section. |
Rec. start and Offset
The annotator turns every marked frame into a real date and time, so that the movements can be found in the sensor data:
event time = Rec. start + time in the video − Offset
- Rec. start is the date and time of the video's first frame, written
YYYY-MM-DD HH:MM:SS(e.g.2026-10-01 10:15:30). It is filled in automatically, and the message under the panel says where it came from:- the folder name, when the recording folder is named by its start time (e.g.
2026-10-13 12-07-14, also with a prefix such asCalibracion_), or for freemocap from thesession_YYYY-MM-DD…andrecording_HH_MM_SS…folders. This is local time, like the sensors. The folder is known when the video is opened through the Data folder or with Load folder…; - otherwise the video file: iPhone videos store the real local capture time; other cameras and OBS store it in UTC, which is converted to this computer's time zone.
- the folder name, when the recording folder is named by its start time (e.g.
- If the message ends in — verify, the time came from a UTC field converted with this computer's time zone (correct only if the video was recorded in the same time zone), or from a field that may be the time the file was copied. Check it and correct it if needed.
- If it says No embedded recording time found, type Rec. start yourself.
- Offset fine-tunes the time, in seconds. Use it when the video clock is slightly off, for example if a movement
that is clearly visible in the sensor data appears 0.4 s later in the video: set Offset to
0.4. A positive Offset moves every event earlier. Measure it with the Offset Detector (guide); leave it at0if you don't know.
Moving through the video
Click or drag on the timeline (the bar under the video) to jump; hovering shows the time under the mouse. The large clock shows the current time in the video and the frame number.
Zoom into the image to see a detail (a hand, a foot): Ctrl+scroll on the video zooms around the mouse, or use − + 1:1 in its bottom-right corner (1:1 shows the whole image again). When zoomed in, drag the image to move around. With several cameras, each keeps its own zoom.
Zoom the timeline to work on a short stretch: scroll on the timeline to zoom in or out around the mouse, Shift+scroll to move earlier or later, or use the − + fit buttons under it (fit shows the whole video again). The time marks under the timeline adapt to the zoom (down to tenths of a second), and a zoomed timeline follows the video while it plays.
| Key | Button | Does |
|---|---|---|
| space | ▶ | Play / pause |
| , . | ◀| |▶ | One frame back / forward |
| ⏪ ⏩ | 10 frames back / forward | |
| ← → | 1 second back / forward | |
| 1–9 | Cam 1… | Switch camera (folder mode) |
| i | Mark start (i) | Set the segment start at the current frame |
| o | Mark end (o) | Set the segment end at the current frame |
| r l b | R L BI | Side of the body of the segment (circuits) |
| Enter | Add segment ⏎ | Save the segment |
Use the speed buttons (0.25× 0.5× 1× 2×) to slow the video down around a movement. Keyboard shortcuts do nothing while the cursor is in a text box: click on the video area first.
Marking events and segments
What you mark depends on the Condition:
- Instant events (TUG, Cognitive TUG, gait, balance, STS, 2MWT, UPDRS): a label at one moment, e.g. start tug, start stand, … end sit. The panel is called Mark an event. Go to the frame and press Enter (or Add event ⏎): the event is added at the current frame and the label moves on to the next one in the list, so a whole TUG (with its two turns) is just “go to the frame, Enter” nine times. To fine-tune a frame first, press i to hold it and use ‹ ›. Instant events show as thin markers on the timeline and as lines in the sensor plot; in the YAML their start and end are the same time.
- Segments (upper- and lower-body circuits): a label with a start and an end, as below.
A segment is one movement: a label with a start and an end. There are two ways to mark one.
Frame by frame (most precise)
- Choose the Label (or type a custom label, which overrides the list).
- Go to the first frame of the movement and press i (Mark start (i)).
- Go to the last frame and press o (Mark end (o)).
- Check the box under the buttons: label, start, end and duration. Use the small ‹ › buttons to move the start or end by one frame. The marked part is also highlighted on the timeline.
- Circuits (09, 10): choose the side of the body, which hand does the task: R right, L left or BI bilateral (both hands); keys r l b, press again to clear. Mark each hand's activity as its own segment: when the right hand pours water while the left one rests, add pour water, R and rest, L over the same time. The side is shown in the box under the buttons and reset after each segment, so it never carries over by mistake; adding a circuit segment without it asks first.
- Optionally fill Trial / rep (e.g.
2for the second repetition) and Notes. - Press Enter or Add segment ⏎.
Live, while the video plays
- Choose the label and play the video (slow it down if it helps).
- Click ● Live mark: start when the movement starts. The button turns red.
- Click ■ Live mark: end when it ends. The segment is added straight away.
Live marking is quick but less precise; you can adjust the segment afterwards (see Checking and fixing).
Labels for each test
The labels offered depend on the Condition. If you need a label that is not in the list, type it in …or custom label.
| Condition | Labels |
|---|---|
| 00 UPDRS | start updrs, end updrs |
| 01 TUG 02 Cognitive TUG | start tug, start stand, end stand, start turn, end turn, start turn, end turn, start sit, end sit (two turns: the list shows the second pair as start turn (2nd), end turn (2nd); they are saved as start turn / end turn) |
| 03 SPPB — Gait | start walk, end walk |
| 04 SPPB — Parallel 05 SPPB — Semi-Tandem 06 SPPB — Tandem | start hold, end hold |
| 07 SPPB — STS | start stand, end stand, start sit, end sit |
| 08 2MWT | start walk, end walk |
| 09 Upper-Body Circuit | stand, walk, sit, put items on tray, pour water, hold tray, add sugar, stir, drink, hold item, rest |
| 10 Lower-Body Circuit | lie down, sit, walk, stand, hold phone, put socks on, put on jacket, rest |
Checking and fixing segments
Every segment appears in the Segments table (sorted by start time) and as a coloured bar on the timeline. Each label has its own colour (shown in the legend under the timeline; rest is always grey), the bars have a dark edge at their start and end, and segments that overlap in time (e.g. pour water, R and rest, L) are drawn on separate rows. The sensor plot uses the same colours, with a line at the start and end of every segment.
- Jump to a segment: click its start time in the table, or click its bar on the timeline.
- ▷ plays just that segment and stops at its end.
- ✎ edits it: the segment is loaded back into Mark a segment (its row turns grey). Change the label, start, end, trial or notes, then press Add segment ⏎ to save the change.
- ✕ deletes it.
- Clear deletes all segments (it asks first).
Sensor data under the video
Optionally, the Sensor data panel (between the video and the Segments table) shows the Axivity signals of the same moment as the video, so you can see the movement in the sensors while you annotate, and check that the segments land on it.
- Fill in Rec. start and Offset (s) (measure the offset with the Offset Detector).
- Fill in Subject, Condition and Run, and click Load sensor data…. The run's split files,
EUROBENCH_DATA_SPLIT/SUBJECT_XX/SESSION_YY/subject_XX_cond_YY_run_ZZ_acceleration.csvand…_velocity.csv, load by themselves when the Data folder is chosen; otherwise the file dialog opens inData/EUROBENCH_DATA_SPLIT: select both files together (Ctrl+click). The split files cover the run's Clinical Log window (the circuits with 5 s on each side), so the plot is empty outside it. - Choose the sensor (
pelvisby default, or a wrist) and the axes to show. The ✕ in the panel's top-right corner closes the sensor data.
- The plot follows the video: the black line is the current frame, placed on the sensor clock at
Rec. start + time in the video − Offset, the same calculation as the exported times. - Every segment is shaded with its label, and the start/end you are marking is shown in orange.
- Click the plot to move the video to that moment. Scroll to zoom (or + −); drag to look elsewhere, which stops following the video until you tick follow video again.
- Changing Offset moves everything immediately. If the movements in the signals sit consistently before or after the shaded segments, the offset is wrong.
Saving: Export and Load YAML
YAML is the only file format the annotator uses. Each video is saved as two files that belong together:
| File | Contains |
|---|---|
subject_XX_cond_YY_run_ZZ_events.yaml | The movements: start and end time of every segment, with trial and notes |
subject_XX_cond_YY_run_ZZ_Info.yaml | The recording information: rec_start, offset and rec_fps |
Export YAML
- Check Subject, Run, Condition and Rec. start.
- Click Export YAML. With the Data folder chosen, both files are saved in
Data/EUROBENCH_DATA_SPLIT/SUBJECT_XX/SESSION_YY/, next to the run's sensor files (the browser asks once to allow editing). The session is the Session field when it readsSESSION_YY, else the subject's only session folder there; otherwise the page asks. Files already there are replaced only after you confirm. - Without a Data folder (or another browser) the two files are downloaded instead. The first time, Chrome or Edge may ask whether the site can download multiple files: click Allow.
Load YAML (continue or check later)
- Open the same video (or folder) as before.
- Click Load YAML and select both files of the video together (Ctrl+click).
Subject, Condition and Run come back from the file name, Rec. start, Offset and fps from the
_Info.yaml, and all segments, with their trial and notes, from the_events.yaml. If segments are already marked, it asks before replacing them. - Make your changes and Export YAML again (it overwrites the old files if you save them with the same names).
If you select only the _events.yaml, the annotator uses the Rec. start already in the panel
(for example, read from the video). You can also load the files before the video; the segments are placed using the fps,
and appear on the timeline once the video is open.
Old JSON files
Earlier versions of the annotator saved .json files. To turn one into YAML, click
Convert it to YAML under the Segments table and choose the JSON. The annotator loads it and
immediately downloads the _events.yaml and _Info.yaml files.
- If the JSON has no Rec. start, the segments are loaded but not exported: type Rec. start (or open the video) and click Export YAML.
- If the JSON was made from a multi-camera folder, open that folder first and then convert, so the times use the cameras' timestamp files.
The YAML files
You do not need to edit them, but this is what they contain.
_events.yaml
Under movements each label has its start and end times (in order, so the first start goes with the
first end), plus the trial and notes of each occurrence and, for the circuits, the laterality (R / L / BI).
All times are clock times on the sensor clock.
movements:
'pour water':
movement_start:
- '2026-10-01 10:15:35.000'
movement_end:
- '2026-10-01 10:15:39.000'
trial:
- '1'
notes:
- ''
The analysis notebook reads movement_start and movement_end; trial
and notes are kept so that Load YAML restores everything.
_Info.yaml
rec_start: '2026-10-01 10:15:30.000'
offset: -0.4
rec_fps: 30
rec_start: the Rec. start field, i.e. the clock time of the video's first frame on the video's own (iPhone) clock.offset: the Offset (s) field. On the sensor clock the first frame is atrec_start − offset.rec_fps: frame rate of the video (the fps box).
Files saved before 14 October 2026 have no offset line: their rec_start already had the
offset applied, so they load with Offset 0 and the same times.
Subject, condition and run are not repeated inside the files: they are in the file names.
Checklist
- Video plays (no warning on the video).
- Condition picked first; Subject and Run filled.
- Rec. start present and checked (especially if marked UTC — verify).
- Every movement marked; overlap warnings checked.
- Segments reviewed with ▷.
- Export YAML clicked and both files (
_events.yaml,_Info.yaml) saved inData/EUROBENCH_DATA_SPLIT/SUBJECT_XX/SESSION_YY/.
Troubleshooting
| Problem | What to do |
|---|---|
| The video is black, or shows browser can't decode this file / codec not supported | The video is in a format the browser cannot play (usually HEVC / H.265). For a synchronized_videos
folder, run Code/video_annotator/transcode_for_annotator.py on it; it makes a browser-playable
synchronized_videos_h264 copy with exactly the same frames. Load that folder instead. |
| Load folder… does nothing or the folder can't be chosen | Use Chrome or Edge. Choose the synchronized_videos folder itself. |
| No "Camera_XXX_synchronized.*" videos found | You picked the wrong folder: it must contain the Camera_…_synchronized.mp4 files. |
| The label list says — pick a condition first — | Choose the Condition in Recording metadata. |
| Export YAML says Event datetimes need a Rec. start | Type Rec. start as YYYY-MM-DD HH:MM:SS. |
| Keys like i or space don't work | The cursor is in a text box. Click on the video or an empty area of the page first. |
| The times look shifted compared with the sensors | Check Rec. start, then adjust Offset and export again. |
| Only one of the two files was downloaded | The browser blocked the second download. Allow multiple downloads for the site (icon at the right of the address bar) and click Export YAML again. |
| Load YAML: No Rec. start | Select the _events.yaml and its _Info.yaml together (Ctrl+click), or open the video first. |
Clinical Log users: see the Clinical Log guide.
