I have been trying to implement a face recognition application using eigen faces algorithm in Java. For which I have installed Opencv and Javacv. I need some measures to check if opencv and javacv are properly installed or not because I am encountering with many errors which occur due to the absence of Opencv and javacv libraries. Unsatisified link error is the one I have been facing since long time. Can anyone please help how to resolve this issue. I am using windows 8 OS and Opencv2.4.5 and javacv0.5. Thanks in advance
UnsatisfiedLinkError almost always means that Java can't find a native library (a DLL on Windows, or an .so file on Linux or Mac OS X). The error message contains the name of the library that wasn't found. To make Java find the library, you must set the system property java.library.path to the directory that contains the native library. You can do this with the -D option when you run the application on the command line, for example:
You can also get this error when you are using a 32-bit JVM but the native library is 64-bit or vice versa. Make sure you use a 32-bit version of the native library if you have a 32-bit JVM, or a 64-bit native library when you have a 64-bit JVM.
Pooja: Find out whether your JVM is 32- or 64-bit. For 64-bit, add the following JARs to your classpath. For 32-bit, add the corresponding "*-windows-*x86.jar"s instead.
/javacv-bin/javacv.jar (this is the actual JavaCV API)
/javacv-bin/javacpp.jar (this is a general framework to load C++ native libraries into java)
/javacv-bin/javacv-windows-x86_64.jar (this contains all the JNI wrapper DLLs)
/javacv-cppjars/opencv-2.4.5-windows-x86_64.jar (this contains the actual OpenCV C++ DLLs)
/javacv-cppjars/ffmpeg-1.2-windows-x86_64.jar (this contains ffmpeg C++ DLLs)
Jesper, what you have said is correct, but javacv uses its own java-c++ bridge framework which packages native DLLs inside JARs and loads them as resources, instead of deploying them in a separate directory. So there's no need to specify java.library.path in this case; the bridge takes care of it.
Thanku for the replies. And sorry for replying back so late. The solutions were really helpful and I cleared off all the errors.
Can you please look into the link
http://fivedots.coe.psu.ac.th/~ad/jg/nui08/ This is the face recognition application I have been trying to implement. Cleared off all the errors, but can't really get the output.
Please help me out in this too.
Thanks in advance
Pooja Donekal wrote:Cleared off all the errors, but can't really get the output.
There are prerequisites involved, such as training the system with your own facial datasets. What steps have you followed before running the code?
While I understand the urge to simply build pre-written code and hope it works, computer vision and face recognition are actually fun and interesting topics.
So I urge you to read and understand the PDFs on that site before proceeding.