crockwell / far

[CVPR 2024 - Highlight] FAR: Flexible, Accurate and Robust 6DoF Relative Camera Pose Estimation
https://crockwell.github.io/far/
109 stars 7 forks source link

about compute_normalized_6d #2

Closed wuqun-tju closed 6 months ago

wuqun-tju commented 6 months ago

the function [compute_normalized_6d] in loftr_loss.py uses the constant vector pose_mean_6d, pose_std_6d, how to get these vectors? by the way , in code folder [mp3d_loftr], I can't find the code about 8vit code , because according to the paper, this dataset uses 8vit as transformer pose module

crockwell commented 6 months ago

Hello,

Hope that helps! Chris

wuqun-tju commented 6 months ago

Hello,

  • pose_mean_6d, pose_std_6d can be calculated by computing mean and std of 6d pose of the val set.
  • 8Pt ViT code is integrated into mp3d_loftr/src/loftr/loftr_module/transformer.py.

Hope that helps! Chris

Thank you for your reply, if I use my own dataset on your pre-model to get pose result, [pose_mean_6d, pose_std_6d] need to be modified? or is it possible not to use [pose_mean_6d, pose_std_6d]? is [pose_mean_6d, pose_std_6d] necessary?In the foler mapfree_6dreg, [pose_mean_6d, pose_std_6d] are not used, so I have some confusions

crockwell commented 6 months ago

If running inference on the pretrained model I'd continue using the same statistics it was trained on. If you want to train again from scratch I'd recompute.

Good point! It is definitely not necessary to apply mean / stdev, as we follow prior work Map-free and do not do so in this case. In some ways, it might be simpler to not apply mean / stdev. We did on Matterport as some early experiments suggested it would be slightly helpful. But in practice it probably doesn't make a huge difference.