Ask Your Question

seriousgeek's profile - activity

2016-07-19 13:59:23 -0600 asked a question Illegal instruction vmovss on running openCV program

Hello, I'm running a centos7 machine and I have installed opencv3 by compiling the source. I have a test C++ program to run openCV but it gives the error: Illegal Instruction. I extracted the core dump and ran it with gdb to get the following output:

 [atmohan@intern01-fm akaze_simp_latest]$ gdb akaze_simple core.16668 

[New LWP 16668]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
Core was generated by `./akaze_simple'.
Program terminated with signal 4, Illegal instruction.
#0  0x00007fcb81fe09a8 in cv::initInterTab2D(int, bool) () from ./libopencv/lib/libopencv_imgproc.so.3.0
Missing separate debuginfos, use: debuginfo-install glibc-2.17-55.el7.x86_64 libgcc-4.8.2-16.el7.x86_64 libjpeg-turbo-1.2.90-5.el7.x86_64 libstdc++-4.8.2-16.el7.x86_64 zlib-1.2.7-13.el7.x86_64
(gdb) bt
#0  0x00007fcb81fe09a8 in cv::initInterTab2D(int, bool) () from ./libopencv/lib/libopencv_imgproc.so.3.0
#1  0x00007fcb81fe0a1d in global constructors keyed to imgwarp.cpp ()
   from ./libopencv/lib/libopencv_imgproc.so.3.0
#2  0x00007fcb82a25106 in __do_global_ctors_aux () from ./libopencv/lib/libopencv_imgproc.so.3.0
#3  0x00007fcb81faf1f3 in _init () from ./libopencv/lib/libopencv_imgproc.so.3.0
#4  0x00007ffff2ca4f28 in ?? ()
#5  0x00007fcb845e34bf in _dl_init_internal () from /lib64/ld-linux-x86-64.so.2
#6  0x00007fcb845d545a in _dl_start_user () from /lib64/ld-linux-x86-64.so.2
#7  0x0000000000000001 in ?? ()
#8  0x00007ffff2ca666e in ?? ()
#9  0x0000000000000000 in ?? ()
(gdb) x/i 0x00007fcb81fe09a8
=> 0x7fcb81fe09a8 <_ZN2cvL14initInterTab2DEib+2344>:    
    vmovss 0xa45af8(%rip),%xmm0        # 0x7fcb82a264a8

As it can be seen, the vmovss instruction is found to be illegal and I'm not sure why. My cpu/procinfo is as follows:

processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 44 model name : Intel(R) Xeon(R) CPU E5620 @ 2.40GHz stepping : 2 microcode : 0x13 cpu MHz : 2394.000 cache size : 12288 KB physical id : 0 siblings : 2 core id : 0 cpu cores : 2 apicid : 0 initial apicid : 0 fpu : yes fpu_exception : yes cpuid level : 11 wp : yes flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts mmx fxsr sse sse2 ss ht syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology tsc_reliable nonstop_tsc aperfmperf pni pclmulqdq ssse3 cx16 sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes hypervisor lahf_lm ida arat dtherm tsc_adjust bogomips : 4788.00 clflush size : 64 cache_alignment : 64 address sizes : 42 bits physical, 48 bits virtual power management:

processor : 1 vendor_id : GenuineIntel cpu family : 6 model : 44 model name : Intel(R) Xeon(R) CPU E5620 @ 2.40GHz stepping : 2 microcode : 0x13 cpu MHz : 2394.000 cache size : 12288 KB physical id : 0 siblings : 2 core id : 1 cpu cores : 2 apicid : 1 initial apicid : 1 fpu : yes fpu_exception : yes cpuid level : 11 wp : yes flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts mmx fxsr sse sse2 ss ht syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology tsc_reliable nonstop_tsc aperfmperf pni pclmulqdq ssse3 cx16 sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes hypervisor lahf_lm ida arat dtherm tsc_adjust bogomips : 4788.00 clflush size : 64 cache_alignment : 64 address sizes : 42 bits physical ... (more)

2016-06-29 10:00:22 -0600 asked a question AKAZE not producing good results compared to SIFT in openCV Java

Hello everyone, I'm new to the world of computer vision and presently I'm working on a project to compare two images to see if there is a match. I have read that AKAZE performs better compared to SIFT, but I have found otherwise. I'm using the Java implementation of openCV and I find that SIFT produces better feature points and thereby better matches as compared to AKAZE. Following is the code I use for detecting keypoints, computing descriptors and finding matches:

         MatOfKeyPoint objectKeyPoints1 = new MatOfKeyPoint();
          MatOfKeyPoint objectKeyPoints2 = new MatOfKeyPoint();

          FeatureDetector featureDetector1 = FeatureDetector.create(FeatureDetector.SIFT);
          FeatureDetector featureDetector2 = FeatureDetector.create(FeatureDetector.SIFT);

          featureDetector1.detect(image1, objectKeyPoints1);
          featureDetector2.detect(image2, objectKeyPoints2);

          DescriptorExtractor descriptorExtractor = DescriptorExtractor.create(DescriptorExtractor.SIFT);

          MatOfKeyPoint objectDescriptors1 = new MatOfKeyPoint();
          descriptorExtractor.compute(image1, objectKeyPoints1, objectDescriptors1);

          MatOfKeyPoint objectDescriptors2 = new MatOfKeyPoint();
          descriptorExtractor.compute(image2, objectKeyPoints2, objectDescriptors2);
          MatOfDMatch mtd=new MatOfDMatch();

          DescriptorMatcher descriptorMatcher = DescriptorMatcher.create(DescriptorMatcher.BRUTEFORCE)
          descriptorMatcher.match(objectDescriptors1,objectDescriptors2 , mtd);

The code is the same for AKAZE as well, just that I substitute SIFT with AKAZE in the code. I get around 178 matches for SIFT but just 10-20 matches for AKAZE.

Could you help me in identifying what could be a probable cause of this issue? Could this be anything related to the Java wrapper for openCV?

Thanks