Git Product home page Git Product logo

find_face_landmarks's People

Contributors

talhassner avatar yuvalnirkin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

find_face_landmarks's Issues

Invalid MEX-file

Invalid MEX-file 'C:\Users\server\Documents\MATLAB\find_face_landmarks.mexw64': The specified module could not be found. I tried different solutions, but the problem still found when I run landmarks function. I use R2016a, win7-64bit and VS 2012. I added find_face_landmarks/bin to path and find_face_landmarks/interfaces/Matlab to Matlab's path.

I am finding the below issue on (cmake find_face_landmarks) while using your code in c++,mac system

In file included from /usr/local/Cellar/dlib/19.7/include/dlib/gui_core/xlib.h:4:
/usr/local/Cellar/dlib/19.7/include/dlib/gui_core/gui_core_kernel_2.h:11:2: error: "DLIB_NO_GUI_SUPPORT is defined so you can't use the GUI code. Turn DLIB_NO_GUI_SUPPORT off if you want to use it."
#error "DLIB_NO_GUI_SUPPORT is defined so you can't use the GUI code. Turn DLIB_NO_GUI_SUPPORT off if you want to use it."
^
/usr/local/Cellar/dlib/19.7/include/dlib/gui_core/gui_core_kernel_2.h:12:2: error: "Also make sure you have libx11-dev installed on your system"
#error "Also make sure you have libx11-dev installed on your system"
^
2 errors generated.

Compilation failing

I was trying to do make in build folder and it is showing some error.
The cmake logs are:
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.9.4
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning at /usr/local/share/OpenCV/OpenCVConfig.cmake:201 (message):
opencv_face is required but was not found
Call Stack (most recent call first):
CMakeLists.txt:53 (find_package)

-- Boost version: 1.54.0
-- Found the following Boost libraries:
-- filesystem
-- program_options
CMake Warning at CMakeLists.txt:70 (find_package):
By not providing "Findprotobuf.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "protobuf",
but CMake did not find one.

Could not find a package configuration file provided by "protobuf" with any
of the following names:

protobufConfig.cmake
protobuf-config.cmake

Add the installation prefix of "protobuf" to CMAKE_PREFIX_PATH or set
"protobuf_DIR" to a directory containing one of the above files. If
"protobuf" provides a separate development package or SDK, be sure it has
been installed.

-- Found Doxygen: /usr/bin/doxygen (found version "1.8.6")
-- Could NOT find Matlab (missing: Matlab_INCLUDE_DIRS Matlab_MEX_LIBRARY Matlab_MEX_EXTENSION Matlab_ROOT_DIR MX_LIBRARY)
-- Matlab interface won't be build.
-- sequence_face_landmarks will be built without loading and saving support because protobuf is missing.
-- sequence_face_landmarks will be built without LBP tracker because OpenCV Contrib is missing.
-- sfl_cache won't be built because protobuf is missing.
-- sfl_viewer won't be built because protobuf is missing.
-- sfl_track won't be built because protobuf is missing.
-- Configuring done
-- Generating done
-- Build files have been written to: /home/ubuntu/find_face_landmarks/build

