Plot extracted world coordinate of object on object

5 次查看(过去 30 天)
Hello,
I have successfully developed a computer vision alrothim to detect segments of an object. To help, I have colored the two segments I am interested in.
I am having a challenge plotting the XY coordinate (shown left of image) of the detected color on the original image so that their location aligns. Can any one offer any suggestions or help? I will very much appreciate this. Thank you.
  2 个评论
KALYAN ACHARJYA
KALYAN ACHARJYA 2022-7-17
Hi Sam,
Are you wish to get the coordinates of the color segments (Red & Blue)?
Kalyan
Sam Ade
Sam Ade 2022-7-17
I would like to let the xy coordinate of the detected color match (or rotated) to that of the actual image taken with a camera.

请先登录,再进行评论。

回答(1 个)

Krishna
Krishna 2024-2-7
编辑:Krishna 2024-2-7
Hello Sam,
As far as I understand your question you need to plot the X Y coordinate you have found for different segments in the image using your computer vision algorithm. If you're using MATLAB to plot the XY coordinates of detected colour segments on an original image, you can follow these steps:
  1. Read the image using ‘imread’.
  2. Use ‘insertshape’ to mark the image of the detected coordinates.
  3. Use ‘imwirte’ or ’imshow’ to display the information.
Please go through the following documentations for more information on the function,
Now for troubleshooting alignment issues as you mentioned in your question,
  • Confirm that the coordinate system used in your detection algorithm matches MATLAB's image coordinate system, where the top-left corner is (1,1).
  • If you're using normalized coordinates or a different scale, convert them to pixel coordinates that match the original image's resolution.
  • Check for any image preprocessing steps like padding, scaling, or rotations you might be using in your computer vision algorithm that could affect the alignment of the coordinates.
If you're working with a sequence of images or a video, apply this process to each frame. If your algorithm outputs bounding boxes, you can use ‘rectangle’ in MATLAB to draw the boxes on the image.
Hope this helps.

类别

Help CenterFile Exchange 中查找有关 Image Processing and Computer Vision 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by