10 votes

In opecv function Hough circles how does parameter 1 and 2 affect circle detection and how can I adjust them to increase accuracy?

Intuition for parameters of HoughCircles: image: 8-bit, single channel image. If working with a color image, convert to grayscale first. method: Defines the method to detect circles in images. ...
Eric Leschinski's user avatar
9 votes
Accepted

How to calculate particles sizes for spheric particles with overlapping and superposition? (Example image included)

Here is what I experimented with: Use ELSD to generate elliptic contours. You could basically use any edge detector, but since in the following stages I will benefit from circle detectors, it is good ...
Tolga Birdal's user avatar
  • 5,465
6 votes
Accepted

Given a set of lines, find only those who are parallel (perspective)

Parallel lines in the image do intersect at a vanishing point. Therefore simply hypothesizing lines (a gradient direction at a point suffices to describe it) and voting (see Hough voting) would ...
Tolga Birdal's user avatar
  • 5,465
5 votes
Accepted

Detect circles in image

1) Normalize your image to range $[0,255]$. 2) Select a threshold and threshold the image. For your image, what worked is: $\tau=[140-150]$. 3) Compute a Euclidean distance transform. 4) Apply ...
Tolga Birdal's user avatar
  • 5,465
3 votes
Accepted

How can I isolate a Hough circle that I perceive to be the best fit, but is ranked much lower?

The Hough Transform is "right". Because it searches for the most consistent "shape" given the accumulated values. If all you would like to do is to find the center of the spot, there are other ...
A_A's user avatar
  • 10.6k
3 votes

How to set threshold value for Hough Transform

Well, it really depends on what you expect to find in the image. The matlab function uses an example threshold of half the largest peak. What sort of images are you using this on? So, based on just ...
Peter K.'s user avatar
  • 25.3k
3 votes
Accepted

Fitting a grid to points in a 2d space

You could represent the grid with 5 parameters: (x0, y0) to represent the offset from your image origin to the grid origin (xs, ys) to represent a multiplication factor from your image plane to your ...
dimsum88's user avatar
3 votes
Accepted

Algo Name: Detecting Elongated Shape in 2D Image by Convolution with Directed Lines

What you are essentially doing is a matched filter. However, thanks to Hough transform, your filter (line) is oriented and therefore I would call it an oriented matched filter. For generating the ...
Tolga Birdal's user avatar
  • 5,465
2 votes
Accepted

Difference between Generalized Hough Transform and Cross-correlation Feature Matching

There is a big difference: The Hough Transform maps the input space to a parameter space, where the search takes place. This way, the run-time of the algorithm is independent of the degree of the ...
Tolga Birdal's user avatar
  • 5,465
2 votes

Can you detect circles only using the hough line transform?

No this won't work. Simply because we do not know the center of the circle in advance (no oracle telling us) and therefore we cannot find a voting space parameterization where $r$ is fixed and only $\...
Tolga Birdal's user avatar
  • 5,465
2 votes

how to detect two parallel lines in a binary image with MATLAB

this is John BG [email protected] 1.- Avoid doubling segments If you carry on with the code you have used in your approach: ...
John Bofarull's user avatar
2 votes

how to detect two parallel lines in a binary image with MATLAB

You mentioned the Hough transform, but your code doesn't use it. However, it can help you to find out the orientations of lines. The maximum values of the Hough transform correspond to probable lines....
Gwen's user avatar
  • 121
2 votes

Selecting gradient orientation for Generalized Hough Transform while scaling and rotation is present

If the shape is rotated by $\theta$, then the gradient orientation ($\phi$) for a given edge point changes. So, shouldn't we do either one of the following: Rotate all the ϕ values in R table ...
A_A's user avatar
  • 10.6k
2 votes
Accepted

Image processing: How to find center of biggest blob in an image?

do a distance transform. you'll see why that's a good idea: for every pixel you get the shortest distance to a border. that's exactly the radius of an inscribed circle. from this, just find the pixel ...
Christoph Rackwitz's user avatar
2 votes

How to segment multiple overlapping coins (ellipses)

Segmentation is generally a process that is very susceptible to noise. I would better use a detector, especially for geometric shapes like coins. Remember, if you have a good detection, you also ease ...
Tolga Birdal's user avatar
  • 5,465
2 votes

Help or suggestions with Line detection in microscopy images

Instead of using a homegrown amalgamation of algorithms, I suggest you look in the scientific literature for existing solutions. People have solved the same problem over and over again, there exist ...
Cris Luengo's user avatar
  • 2,359
1 vote

Help or suggestions with Line detection in microscopy images

I used Median Blur instead of Gaussian Blur, and used Sobel Filter to detect the edges, the ...
Bilal's user avatar
  • 167
1 vote

Hough Transform not working to recognize a line

What you want is just to find the function $$y(x) = mx + q$$ that fits through the centroids you've found. You wouldn't do a Hough transform on that (since Hough transforms generally perform badly ...
Marcus Müller's user avatar
1 vote
Accepted

Computer Vision - Does implementation of Hough Transform for lines require a loop for angle parameter?

In real world implementations, is the line: for theta = [theta_min to theta_max ] required? . . . Since we apply Canny edge detector to an image, prior to Hough Transform, we can obtain angle of ...
A_A's user avatar
  • 10.6k
1 vote
Accepted

Selecting gradient orientation for Generalized Hough Transform while scaling and rotation is present

I was having the same issue as you had: most resources I found online seem to miss this issue about the rotating gradient orientation, as did A_A in their answer (which to be fair is very clear in the ...
chelivery's user avatar
1 vote
Accepted

MatLab - Can not detect all lines in a "simple" image using houghlines

houghpeaks function in MATLAB accepts a parameter named NHoodSize that specifies the size of the neighborhood where a non-...
Tolga Birdal's user avatar
  • 5,465
1 vote

Line Detection with OpenCV and Python

The performance of line detectors are image and application dependent in generally. Typically, people tune the parameters of the detectors to get the best possible result. When such a result cannot be ...
Tolga Birdal's user avatar
  • 5,465
1 vote

Edge following using Hough transform

SLAM is Simultaneous Localization and Mapping. If you have maps already, I think your main challenge in line following is the localization part. For straight lines, Canny+Hough pipeline works ...
Philip M.'s user avatar
  • 156

Only top scored, non community-wiki answers of a minimum length are eligible