Plotting results - asolis/vivaTracker GitHub Wiki

To facilitate the evaluation and comparison of different trackers, we have included a python script plot.py that takes the ground truth of a sequence and the output of different algorithms and create different plots to analyze the outcome of each algorithm.

NOTE: The script plot.py will be automatically copied by CMake to the Debug and Release folder with the vivaTracker executable

For example, let's assume we execute and save the output of the following trackers: sKCF, KCF, NCC, OpenTLD, and Struck using the vot2014/car sequence. We will create a .txt file for each algorithm.

$./vivaTracker -m=skcf -o=skcf.txt vot2014/car -n
$./vivaTracker -m=ncc -o=ncc.txt vot2014/car -n
$./vivaTracker -m=kcf -o=kcf.txt vot2014/car -n
$./vivaTracker -m=opentld -o=opentld.txt vot2014/car -n
$./vivaTracker -m=struck -o=struck.txt vot2014/car -n

We can analyze the precision, accuracy, and success plots of each algorithm compared to the ground truth for the vot2014/car sequence by executing

$./plot.py vot2014/car skcf.txt ncc.txt kcf.txt opentld.txt struck.txt --plot=accuracy
$./plot.py vot2014/car skcf.txt ncc.txt kcf.txt opentld.txt struck.txt --plot=precision
$./plot.py vot2014/car skcf.txt ncc.txt kcf.txt opentld.txt struck.txt --plot=success

accuracy precision success

Plot.py command line arguments

plot.py [-h] [--plot={accuracy|precision|success}] [--save] ground-truth [outputs ...]

The first file will be considered the ground-truth and the following will be plotted according to the first one.

  1. ground-truth: could be the name of existing sequence in a dataset e.g., vot2014/car or path to a file
  2. outputs: a list of path to files
  3. -h: prints help
  4. --plot: selects the type of plot, choices are accuracy, precision or success
  5. --save: saves the image instead of showing them