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).
build-essentia, cmake, g++, libgoogle-glog-dev, libgsl0-dev, git, libgtest-dev, libboost-program-options-dev
$ sudo apt-get install build-essential cmake g++ libgoogle-glog-dev libgsl0-dev git libgtest-dev libboost-program-options-dev
$ cd /path/to/dev # your preferred location
$ git clone https://github.com/AutonomyLab/obzerver
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
$ cd /path/to/dev/obzerver
$ mkdir build && cd build
$ cmake .. -DCMAKE_PREFIX_PATH=$OPENCV_INSTALL_PREFIX -DCMAKE_BUILD_TYPE=RelWithDebInfo -DWITH_TESTS=1
$ make
$ make test # optional, very low coverage
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
stablization
--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)
./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/datasetSet
DEMO
variable according to the path of your local build.