The verbose logs make logs are:
[ 20%] Building CXX object sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/sequence_face_landmarks.cpp.o
[ 40%] Building CXX object sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/face_tracker_brisk.cpp.o
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp: In constructor ‘sfl::FaceTrackerBRISK::FaceTrackerBRISK()’:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:35:59: error: no matching function for call to ‘cv::BRISK::create()’
FaceTrackerBRISK() : m_desc_extractor(cv::BRISK::create())
^
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:35:59: note: candidate is:
In file included from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:9:0:
/usr/local/include/opencv2/features2d.hpp:213:35: note: static cv::Ptrcv::Feature2D cv::Feature2D::create(const cv::String&)
CV_WRAP static Ptr create( const String& name );
^
/usr/local/include/opencv2/features2d.hpp:213:35: note: candidate expects 1 argument, 0 provided
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp: In member function ‘std::unique_ptrsfl::TrackedFaceBRISK sfl::FaceTrackerBRISK::createTrackedFace(const cv::Mat&, sfl::Face&, int)’:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:51: error: no match for ‘operator/’ (operand types are ‘cv::Point2f {aka cv::Point_}’ and ‘float’)
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:51: note: candidates are:
In file included from /usr/local/include/opencv2/core.hpp:57:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/mat.hpp:2327:20: note: cv::MatExpr cv::operator/(const cv::MatExpr&, const cv::MatExpr&)
CV_EXPORTS MatExpr operator / (const MatExpr& e1, const MatExpr& e2);
^
/usr/local/include/opencv2/core/mat.hpp:2327:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘const cv::MatExpr&’
/usr/local/include/opencv2/core/mat.hpp:2326:20: note: cv::MatExpr cv::operator/(double, const cv::MatExpr&)
CV_EXPORTS MatExpr operator / (double s, const MatExpr& e);
^
/usr/local/include/opencv2/core/mat.hpp:2326:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘double’
/usr/local/include/opencv2/core/mat.hpp:2325:20: note: cv::MatExpr cv::operator/(const cv::MatExpr&, double)
CV_EXPORTS MatExpr operator / (const MatExpr& e, double s);
^
/usr/local/include/opencv2/core/mat.hpp:2325:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘const cv::MatExpr&’
/usr/local/include/opencv2/core/mat.hpp:2324:20: note: cv::MatExpr cv::operator/(const cv::Mat&, const cv::MatExpr&)
CV_EXPORTS MatExpr operator / (const Mat& m, const MatExpr& e);
^
/usr/local/include/opencv2/core/mat.hpp:2324:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘const cv::Mat&’
/usr/local/include/opencv2/core/mat.hpp:2323:20: note: cv::MatExpr cv::operator/(const cv::MatExpr&, const cv::Mat&)
CV_EXPORTS MatExpr operator / (const MatExpr& e, const Mat& m);
^
/usr/local/include/opencv2/core/mat.hpp:2323:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘const cv::MatExpr&’
/usr/local/include/opencv2/core/mat.hpp:2322:20: note: cv::MatExpr cv::operator/(double, const cv::Mat&)
CV_EXPORTS MatExpr operator / (double s, const Mat& a);
^
/usr/local/include/opencv2/core/mat.hpp:2322:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘double’
/usr/local/include/opencv2/core/mat.hpp:2321:20: note: cv::MatExpr cv::operator/(const cv::Mat&, double)
CV_EXPORTS MatExpr operator / (const Mat& a, double s);
^
/usr/local/include/opencv2/core/mat.hpp:2321:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘const cv::Mat&’
/usr/local/include/opencv2/core/mat.hpp:2320:20: note: cv::MatExpr cv::operator/(const cv::Mat&, const cv::Mat&)
CV_EXPORTS MatExpr operator / (const Mat& a, const Mat& b);
^
/usr/local/include/opencv2/core/mat.hpp:2320:20: note: no known conversion for argument 1 from ‘cv::Point2f {aka cv::Point_}’ to ‘const cv::Mat&’
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:1852:14: note: template cv::Scalar_<Tp> cv::operator/(const cv::Scalar<Tp>&, const cv::Scalar<Tp>&)
Scalar
<Tp> operator / (const Scalar<Tp>& a, const Scalar<Tp>& b)
^
/usr/local/include/opencv2/core/types.hpp:1852:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Scalar_<Tp>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:1845:14: note: template cv::Scalar
<Tp> cv::operator/(Tp, const cv::Scalar<Tp>&)
Scalar
<Tp> operator / (Tp a, const Scalar<Tp>& b)
^
/usr/local/include/opencv2/core/types.hpp:1845:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: mismatched types ‘const cv::Scalar
<Tp>’ and ‘float’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:1831:17: note: template cv::Scalar
cv::operator/(const cv::Scalar
&, double)
Scalar
operator / (const Scalar_& a, double alpha)
^
/usr/local/include/opencv2/core/types.hpp:1831:17: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: cannot convert ‘tracked_face.std::unique_ptr<Tp, Dp>::operator-><sfl::TrackedFaceBRISK, std::default_deletesfl::TrackedFaceBRISK >()->sfl::TrackedFaceBRISK::pos’ (type ‘cv::Point2f {aka cv::Point}’) to type ‘const cv::Scalar&’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:1824:16: note: template cv::Scalar_ cv::operator/(const cv::Scalar_&, float)
Scalar_ operator / (const Scalar_& a, float alpha)
^
/usr/local/include/opencv2/core/types.hpp:1824:16: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: cannot convert ‘tracked_face.std::unique_ptr<Tp, Dp>::operator-><sfl::TrackedFaceBRISK, std::default_deletesfl::TrackedFaceBRISK >()->sfl::TrackedFaceBRISK::pos’ (type ‘cv::Point2f {aka cv::Point}’) to type ‘const cv::Scalar&’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:1815:14: note: template cv::Scalar_<Tp> cv::operator/(const cv::Scalar<_Tp>&, Tp)
Scalar
<Tp> operator / (const Scalar<Tp>& a, Tp alpha)
^
/usr/local/include/opencv2/core/types.hpp:1815:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Scalar
<_Tp>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:877:14: note: template cv::Complex<_Tp> cv::operator/(_Tp, const cv::Complex<_Tp>&)
Complex<_Tp> operator / (_Tp b, const Complex<_Tp>& a)
^
/usr/local/include/opencv2/core/types.hpp:877:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: mismatched types ‘const cv::Complex<_Tp>’ and ‘float’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:870:14: note: template cv::Complex<_Tp> cv::operator/(const cv::Complex<_Tp>&, _Tp)
Complex<_Tp> operator / (const Complex<_Tp>& a, Tp b)
^
/usr/local/include/opencv2/core/types.hpp:870:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Complex<_Tp>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:56:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/types.hpp:856:14: note: template cv::Complex<_Tp> cv::operator/(const cv::Complex<_Tp>&, const cv::Complex<_Tp>&)
Complex<_Tp> operator / (const Complex<_Tp>& a, const Complex<Tp>& b)
^
/usr/local/include/opencv2/core/types.hpp:856:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Complex<_Tp>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:55:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/matx.hpp:1329:14: note: template<class _Tp, int cn> cv::Vec<_Tp, m> cv::operator/(const cv::Vec<_Tp, m>&, double)
Vec<_Tp, cn> operator / (const Vec<Tp, cn>& a, double alpha)
^
/usr/local/include/opencv2/core/matx.hpp:1329:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Vec<_Tp, m>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:55:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/matx.hpp:1323:14: note: template<class _Tp, int cn> cv::Vec<_Tp, m> cv::operator/(const cv::Vec<_Tp, m>&, float)
Vec<_Tp, cn> operator / (const Vec<Tp, cn>& a, float alpha)
^
/usr/local/include/opencv2/core/matx.hpp:1323:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Vec<_Tp, m>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
In file included from /usr/local/include/opencv2/core.hpp:55:0,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:10,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/sfl/face_tracker.h:5,
from /home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:1:
/usr/local/include/opencv2/core/matx.hpp:1317:14: note: template<class _Tp, int cn> cv::Vec<_Tp, m> cv::operator/(const cv::Vec<_Tp, m>&, int)
Vec<_Tp, cn> operator / (const Vec<Tp, cn>& a, int alpha)
^
/usr/local/include/opencv2/core/matx.hpp:1317:14: note: template argument deduction/substitution failed:
/home/ubuntu/find_face_landmarks/sequence_face_landmarks/face_tracker_brisk.cpp:210:89: note: ‘cv::Point2f {aka cv::Point
}’ is not derived from ‘const cv::Vec<_Tp, m>’
tracked_face->pos = tracked_face->pos / (float)tracked_face->landmarks.size();
^
make[2]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/face_tracker_brisk.cpp.o] Error 1
make[1]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/all] Error 2
make: *** [all] Error 2

