lijx10 / USIP

USIP: Unsupervised Stable Interest Point Detection from 3D Point Clouds. ICCV 2019
GNU General Public License v3.0
206 stars 29 forks source link

About the rotation of key points #10

Closed SRainGit closed 4 years ago

SRainGit commented 4 years ago

Hi,

Thanks for your work! But I found the key points don't align the original point cloud.

I pick up several frames of point cloud and transfer them into the global coordinate frame as well as the detected key points. From the picture, it seems the key points are rotated by 90 degrees somehow.

image

I tried all the cases of rotating X/Y/Z 90/-90 degrees respectively but still cannot work. See the below screenshots. The key points are rotated by 90 degrees along X-axis before aligning to the global coordinate frames.

image image

I read the related issues. The most similar one is https://github.com/lijx10/USIP/issues/6#issue-513906621 But he said he solved the problem by reading per 3 columns from the keypoints files. It's not the same problem.

Do you know the reason? Thanks.

lijx10 commented 4 years ago

It is likely that you are using a different coordinate system. I remember that I used camera coordinate, that is right is x, down is y, depth is z. But many dataset is not camera coordinate, for example kitti is NWU (north west up). You may want to confirm the coordinate system.

SRainGit notifications@github.com于2019年11月13日 周三下午8:26写道:

Hi,

Thanks for your work! But I found the key points don't align the original point cloud.

I pick up several frames of point cloud and transfer them into the global coordinate frame as well as the detected key points. From the picture, it seems the key points are rotated by 90 degrees somehow.

[image: image] https://user-images.githubusercontent.com/44186254/68762991-045ac880-0620-11ea-8e05-b50fd8d2fb68.png

I tried all the cases of rotating X/Y/Z 90/-90 degrees respectively but still cannot work. See the below screenshots. The key points are rotated by 90 degrees along X-axis before aligning to the global coordinate frames.

[image: image] https://user-images.githubusercontent.com/44186254/68763292-c316e880-0620-11ea-8a1e-05b29855f743.png [image: image] https://user-images.githubusercontent.com/44186254/68763348-e2ae1100-0620-11ea-847f-39d1fbccce12.png

I read the related issues. The most similar one is #6 (comment) https://github.com/lijx10/USIP/issues/6#issue-513906621 But he said he solved the problem by reading per 3 columns from the keypoints files. It's not the same problem.

Do you know the reason? Thanks.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/lijx10/USIP/issues/10?email_source=notifications&email_token=AC5G72JZL2SZZ5KLEJ6SLC3QTPW6LA5CNFSM4JM2TME2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HY75L5A, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC5G72MC52S66EXD2ZMN3RTQTPW6LANCNFSM4JM2TMEQ .

-- 黎嘉信 Jiaxin LI PhD, National University of Singapore B.S., Tsinghua University Mobile: 65-9094 1909 / 86-15201519053 Email: lijx1992@gmail.com / jli@u.nus.edu jli@nus.edu.sg

SRainGit commented 4 years ago

OK, I see. It's 90 degrees rotation for both X and Z. Now everything looks right.

Thank you very much.

LeoAnnArbor commented 3 years ago

Hi, I tried to reproduce the results of work on the KITTI dataset. I used save_keypoints.py with path to the dataset from GDrive (numpy representations of PCs) and to both models best.pth from oxford/16384-512-k1k16-2d and oxford/16384-256-k1k32-2d. When visualizing the results, I also had the similar problem as shown below: result with the output: kitti - i916 - n35 - .../USIP/processed_data/kitti-reg-test/02/002121.bin, .../USIP/output/keypoints_knn_ball/oxford_kitti_k1k16/tsf_8APLY1X2/02/002121.bin

However, I think my results are more than just a rotation.

First, when loading the key points, they are already transformed back to the velodyne coordinate based on the calibration files using the /tools/load_keypoint.m function. So the key points should already be in the NWU coordinate?

Second, the range of the original point cloud is x [-78.79, 79.56], y [-18.25, 25.04] and z [-3.02, 2.9]. The range of the key point is x [-46.08, 22.42], y [-27.67, 61.71] and z [-9.1, 11.31]. From the stats, it looks like that there is a rotation offset between x and y coordinate. But all three ranges are much greater than the original range of the z and the new key points will be off.

It would be great if anyone can help me figure out where I did wrong. Thanks in advance for the help!