Menu
  • HOME
  • TAGS

How does OpenCV represent a line with 2 two values?

c++,opencv,line,hough-transform

The explanation is given in a link the documentation you point to here. The line is defined in a parametric way, i.e under the form x cos(a) + y sin(a) = r. Contrary to cartesian form, it allows to express vertical lines. Thus, if you don' have vertical lines (i.e...

Using GPUImage and GPUImageHoughTransformLineDetector to detect highlighted text bounding box

ios,objective-c,gpu,gpuimage,hough-transform

I just made some improvements to the Hough transform line detector in the framework that will help with this, but you're going to need to do some additional preprocessing to your image to pick out just that blue box. Let me explain how this operation works. First, it detects edges...

Improving circle detection

opencv,circle,emgucv,hough-transform

analogue to my answers in Detect semi-circle in opencv I see a problem: Don't extract canny edge detection before hough circle detection, since openCV houghCircle itself computes Gradient AND canny. So what you are trying to do is to extract canny from and edge image and detect circles in that,...

Normalize car plate for OCR in OpenCV C++

c++,opencv,ocr,hough-transform

You need to use affine transformations, here there is tutorial. In your situation you need to choose some size of car plate, for example 20x100. Your destination points will be 3 corners of non rotated rectangle of choosen size and source points will be 3 corners of founded car plate....

How can i remove overlaping circles after Hough Transform segmentation

matlab,image-segmentation,hough-transform

You could simply loop over the circles and check if others are "close" to them. If so, you ignore them. idx_mask = ones(size(radii)); min_dist = 1; % relative value. Tweak this if slight overlap is OK. for i = 2:length(radii) cur_cent = centers(i, :); for j = 1:i-1 other_cent =...

Hough Transform with Matlab

matlab,hough-transform

Please read the documentation of the hough function carefully. Here is a clear explanation what is H, theta and rho: The function returns H, the Hough transform matrix. theta (in degrees) and rho are the arrays of rho and theta values over which hough generates the Hough transform matrix. ...

Highlight lines found by hough transform - OPENCV

matlab,opencv,hough-transform

taoufik is correct and I upvoted his answer. I actually found the answer in the OpenCV 2 Computer Vision Application Programming Cookbook before I read his comment. I'm selecting my answer as the answer, because it is more complete for future reference. @taoufik - thanks again, man! I'll post a...

Hough transform and plate localization

c++,opencv,image-processing,hough-transform

Detecting many line segments is typical for the Hough transform. E.g. the letters on the plates might contain straight line segments, the surroundings of the plate (a car?) and whatever. So, you should try utilizing more context information on your plate detection such as background color of the plate (e.g....

Python OpenCV Hough Circles returns None

python,opencv,image-processing,hough-transform

The following code will give you non-None circles: import numpy as np import cv2 img = cv2.imread("../images/opencv_logo.png", 0) img = cv2.medianBlur(img,5) cimg = cv2.cvtColor(img,cv2.COLOR_GRAY2BGR) cv2.imshow("grayscale", cimg) cv2.waitKey(0) circles = cv2.HoughCircles(img,cv2.HOUGH_GRADIENT,1,20, param1=50,param2=30,minRadius=0,maxRadius=0) print (circles) Indeed, the output is: [[[ 45.5 133.5 16.50757408] [ 97.5 45.5 16.80773544] [ 147.5 133.5 16.32482719]]] Note:...

Reading time from analog clock using Hough Line Transform in Python (OpenCV)

python,opencv,hough-transform

I've managed to solve my problem. I've been trying to use Hough Line Transform where I was supposed to use Hough Probabilistic Transform. The moment I got it, I grouped lines drawn along similar functions, sorted them by length, and used arcsine as well as locations of their ends to...

Hough Circle on binary images

c++,opencv,image-processing,hough-transform

I think that you should base you method on finding colors, not shapes or at least you should stary with finding colors and then find shapes. Here there is good(it uses old OpenCV API, but everything else is fine) article describing how to perform color based object tracking in OpenCV....

Difference between MATLAB hough and my implementation

matlab,hough-transform

Well, actually it was a very silly mistake... r = n2*cos(T(i)*pi/180) + n1*sin(T(i)*pi/180); must be r = (n2-1)*cos(T(i)*pi/180) + (n1-1)*sin(T(i)*pi/180); Thanks to this weird MATLAB indexing....