Trying to find chekerboard points, not returning any points with detectCheckerboardPoints

4 Ansichten (letzte 30 Tage)
Hi all
I have a fisheye lens system through which I'm taking images. The images are highly distorted, but there are also many of these images, and I wanted to find an automated way of consistently undistorting them. I printed out a checkerboard pattern, and took multiple images of this pattern, a representative image shown.
However, when I try to use the detectCheckerboardPoints, I get no points back. I know that this algo is sensitive to noise, which I definitely have in my images, but I can't do a whole lot better with my current system, so this is what I've got. I've tried playing with HighDistortion toggle, the MinCornerMetric, which I set as low as 0.0002 and as high as 0.5, and the PartialDetections toggle, to no joy. Can anyone suggest further steps, or alternative algorithms, or a better way of doing this? Otherwise, I'll have to parse through hundreds of images and manually label the points, and that is likely to take a while.
Some of the pre-processing steps I've tried:
  1. imbinarize
  2. imerode
  3. medfilt2
  4. Combination of the three above steps in varied order

Akzeptierte Antwort

Matt J
Matt J am 20 Okt. 2023
Bearbeitet: Matt J am 20 Okt. 2023
You can download pgonCorners,
However, it will only find the corners of one chequerboard square at a time, so you will have to extract separate images of each black square:
load chequerboard
BW=~imfill(BW,[1,1]);
BW=bwareaopen(BW,10);
BW=imclose(BW, ones(5));
BW=imerode(BW,ones(3));
rc=fliplr(vertcat(regionprops(BW,'Centroid').Centroid));
clear V
for i=height(rc):-1:1
onesquare=bwselect(BW,rc(i,1),rc(i,2));
% imdisp(onesquare)
V{i}=fliplr(pgonCorners(onesquare,4));
end
V=vertcat(V{:});
imshow(BW,[]);hold on
scatter(V(:,1),V(:,2),'r','filled','SizeData',15); hold off
  5 Kommentare
Matt J
Matt J am 20 Okt. 2023
Since you accept-clicked the answer, I assume you overcame the problem?
Alexander Dumont
Alexander Dumont am 20 Okt. 2023
I think I'm at a point where I can figure out the rest. Thank you for all the help, it saved me days of hassle.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Convert Image Type finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by