- Install dlib library:
- Download the latest library archive-release
- Extract it
- cd /dlib
- mkdir build
- cd build
- cmake . .
- make -j4
- sudo make install
- Install OpenCV library:
- Install dependencies (maybe you'll need more. Shell'll recommend it if it's necessary): sudo apt-get install python-dev python3-dev libgphoto2-dev python3-numpy python-numpy libv4l-dev libv4l2rds0 libgtk-3-dev libgstreamer-plugins-base1.0-dev libgst-dev cmake-qt-gui build-essential cmake git libgtk2.0-dev pkg-config libavcodec-dev libswscale-dev libtbb2 libtbb-dev libjpeg-dev libpng-dev libtiff-dev libjasper-dev libdc1394-22-dev libgstreamer-vaapi1.0-dev libavformat-dev libavformat-ffmpeg-dev -y
- Download the latest library archive-release
- Download the latest contrib library archive-release
- Extract archives in one directory
- cd opencv && mkdir build && cd build && cmake-gui
- Select opencv directory for source code directory
- Select opencv/build directory for build the binaries
- Press "Configure" and "Finish"
- Type in "extra" in the Search field. The OPENCV_EXTRA_MODULES_.. must be shown. Change it's value to opencv-contrib/modules
- Press "Configure"
- Close the window
- make -j4
- sudo make install
- Run Face Morphing:
- git clone https://github.com/atommaks/FaceMorphing.git to your directory
- cd to <project_directory>
- cmake .
- replace default CMakeLists.txt with my CMakeListst.txt
- make
- ./main args..
./main <img1_path> <img2_path> <shape_predictor_file>
Shape predictor file can be downloaded here