- Introduction
- Prerequisites
- Upload files, and Settings of Keypoints and Lines
- Manual Annotation
- CSV Input Format
- Output Format
- CSV Output Format
The following mechanism allows admin to manually annotate videos and save their annotation as csv and compare it to the OpenPose library performance.
- You must have Python3 installed.
- Run in the terminal/command line from the
/testing
directory the following command:pip install -r requirements.txt
- Video files must be .mov format only.
- Working with existing CSV files must be done with csvs stand in the input format
-
Run in the terminal/command line from the
/testing
directory the following commandpython test_generator.py
. -
Press on "Load Video" button in order to load a MOV video.
-
[Optional] : Press on "Load CSV" button in order to load existing csv file with keypoints with the given format
-
[Optional] : Press on "Default Settings" in order to load the default key points and lines settings (Based on our relevant keypoints for analysis process).
Note: In this case you will not be able to define keypoints and lines by yourself or load CSV file, so you can continue to (7)
-
Insert records to body parts table. This table includes the following : Name of body part , x coordinate for current frame and y one.
In this level, just type the body parts you want to include in your test. Insertion of new body part line record are done by pressing "Insert Row".
Applying is done by pressing the "Finish define table" button. -
At the bottom of the window you can find a drop down list to define lines between 2 body parts you want to include as a line in every frame. Insertion of new line record is done by the "Add" button.
Applying is done by pressing "Finish line definition" button. -
If all the steps above were done right- the first frame of the loaded video should appear.
You can now move between the frames of the loaded movie (Prev and Next buttons).
Getting the keypoints coordinates is done as follows:
A. By default- the first body part to be taken is the first one appears in the body parts list defined before, unless you have defined otherwise (by pressing the desired body part row as shown in B).
B. Selection of a specific keypoint is done by selecting the corresponding line of the desired keypoint.
C. Annotating a keypoint is done by clicking on the desired location on the frame.
Note 1: By default, the next keypoint to be annotated is the one appears next on the keypoints list. Note 2: Once finished annotating all frames of a given movie - the tool will be closed automatically.
D. Moving to the next or the previous frame is done by "Next" and "Prev" buttons respectively.
Note: both buttons saves the information got from the current frame.
E. Clearing the last annotation is done by pressing "Undo" button.
F. Clearing all the annotations of the current frame is done by pressing "Clean all" button.
"Load video" button - loads other video. Working with the new video is done by following this guide again.
Important Note 1: choosing this option will delete accumulated data. Make sure you saved the data you generated before! Important Note 2: Clicking the red "X" button will terminate the tool and also delete accumulated data. Make sure you saved the data you generated before!
H. Save button - Saves all the generated annotation up to this point. See output section.
There is an expected format for the csv file. The csv must include the following columns :
Frame Number , <body_part>* s.t <body_part> := <body_part>_X , <body_part>_Y
The following files are saved as an output of the program in the working directory (i.e in test folder):
- A file in a MOV format named by the given file with the keypoints annotations according to your manual annotations.
- A file in a CSV format with the keypoints coordinates you annotated for each frame. Please read CSV Output section.
The CSV output format is as follows: You will have for each frame number the X and Y coordinated for each body part mentioned in body parts table in the program.