opencv3.0

Using native OpenCV 3.0.0 in Android Studio 1.5 with Gradle experimental 0.4.0

时光毁灭记忆、已成空白 提交于 2019-12-03 17:17:15
I'm trying to get OpenCV 3.0.0 native to run in my Android Studio 1.5 with Gradle experimental 0.4.0. I can already use the Java components of OpenCV and the regular NDK functions. But as soon as I try to use the namespace cv in my native code I get the following exception (it is shortened. The complete exception was too long): app\src\main\jniLibs\armeabi\libopencv_core.a(matrix.cpp.o):matrix.cpp:function std::vector<unsigned char, std::allocator<unsigned char> >::resize(unsigned int, unsigned char): error: undefined reference to 'std::__throw_length_error(char const*)' app\src\main\jniLibs

LineSegmentDetector in Opencv 3 with Python

微笑、不失礼 提交于 2019-12-03 13:37:46
Can a sample implementation code or a pointer be provided for implementing LSD with opencv 3.0 and python? HoughLines and HoughLinesP are not giving desired results in python and want to test LSD in python but am not getting anywhere. I have tried to do the following: LSD=cv2.createLineSegmentDetector(0) lines_std=LSD.detect(mixChl) LSD.drawSegments(mask,lines_std) However when I draw lines on the mask I get an error which is: LSD.drawSegments(mask,lines_std) TypeError: lines is not a numerical tuple Can someone please help me with this? Thanks in advance. You can use cv2.drawSegments function

Image Processing - Dress Segmentation using opencv

痴心易碎 提交于 2019-12-03 09:12:28
问题 I am working on dress feature identification using opencv. As a first step, I need to segment t-shirt by removing face and hands from the image. Any suggestion is appreciated. 回答1: I suggest the following approach: Use Adrian Rosebrock's skin detection algorithm for detecting the skin (thank you for Rosa Gronchi for his comment). Use region growing algorithm on the variance map. The initial seed can be calculated by using stage 1(see the attached code for more information). code: %stage 1:

How to check if point is placed inside contour? [closed]

别说谁变了你拦得住时间么 提交于 2019-12-03 07:56:30
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed last year . I have drawn a contour around extreme points. Inside polygon figure I have others points. How to check if they are inside contour? 回答1: You can use the cv2.pointPolygonTest() function available in OpenCV. For example: dist = cv2.pointPolygonTest(cnt,(50,50),True) In this example we

KNN train() in cv2 with opencv 3.0

女生的网名这么多〃 提交于 2019-12-03 04:56:17
问题 I'm trying to run k-nearest neighbours using cv2 (python 2.7) and opencv 3.0. I've replicated the same error message using code like http://docs.opencv.org/3.0-beta/doc/py_tutorials/py_ml/py_knn/py_knn_understanding/py_knn_understanding.html: import cv2 import numpy as np import matplotlib.pyplot as plt # Feature set containing (x,y) values of 25 known/training data trainData = np.random.randint(0,100,(25,2)).astype(np.float32) # Labels each one either Red or Blue with numbers 0 and 1

What are the main references to the fish-eye camera model in OpenCV3.0.0dev?

谁都会走 提交于 2019-12-03 04:24:46
问题 I am wrestling with the Fish-Eye Camera Model used in OpenCV 3.0.0.dev . I have read the documentation in this link several times, especially the "Detailed Description" part and formulas modeling fish-eye distortion. By now I have two concerns: Based on the projection models listed here and their conceptual explanations in " Accuracy of Fish-Eye Lens Model " By Hughes, I can't figure out which projection model has been used in the OpenCV implementation. Since the description is so concise, I

what is the difference between OpenCV 2.4.11 and 3.0.0

試著忘記壹切 提交于 2019-12-03 03:56:49
问题 The latest release of OpenCV shows 2.4.11 Feb,2015 which is more recent then 3.0.0 which is in Beta. What is the difference between them. Should I use OpenCV 2.4.11 over 3.0.0 as I have encountered few bugs in 3.0.0. How do their releases work? 回答1: 3.0.0 should bring a lot of new features but it's currently beta and not the official release (can be unstable). Last official stable release was 2.4.11. Use the 3.0.0 if there is features you don't retrieve in 2.4.11 or if you are adventurous (3

How to merge a lot of square images via OpenCV

牧云@^-^@ 提交于 2019-12-03 01:48:01
How can I merge images like below into a single image using OpenCV (there can be any number of them both horizontally and vertically)? Is there any built-in solution to do it? Additional pieces: Well, it seems that I finished the puzzle: Main steps: Compare each pair of images ( puzzle pieces ) to know the relative position ( findRelativePositions and getPosition ). Build a map knowing the relative positions of the pieces ( buildPuzzle and builfForPiece ) Create the final collage putting each image at the correct position (final part of buildPuzzle ). Comparison between pieces A and B in step

Image Processing - Dress Segmentation using opencv

徘徊边缘 提交于 2019-12-02 23:23:40
I am working on dress feature identification using opencv. As a first step, I need to segment t-shirt by removing face and hands from the image. Any suggestion is appreciated. I suggest the following approach: Use Adrian Rosebrock's skin detection algorithm for detecting the skin (thank you for Rosa Gronchi for his comment). Use region growing algorithm on the variance map. The initial seed can be calculated by using stage 1(see the attached code for more information). code: %stage 1: skin detection - Adrian Rosebrock solution im = imread(<path to input image>); hsb = rgb2hsv(im)*255; skinMask

How to check if point is placed inside contour? [closed]

≡放荡痞女 提交于 2019-12-02 21:25:14
I have drawn a contour around extreme points. Inside polygon figure I have others points. How to check if they are inside contour? You can use the cv2.pointPolygonTest() function available in OpenCV. For example: dist = cv2.pointPolygonTest(cnt,(50,50),True) In this example we are checking whether the coordinate (50, 50) is present withing the contour cnt dist returns one of the following three: Positive value if the point is inside the contour Negative value if the point is outside the contour Zero if the point is on the contour Within the function cv2.pointPolygonTest() the third parameter