Can you please help in figuring out the issue here?

compiling failed

Hi,
I tried to compile on two computers and both failed. Could you help me with them? Thank you.


On the first one:
[100%] Linking CXX shared library find_face_landmarks.mexa64
Copy find_face_landmarks documentation file into the output folder
/usr/bin/ld: /usr/local/lib/libdlib.a(base64_kernel_1.cpp.o): relocation R_X86_64_32S against `_ZTVN4dlib6base64E' can not be used when making a shared object; recompile with -fPIC
/usr/local/lib/libdlib.a: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
interfaces/matlab/find_face_landmarks_mex/CMakeFiles/find_face_landmarks.dir/build.make:151: recipe for target 'interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64' failed
make[2]: *** [interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64] Error 1
CMakeFiles/Makefile2:262: recipe for target 'interfaces/matlab/find_face_landmarks_mex/CMakeFiles/find_face_landmarks.dir/all' failed
make[1]: *** [interfaces/matlab/find_face_landmarks_mex/CMakeFiles/find_face_landmarks.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2


On the second one:
[ 12%] Building CXX object sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/sequence_face_landmarks.cpp.o
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp: In member function ‘virtual const sfl::Frame& sfl::SequenceFaceLandmarksImpl::addFrame(const cv::Mat&, int)’:
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:70:39: error: ‘make_unique’ is not a member of ‘std’
std::unique_ptr sfl_frame = std::make_unique();
^
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:70:61: error: expected primary-expression before ‘>’ token
std::unique_ptr sfl_frame = std::make_unique();
^
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:70:63: error: expected primary-expression before ‘)’ token
std::unique_ptr sfl_frame = std::make_unique();
^
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp: In member function ‘void sfl::SequenceFaceLandmarksImpl::extract_landmarks(const cv::Mat&, sfl::Frame&)’:
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:253:34: error: ‘make_unique’ is not a member of ‘std’
std::unique_ptr face = std::make_unique();
^
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:253:55: error: expected primary-expression before ‘>’ token
std::unique_ptr face = std::make_unique();
^
/home/heming/Documents/MATLAB/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:253:57: error: expected primary-expression before ‘)’ token
std::unique_ptr face = std::make_unique();
^
make[2]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/sequence_face_landmarks.cpp.o] Error 1
make[1]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/all] Error 2
make: *** [all] Error 2

Linking CXX executable sfl_cache failed

I can't seem to link sfl_cache executable, even though OpenBlas is already installed. Any help is much appreciated. I'm on Ubuntu 16.04 LTS and using CMake to compile.

Btw thanks Nirkin and the colleagues a lot for publishing your implementation to the public.

/usr/bin/ld: ../sequence_face_landmarks/libsequence_face_landmarks.a(sequence_face_landmarks.cpp.o): undefined reference to symbol 'cblas_sscal' //opt/OpenBLAS/lib/libopenblas.so.0: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status sfl_cache/CMakeFiles/sfl_cache.dir/build.make:114: recipe for target 'sfl_cache/sfl_cache' failed make[2]: *** [sfl_cache/sfl_cache] Error 1 CMakeFiles/Makefile2:140: recipe for target 'sfl_cache/CMakeFiles/sfl_cache.dir/all' failed make[1]: *** [sfl_cache/CMakeFiles/sfl_cache.dir/all] Error 2 Makefile:127: recipe for target 'all' failed make: *** [all] Error 2

non-type template argument is not a pointer to member constant

i found some issues when i try to build this program on my MacBook Pro
sfl_viewer_states.h:59:55: error: non-type template argument is not a pointer to
member constant
sc::in_state_reaction<EvUpdate, Inactive, (void(Inactive::)(const EvUpdate&))(&Inactive::onUpdate)>,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/haiying7/face/find_face_landmarks/sfl_viewer/sfl_viewer_states.h:60:44: error: expected member name or ';' after declaration
specifiers
sc::custom_reaction< EvStart > > reactions;
^
/Users/haiying7/face/find_face_landmarks/sfl_viewer/sfl_viewer_states.h:73:51: error: non-type template argument is not a pointer to
member constant
sc::in_state_reaction<EvSeek, Active, (void(Active::
)(const EvSeek&))(&Active::onSeek)>,

Clarification about Bounding Box Creation

First of all thanks for the great project. I was trying to replicate some results, but I have a couple of doubts about the way bounding boxes are obtained from dlib landmarks in bbox_from_landmarks() from find_face_landmarks/interfaces/matlab/bbox_from_landmarks.m:

function bbox = bbox_from_landmarks(landmarks, frameWidth, frameHeight, square)
%BBOX_FROM_LANDMARKS(landmarks, frameWidth, frameHeight, square) Compute
%   bounding box from landmarks.
%   Input:
%   Output:
%       bbox - Output bounding box [minx miny width height].

%% Parse input arguments
if(~exist('square','var'))
    square = 1;
end

%% Calculate bounding box
minp = min(landmarks);
maxp = max(landmarks);
size = double(maxp - minp + 1);
center = double((maxp + minp)/2);
avg = round(mean(landmarks));
dev = center - avg;
dev_lt = round([0.1*size(1) size(2)*(max(size(1)/size(2),1)*2-1)]) +...
    abs(min(dev,0));
dev_rb = round(0.1*size) + max(dev,0);

%% Limit to frame boundaries
minp = max(double(minp) - dev_lt, 1);
maxp = min(double(maxp) + dev_rb, [frameWidth frameHeight]);

%% Make square
if(square)
    size = maxp - minp + 1;
    sq_size = max(size);
    half_sq_size = round((sq_size - 1)/2);
    center = round((maxp + minp)/2);
    minp = center - half_sq_size;
    maxp = center + half_sq_size;
    
    % Limit to frame boundaries
    minp = max(minp, 1);
    maxp = min(maxp, [frameWidth frameHeight]);
end

%% Output bounding box
bbox = [minp (maxp - minp + 1)];

end

First of all, the bounding box is simply initialised by finding the minimum and maximum coordinates along each dimension. However, immediately afterwards its size is adjusted using the distance between its center and the average location of the keypoints (dev). Could you please explain why this correction is made? Does it make the bounding box more robust in some manner?

Ignoring for the aforementioned correction for a moment, it is common to expand the size the size of the bounding box around its center by some value x (0.2 in this case), e.g.

size = double(maxp - minp + 1);
half_size = (size - 1)/2;
center = (maxp + minp)/2;
minp = center - half_size;
maxp = center + half_size;
bbox = [minp (maxp - minp + 1)]

this operation is quite simple and preserves the aspect ratio. However, in bbox_from_landmarks() the height coordinate is corrected differently (by size(2)*(max(size(1)/size(2),1)*2-1) instead of 0.1 * size(2)). Could you explain the rationale for this alteration?

Thanks in advance,
Davide

New binaries

Hi Yuval,

Is it possible to get new binaries compiled from master for Windows? I'm having some issues using the most recent binaries (and I haven't got a windows compiler toolchain yet, installing VS now).

>> x = find_face_landmarks('models/shape_predictor_68_face_landmarks.dat', 'input/anuclass01.JPG', 1, 1, 0);
>> x

x = 

  struct with fields:

     faces: []
     width: 0
    height: 0

Where as the exact same command worked fine on my MacOS setup with the libraries I compiled myself.

Russ

Unable to find dlib

I've downloaded the dlib library and compiled it successfully:
mkdir build
cd build
cmake ..
make
sudo make install

However, I keep getting the error that my DLIB_ROOT isn't set when trying to build your lib, though I've tried setting it.
I guess I'm missing something simple but would appreciate the help.

Invalid MEX File even with latest binaries

Hi !! I am unable to resolve the below error even after having the latest files on the path.

Invalid MEX-file
'C:\Users\rjznbz\Documents\MATLAB\find_face_landmarks-1.2-x64-vc14-release\interfaces\matlab\find_face_landmarks.mexw64':
Das angegebene Modul wurde nicht gefunden (The Module can't be found)

image

Pre-Compiled Mex File Invalid

I'm unable to execute the pre-compiled mex file on windows. My system is running:
64-bit Windows 7
64-bit Matlab 2016b

When calling the find_face_landmarks function as described in the Matlab tutorial I get the following error:

frames = find_face_landmarks(modelFile, videoFile);
Invalid MEX-file
<my_path>\find_face_landmarks-1.1-x64-vc14-release\interfaces\matlab\find_face_landmarks.mexw64':
The specified module could not
be found..

I understand that this error happens when a mex file is dependent on an external dll that cannot be found. I have added the bin folder containing the opencv dlls to my path.

Unfortunately, Matlab doesn't tell me what dll is missing. However, when I directly run one of the executables in the bin folder (sfl_cache.exe for example), these executables fail with a system error because "opencv_face310.dll" is missing.

So find_face_landmarks.mexw64 may be dependent on opencv_face310.dll? This dll is not in the bin folder and is also not a part of the standard opencv3.1 package (I tried compiling opencv3.1 to see if I could generate my own version of this dll and no luck).

I really appreciate any help you can offer. Thanks!

further explanation

hello yuval,

may you be so kind and explain me what the code is doing?
do you use the frontalized face for landmark detection, instead of the original one?

best regards:)
bibof

Invalid mex file

Hi ,
I am using the 'find_face_landmarks-0.8-x64-vc12' binary in matlab2015b but am getting an error invalid mex file.

Invalid MEX-file
'C:\Users\vijaykumar\Documents\MATLAB\Ankit\find_face_landmarks-0.8-x64-vc12\find_face_landmarks\find_face_landmarks.mexw64':
The specified module could not be found.
Please help me to run

Can't compile

In member function ‘void sfl::FaceTrackerLBP::match(const std::__cxx11::list<std::unique_ptrsfl::TrackedFaceLBP >&, const std::vectorsfl::CandidateFace&, std::set&, std::vectorsfl::Face*&, int)’:
/home/huangw/workspace/find_face_landmarks/sequence_face_landmarks/face_tracker_lbp.cpp:291:56: error: invalid initialization of non-const reference of type ‘std::_Rb_tree_const_iterator&’ from an rvalue of type ‘std::set::iterator {aka std::_Rb_tree_const_iterator}’
auto& tracked_it = tracked_indices.find(tracked_ind);
^
/home/huangw/workspace/find_face_landmarks/sequence_face_landmarks/face_tracker_lbp.cpp:293:50: error: invalid initialization of non-const reference of type ‘std::_Rb_tree_const_iterator&’ from an rvalue of type ‘std::set::iterator {aka std::_Rb_tree_const_iterator}’
auto& cand_it = cand_indices.find(cand_ind);
^
sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/build.make:110: recipe for target 'sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/face_tracker_lbp.cpp.o' failed
make[2]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/face_tracker_lbp.cpp.o] Error 1
CMakeFiles/Makefile2:85: recipe for target 'sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/all' failed
make[1]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

Attempt to execute SCRIPT find_face_landmarks as a function:

Dear, I downloaded pre-compiled library and tried to run on a single still image by using following command "frames = find_face_landmarks(modelFile, 'img.jpg');" but it gives an error

Attempt to execute SCRIPT find_face_landmarks as a function:
/home/omair530/FaceRegistration/find_face_landmarks_1_1/interfaces/matlab/find_face_landmarks.m

Any solution ?

Invalid MEX-file

Hi.
I am using your library to find the facial landmark by Dlib in Matlab.
But the problem occur when I try to run your example in Matlan:
frame = find_face_landmarks(modelFile, I);

Error:
Invalid MEX-file
'/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64':
Missing symbol 'sqlite3_auto_extension' required by
'/usr/lib/libgdal.so.1->/usr/local/lib/libopencv_imgcodecs.so.3.2->/usr/local/lib/libopencv_highgui.so.3.2->/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64'
Missing symbol 'sqlite3_bind_blob' required by
'/usr/lib/libgdal.so.1->/usr/local/lib/libopencv_imgcodecs.so.3.2->/usr/local/lib/libopencv_highgui.so.3.2->/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64'
Missing symbol 'sqlite3_bind_double' required by
'/usr/lib/libgdal.so.1->/usr/local/lib/libopencv_imgcodecs.so.3.2->/usr/local/lib/libopencv_highgui.so.3.2->/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64'
Missing symbol 'sqlite3_bind_int' required by
'/usr/lib/libgdal.so.1->/usr/local/lib/libopencv_imgcodecs.so.3.2->/usr/local/lib/libopencv_highgui.so.3.2->/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64'
Missing symbol 'sqlite3_bind_int64' required by
'/usr/lib/libgdal.so.1->/usr/local/lib/libopencv_imgcodecs.so.3.2->/usr/local/lib/libopencv_highgui.so.3.2->/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64'
Missing symbol 'sqlite3_bind_null' required by
'/usr/lib/libgdal.so.1->/usr/local/lib/libopencv_imgcodecs.so.3.2->/usr/local/lib/libopencv_highgui.so.3.2->/home/thanhvo/Downloads/find_face_landmarks-1.2/interfaces/matlab/find_face_landmarks_mex/find_face_landmarks.mexa64'
Missing symbol 'sqlite3_bind_text' required by
....
It is very long.
It will be very helpful if you could help. My computer runs in Ubuntu 16.04 with Matlab R2017a. I have installed Dlib, OpenCV also.
Best regards.
Thanh.

Compile error on OSX 10.11

Hi Yuval,

Running into some issues compiling.

-- The C compiler identification is AppleClang 8.1.0.8020042
-- The CXX compiler identification is AppleClang 8.1.0.8020042
Scanning dependencies of target sequence_face_landmarks
[ 12%] Building CXX object sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/sequence_face_landmarks.cpp.o
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:70:44: error: 
      no member named 'make_unique' in namespace 'std'
                        std::unique_ptr<Frame> sfl_frame = std::make_unique<Frame>();
                                                           ~~~~~^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:70:56: error: 
      'Frame' does not refer to a value
                        std::unique_ptr<Frame> sfl_frame = std::make_unique<Frame>();
                                                                            ^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:25:12: note: 
      declared here
    struct Frame
           ^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:70:63: error: 
      expected expression
                        std::unique_ptr<Frame> sfl_frame = std::make_unique<Frame>();
                                                                                   ^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:253:39: error: 
      no member named 'make_unique' in namespace 'std'
                                std::unique_ptr<Face> face = std::make_unique<Face>();
                                                             ~~~~~^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:253:51: error: 
      'Face' does not refer to a value
                                std::unique_ptr<Face> face = std::make_unique<Face>();
                                                                              ^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sfl/sequence_face_landmarks.h:16:12: note: 
      declared here
    struct Face
           ^
/Users/russ/Documents/project/files/find_face_landmarks/sequence_face_landmarks/sequence_face_landmarks.cpp:253:57: error: 
      expected expression
                                std::unique_ptr<Face> face = std::make_unique<Face>();
                                                                                    ^
6 errors generated.
make[2]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/sequence_face_landmarks.cpp.o] Error 1
make[1]: *** [sequence_face_landmarks/CMakeFiles/sequence_face_landmarks.dir/all] Error 2
make: *** [all] Error 2

Thanks,

Russ

code speed

Hi, YuvalNirkin.
I want to use your code to do something, but some errors appeared when I cmake the file, and I deal with these errors one by one, and there still exist some error. Because I'm in a hurry, I think maybe I can confirm the fps of the method when tracking, would mind tell me?
Thank you very much!
Best Zhang.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.