Obzerver Supplementary software for paper "UAV, Do You See Me?", IROS 2015


obzerver is the core computer vision component of the pipeline described in the following paper for detecting stationary arm waving (periodic) gestures from an airborne UAV (quadrocopter).

"UAV, Do You See Me? Establishing Mutual Attention Between an Uninstrumented Human and an Outdoor UAV In Flight"
Mani Monajjemi and Jake Bruce and Seyed Abbas Sadat and Jens Wawerla and Richard T. Vaughan.
Proceedings of the IEEE International Conference on Intelligent Robots and Systems (IROS'15), Hamburg, Germany 2015
 BIB   PDF  Code

How to Compile


$ sudo apt-get install build-essential cmake g++ libgoogle-glog-dev libgsl0-dev git libgtest-dev libboost-program-options-dev

Clone the source repository

$ cd /path/to/dev # your preferred location
$ git clone https://github.com/AutonomyLab/obzerver

Compile OpenCV from source

Although it's possible to compile obzerver against pre-built OpenCV library, it's recommended to build OpenCV from source with all optimizations enabled. To build OpenCV from source (and if you are using Ubuntu, Debian or Mint), you can use the provided build script (scripts/build-opencv.sh) as follows. The script downloads, compiles and installs OpenCV in the directory that it's called from. OpenCV compile flags are optimized for Intel Core iX processors. Feel free to modify the script if your target system is different.
$ mkdir thirdparty/opencv
$ cd thirdparty/opencv
$ source ../../scripts/build-opencv.sh

Compile libobzerver and demo application

$ cd /path/to/dev/obzerver
$ mkdir build && cd build
$ make
$ make test # optional, very low coverage


libobzerver Classes


Demo Application

The demo application (build/demo) is an app that demonstrated how to use components of libobzerver to detect stationary periodic motions in a video stream. PeriodicityApp Configurations can also be set from an INI configuration file.
$ ./build/demo --help

Generic Options:
  -h [ --help ]                        Show help
  -v [ --video ] arg                   Video file
  --downsample arg (=1)                Downsample (resize) factor (0.5: half)
  -c [ --config ] arg                  Configuration File (INI)
  -d [ --display ]                     Show visualization
  --viz.features                       Visualize Features
  --viz.rois                           Visualize ROIS
  --viz.tracks                         Visualize Tracks
  -c [ --clear ]                       Clear Terminal
  -p [ --pause ]                       Start in pause mode
  -l [ --logfile ] arg                 specify log file (empty: log to stderr)
  -k [ --skip ] arg (=0)               Starting frame
  -e [ --eval.enabled ]                Evaluation (Experiment/Decistion) mode
  --eval.file arg (=/tmp/obzerver.png) Image file to dump the decision bounding
                                       box to
  --loop                               loop video

PeriodicityApp Configuration:
  -h [ --history ] arg (=120)           Length of history (frames)
  --fps arg (=30)                       frames per second
  --eval.f_low arg (=0.899999976)       Decision min frequency
  --eval.f_high arg (=3.0999999)        Decision max frequency
  --eval.min_frames arg (=5)            Minimum number of consequtive positive 
                                        hits before making the decision
  --icf.cascade arg                     icf cascade file
  --stablize.numfeatures arg (=300)     Number of features to track for 
  --stablize.ffd_threshold arg (=30)    Fast Feature Detector threshold
  --stablize.pylk_winsize arg (=30)     Size of search window size for pylk
  --stablize.pylk_iters arg (=30)       Number of iterations for pylk
  --stablize.pylk_eps arg (=0.01)       pylk eps criteria
  --dbscan.eps arg (=0.040000000000000001)
                                        DBScan Threshold (0,1) 
  --dbscan.min_elements arg (=10)       in number of cluster members
  --dbscan.threads arg (=2)             DBScan OpenMP Threads
  --roi.min_motion_ppx arg (=0.00999999978)
                                        Min sum(diff(roi))/roi.size() to accept
                                        the ROI
  --roi.min_motion_pft arg (=40)        Min diff value for a feature point to 
                                        be considered for clustering
  --roi.min_flow_ppx arg (=0.100000001) Min sum(|flow(roi)|/roi.size() to 
                                        accept the ROI
  --roi.inflation_width arg (=0.75)     How much to inflate the width of and 
                                        extracted and accepted ROI (0.5: 0.25 
                                        increase for each side
  --roi.inflation_height arg (=0.5)     How much to inflate the height of an 
                                        extracted and accepted ROI (0.5: 0.25 
                                        increase for each side
  --mot.method arg (=0)                 Periodicity Detection Method 0: 
                                        SelfSimilarity 1: Average Diff Motion
  --mot.max_skipped_frames arg (=30)    Maximum number of non-matching 
                                        obzervation before deleting a track
  --mot.max_matching_cost arg (=100)    Maximum tolerable eucledian distance 
                                        when mathcing tracks and observations 
                                        (in pixels)


Run the demo on a waving person file from UCG ARG dataset:
./build/demo -v /path/to/arg/aerial/waving/video.avi --config ./config/ucf_arg.ini -d --viz.features --viz.tracks --viz.rois


scripts/run-dataset.sh /path/to/config/file /path/to/dataset
Set DEMO variable according to the path of your local build.