Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Whether or not there is a bounding box parameter for extracting the mesh #64

Open
Get-h1gh opened this issue Jun 30, 2024 · 3 comments
Open

Comments

@Get-h1gh
Copy link

I tested your code with my own dataset, and since the dataset is unbounded, I ended up with a very poor quality mesh. Therefore, I would like to define a bounding box to improve the quality. Now I don't know if the code contains the relevant parameters for the bounding box. If not, I need to define a bounding box myself.

@Get-h1gh Get-h1gh changed the title Whether or not there is a bounding box parameter for generating the mesh Whether or not there is a bounding box parameter for extracting the mesh Jun 30, 2024
@niujinshuchong
Copy link
Member

Hi, you can use a bbox to filter the gaussian similar to here https://github.com/autonomousvision/gaussian-opacity-fields/blob/main/scene/gaussian_model.py#L392-L397 and you need to define the bbox your self.

@qianjiating
Copy link

I tried your code related to filtering the gaussian, but it reported an error. What might be the reason?
Traceback (most recent call last):
File "/home/q/gaussian-opacity-fields/extract_mesh.py", line 203, in
extract_mesh(model.extract(args), args.iteration, pipeline.extract(args), args.filter_mesh, args.texture_mesh)
File "/home/q/gaussian-opacity-fields/extract_mesh.py", line 183, in extract_mesh
marching_tetrahedra_with_binary_search(dataset.model_path, "test", iteration, cams, gaussians, pipeline, background, kernel_size, filter_mesh, texture_mesh)
File "/home/q/anaconda3/envs/gof/lib/python3.8/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/home/q/gaussian-opacity-fields/extract_mesh.py", line 96, in marching_tetrahedra_with_binary_search
verts_list, scale_list, faces_list, _ = marching_tetrahedra(vertices, tets, sdf, points_scale[None])
File "/home/q/gaussian-opacity-fields/utils/tetmesh.py", line 189, in marching_tetrahedra
list_of_outputs = [_unbatched_marching_tetrahedra(vertices[b], tets, sdf[b], scales[b]) for b in range(vertices.shape[0])]
File "/home/q/gaussian-opacity-fields/utils/tetmesh.py", line 189, in
list_of_outputs = [_unbatched_marching_tetrahedra(vertices[b], tets, sdf[b], scales[b]) for b in range(vertices.shape[0])]
File "/home/q/gaussian-opacity-fields/utils/tetmesh.py", line 99, in _unbatched_marching_tetrahedra
occ_fx4 = occ_n[tets.reshape(-1)].reshape(-1, 4)
RuntimeError: CUDA error: device-side assert triggered

@niujinshuchong
Copy link
Member

@qianjiating Hi, I think if you need to delete cells.pt file after changing the code to filter the Gaussian.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants