How to Find the image gradient and magnitude and angle. I’ve attached the 2pic, tells which is foreground & background needs to remove for process. thanks

1 visualizzazione (ultimi 30 giorni)
%Aim is how to find multiple gradient and magnitude and angle for edge detection of this image?

Risposte (2)

Image Analyst
Image Analyst il 10 Gen 2022
There are imgradient() and imgradientxy() functions. I'm not sure what is background in the images. There are lots of regions that could potentially be considered as "background". Can you identify the background and foreground regions? And what is your algorithm for detecting defects? Some sort of morphological subtraction based on using imbinarize on the original image? Note that you cannot use imbinarize on two images if the images are different because it may choose different thresholds for each image so you can't compare them. You'll have to use graythresh() on one of the images and then use that threshold gray level to apply to both images.

Image Analyst
Image Analyst il 10 Gen 2022
Try calling imregister() to align your perfect, reference image, and your test image. Then subtract and threshold.
  3 Commenti
Image Analyst
Image Analyst il 11 Gen 2022
No, I've been too busy with my real job. How about you? I'm sure you've tried my suggestions by now, so what do you have?
Image Analyst
Image Analyst il 11 Gen 2022
If they're not proprietary/secret, attach your two images - your reference/perfect image, and your moved one with the defects.

Accedi per commentare.

Prodotti


Release

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by