Exception in thread "Thread-2" java.lang.UnsatisfiedLinkError: no jniopencv_core in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1889)
at java.lang.Runtime.loadLibrary0(Runtime.java:849)
at java.lang.System.loadLibrary(System.java:1088)
at org.bytedeco.javacpp.Loader.loadLibrary(Loader.java:726)
at org.bytedeco.javacpp.Loader.load(Loader.java:501)
at org.bytedeco.javacpp.Loader.load(Loader.java:418)
at org.bytedeco.javacpp.opencv_core.<clinit>(opencv_core.java:10)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:278)
at org.bytedeco.javacpp.Loader.load(Loader.java:473)
at org.bytedeco.javacpp.Loader.load(Loader.java:418)
at org.bytedeco.javacpp.opencv_imgcodecs.<clinit>(opencv_imgcodecs.java:13)
at org.datavec.image.loader.NativeImageLoader.asMatrix(NativeImageLoader.java:193)
at imagenet.Utils.ImageNetRecordReader.next(ImageNetRecordReader.java:75)
at org.deeplearning4j.datasets.datavec.RecordReaderDataSetIterator.next(RecordReaderDataSetIterator.java:171)
at org.deeplearning4j.datasets.datavec.RecordReaderDataSetIterator.next(RecordReaderDataSetIterator.java:347)
at org.deeplearning4j.datasets.datavec.RecordReaderDataSetIterator.next(RecordReaderDataSetIterator.java:46)
at org.deeplearning4j.datasets.iterator.AsyncDataSetIterator$IteratorRunnable.run(AsyncDataSetIterator.java:294)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.UnsatisfiedLinkError: /tmp/javacpp1176234266740952/libjniopencv_core.so: /tmp/javacpp1176234266740952/libopencv_core.so.3.1: symbol _ZTTNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEE, version GLIBCXX_3.4.21 not defined in file libstdc++.so.6 with link time reference
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1968)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1893)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1854)
at java.lang.Runtime.load0(Runtime.java:795)
at java.lang.System.load(System.java:1062)
at org.bytedeco.javacpp.Loader.loadLibrary(Loader.java:709)
... 15 more
Exception in thread "main" java.lang.IllegalStateException: Unexpected state occurred for AsyncDataSetIterator: runnable died or no data available
at org.deeplearning4j.datasets.iterator.AsyncDataSetIterator.next(AsyncDataSetIterator.java:226)
at org.deeplearning4j.datasets.iterator.AsyncDataSetIterator.next(AsyncDataSetIterator.java:35)
at org.deeplearning4j.datasets.iterator.MultipleEpochsIterator.next(MultipleEpochsIterator.java:99)
at org.deeplearning4j.datasets.iterator.MultipleEpochsIterator.next(MultipleEpochsIterator.java:122)
at org.deeplearning4j.datasets.iterator.MultipleEpochsIterator.next(MultipleEpochsIterator.java:36)
at org.deeplearning4j.nn.multilayer.MultiLayerNetwork.fit(MultiLayerNetwork.java:1048)
at imagenet.ImageNetStandardExample.trainModel(ImageNetStandardExample.java:81)
at imagenet.ImageNetStandardExample.initialize(ImageNetStandardExample.java:49)
at imagenet.ImageNetMain.run(ImageNetMain.java:125)
at imagenet.ImageNetMain.main(ImageNetMain.java:195)
How can I resolve this issue?
Regards
Deepali
What does your pom.xml file look like?
sudo apt-get install libopencv-dev python-opencv
--
---
You received this message because you are subscribed to a topic in the Google Groups "javacv" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/javacv/70Fl3NDLGXk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to javacv+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
---
You received this message because you are subscribed to the Google Groups "javacv" group.
To unsubscribe from this group and stop receiving emails from it, send an email to javacv+unsubscribe@googlegroups.com.
Hard to say, I did try a little experiment with enabling a bunch of pi3 optimisations, but didn't make much difference - but might have been a flawed test.There's a lot of questions there, best way if you need an answer to them is to come up with some experiments that would find out, pi functionality is still not very well tested (or if it is, would be nice to see some results). A year or so ago, I found not much difference between opencv and ffmpeg via javacv, and raw framerate I could get around 20-30fps - so long as resolution wasn't too high. That framerate dropped really quickly as soon as any operations were performed on each frame - so with face detection it'd be more like 1-2fps.Would be interesting if someone has time to benchmark, where that slowness comes in, is it just that the pi is a bit slower (but, 1ghz is still pretty quick for what I grew up using), but if python is able to call effectively the same methods from opencv for face recognition using same data set, camera, device, etc, to keep it all fair, that'd be pretty useful to know. If you've got time to put together sample code for python and java that's equivalent, it'd be a great step forward to baseline/improve pi performance.For using the raspicam, try thissudo modprobe bcm2835-v4l2 max_video_width=2592 max_video_height=1944That should give you a device at /dev/video0 usable as if its a normal USB camera
I was still curious about this, so I just built opencv with python 2.7 bindings on a Pi3, and tested a pretty simple python program to grab the camera via PiCamera library, pass it to opencv and perform face recognition on that frame.If I keep the loop just grabbing the image, I get about 15fps. As soon as I do face recognition per frame, it drops to about 2.5fps. So seems on par with javacv. If anyone is getting better performance I'm keen to hear, could be something to include in Pi builds for javacv
On 18 September 2017 at 16:53, Vin Baines <v.f.b...@gmail.com> wrote:
Hard to say, I did try a little experiment with enabling a bunch of pi3 optimisations, but didn't make much difference - but might have been a flawed test.There's a lot of questions there, best way if you need an answer to them is to come up with some experiments that would find out, pi functionality is still not very well tested (or if it is, would be nice to see some results). A year or so ago, I found not much difference between opencv and ffmpeg via javacv, and raw framerate I could get around 20-30fps - so long as resolution wasn't too high. That framerate dropped really quickly as soon as any operations were performed on each frame - so with face detection it'd be more like 1-2fps.Would be interesting if someone has time to benchmark, where that slowness comes in, is it just that the pi is a bit slower (but, 1ghz is still pretty quick for what I grew up using), but if python is able to call effectively the same methods from opencv for face recognition using same data set, camera, device, etc, to keep it all fair, that'd be pretty useful to know. If you've got time to put together sample code for python and java that's equivalent, it'd be a great step forward to baseline/improve pi performance.For using the raspicam, try thissudo modprobe bcm2835-v4l2 max_video_width=2592 max_video_height=1944That should give you a device at /dev/video0 usable as if its a normal USB camera
To unsubscribe from this group and all its topics, send an email to javacv+un...@googlegroups.com.
To unsubscribe from this group and all its topics, send an email to javacv+unsubscribe@googlegroups.com.