nerfstudio-project / viser

Web-based 3D visualization + Python
https://viser.studio/latest
Apache License 2.0
702 stars 42 forks source link

Matrix not positive #263

Open LaFeuilleMorte opened 1 month ago

LaFeuilleMorte commented 1 month ago

Thanks for open-sourcing this great work! I've encountered "matrix not positive defined" error in using cholesky decomposition here. As I dig deeper, I found that the covariance matrix has NaN values. So I replace NaN with 0, and add a small eye matrix to make the matrix positive defined. The ply has been successfully loaded but it failed to render the ply file. Can you give me some suggestions. This https://github.com/mkkellogg/GaussianSplats3D/ viewer is able to render my ply file successfully.

image
LaFeuilleMorte commented 1 month ago

Oh, I think I've found what's wrong in the code. My ply file has gaussians that contains NaN values in the scale and rotate. So it will trigger the matrix not positive defined error. One easy fix would be filtering gaussians that have bad values:

image
brentyi commented 1 month ago

Interesting yeah, we currently assume all covariance inputs are valid. Can I ask where you got your PLY file from? We could also add the filtering on our end.

If you have any other issues with the Gaussian rendering please do let us know, it's very much in an experimental phase right now!

LaFeuilleMorte commented 1 month ago

Interesting yeah, we currently assume all covariance inputs are valid. Can I ask where you got your PLY file from? We could also add the filtering on our end.

If you have any other issues with the Gaussian rendering please do let us know, it's very much in an experimental phase right now!

Not the vanilla 3DGS. It's from PGSR: PGSR: Planar-based Gaussian Splatting for Efficient and High-Fidelity Surface Reconstruction. I guess this method might introduce some gaussians with NaN values during optimization.