ubc-vision/COTR

find the coordinates of the corresponding point (x', y') on another picture.

Closed this issue · 9 comments

Thank you for the outstanding work you do. I would like to ask if it is possible to enter the coordinates of a point (x, y) and find the coordinates of the corresponding point (x', y') on another picture.

Yes, it is possible. You can check the script: https://github.com/ubc-vision/COTR/blob/master/demo_homography.py
In this script we manually input the coordinates of 4 corners of a paint, and find corresponding points in the other image.

Thank you very much for your prompt answer, I have tried your suggestion and was able to find the coordinates of the corresponding feature points.
Also, can cotr be used for matches with large deformations? For example, a photo of the same person with five fingers open and a photo of the same person with five fingers together, or a photo of a different person with the same five fingers open.

Yes, it is possible. You can check the script: https://github.com/ubc-vision/COTR/blob/master/demo_homography.py In this script we manually input the coordinates of 4 corners of a paint, and find corresponding points in the other image.

I tried, but when I specified a point and tried to find its counterpart, I entered the fixed image coordinates and the resulting content of the corresponding point coordinates did not match the original image, it seemed to just move the fixed image coordinate set uniformly to the floating image.

Maybe the images you tested are too difficult for COTR to work, I.e too much deformation. Can you share some screenshots of your test images?

Maybe the images you tested are too difficult for COTR to work, I.e too much deformation. Can you share some screenshots of your test images?

I tried it again this morning and replaced the function 'cotr_corr_multiscale_with_cycle_consistency' with 'cotr_corr_multiscale ' and it worked a little better. When using 'cotr_corr_multiscale_with_cycle_consistency' I enter five coordinates and end up with only one set of matches, using 'cotr_corr_multiscale ', I was able to find all of them, although there were some wrong matches in there.
findxyhand12
findxy12
The image above is generated using the function 'cotr_corr_multiscale_with_cycle_consistency' and the image below is generated using 'cotr_corr_multiscale'.
I also tried matching photos of different hands and the results are shown below.
differentpeoplezijifind
From the naked eye, the effect seems to be OK.

Yes, the one with cycle consistency will filter out matches that are not trustworthy, that’s why you only obtained one match in the end.

thanks for ur answer!

Although it doesn't feel quite possible, I'd like to ask if you think cotr can be used for point cloud alignment.

Maybe the images you tested are too difficult for COTR to work, I.e too much deformation. Can you share some screenshots of your test images?

I tried it again this morning and replaced the function 'cotr_corr_multiscale_with_cycle_consistency' with 'cotr_corr_multiscale ' and it worked a little better. When using 'cotr_corr_multiscale_with_cycle_consistency' I enter five coordinates and end up with only one set of matches, using 'cotr_corr_multiscale ', I was able to find all of them, although there were some wrong matches in there. findxyhand12 findxy12 The image above is generated using the function 'cotr_corr_multiscale_with_cycle_consistency' and the image below is generated using 'cotr_corr_multiscale'. I also tried matching photos of different hands and the results are shown below. differentpeoplezijifind From the naked eye, the effect seems to be OK.

Excuse me, do you mean a single pixel or a very small area on the hand. Because I consider that a single pixel has no coordinates of four corners