-
Notifications
You must be signed in to change notification settings - Fork 111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to get viewmat from c2w and intrinsic? #162
Comments
@baoachun the view matrix is the world to camera (w2c) transform. So if you have a c2w you can invert this to obtain a w2c. The method linked above is actually the same as taking the inverse of a 3x4 camera matrix. Note the c2w has both the rotation and translation component appended, which is the convention often used. Here the inverse is just computed manually: the transpose of the SO(3) rotation matrix component is taken probably for speed and numerical efficiency reasons (instead of calling inv(c2w[:3,;3)). The inverse of the translation component also follows from math. |
@maturk Hi, thank you for your reply. However, I'm now encountering another issue. The original 3DGS can converge, but it fails to converge when using gsplat. I saved the rendering results and found that they are all black. I suspect that the input parameters are not set correctly. Could you please help me check if the following settings are correct? 3DGS
gsplat
|
@baoachun given the same |
@ivanpuhachov The two methods are identical in all settings except for the rendering method. I suspect there might be an issue with the camera parameter settings, so I'd like to know how to obtain the relevant input parameters for gsplat from the c2w and intrinsic matrices. |
I meet the similiar problem probably. I've checked my input model on another gaussian splatting implement and got the expected rendering result. But when I try on gsplat, it returns blank image with only bg color. I check the returns of I upload some code in my repository to compare the result between gsplat and my temporary implement. My installed gsplat version is 0.1.11. Appreciation for your attention! |
I've run your code and I have a few comments:
After these fixes the code gsplat and your manual check output the same values |
I fix my code and find that in my pre-trained model no gaussian is inside the view frustum. Maybe it's because of my incorrect data loading. Thanks for your comments! |
@ivanpuhachov Hello, based on the discussion above, I've realized that my model also suffers from the issue of having no Gaussian points within the current view. How can I debug this situation? Is there a way to visualize the view under the current camera parameters? Thank you. |
I'm currently trying to implement 3D rendering using this library, but I'm confused about how to set the
viewmat
. I have thec2w
matrix and the intrinsic matrix . According to the official documentation, I initially thought that taking the inverse ofc2w
would give me theviewmat
. However, the calculation method here does not directly involve taking the inverse ofc2w
. Can you provide a more detailed example to explain the process of calculatingviewmat
?https://github.com/Harr7y/nerfstudio/blob/37948b360b108f8e30b2122d8eab220bf1443965/nerfstudio/models/splatfacto.py#L682
The text was updated successfully, but these errors were encountered: