I want to check if the physical material is aligned with its bonding diagram?
11 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti

physical material

Bonding diagram
I want to check if all the SMDs and filp dies are located in each white rectangle respectively.
How to do the alignment? Assume top-left corner of top-left rectangle is aligned with top-left corner of top-left SMD pad, but these two figures are not the same size.
3 Commenti
Risposta accettata
praguna manvi
il 13 Feb 2025
To find the alignment between two images, you can perform an "affinetform2d" transformation using key points, specifically the top corners of the first rectangle, and compare the alignment using "imshowpair." Here is an example of how to do this for the images mentioned above:
physical_image = imread("ground.png");
bounding_image = imread("masked.png");
rect_top_left = [25, 35];
smd_top_left = [17, 15];
scale_x = size(physical_image, 2) / size(bounding_image, 2);
scale_y = size(physical_image, 1) / size(bounding_image, 1);
translation_x = rect_top_left(1) - smd_top_left(1);
translation_y = rect_top_left(2) - smd_top_left(2);
tform = affinetform2d ([scale_x 0 0; 0 scale_y 0; translation_x translation_y 1]');
smd_transformed = imwarp(bounding_image, tform, 'OutputView', imref2d(size(physical_image)));
imshowpair(physical_image, smd_transformed, "blend", "Scaling", "joint");

For more information, refer to the following documentation links on the "affinetform2d," "imshowpair," and "imwarp" functions:
Additionally, here is a useful discussion thread on other techniques in general for aligning two images:
Più risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!