sdfstudio icon indicating copy to clipboard operation
sdfstudio copied to clipboard

"--num-rays-per-batch" does not work for "ns-export poisson --texture-method nerf"

Open GCChen97 opened this issue 1 year ago • 2 comments

Describe the bug I found "--num-rays-per-batch" does not work for "ns-export poisson --texture-method nerf" when I tried to export mesh and constantly got CUDA out of memory.

To Reproduce Steps to reproduce the behavior: 1.ns-train nerfacto 2.ns-extract poisson --texture-method nerf --num-rays-per-batch 16384

Expected behavior Mesh texture extraction should use 16384 rays after pointcloud extraction.

Additional context Without the control of the number of sample rays when running nerfacto, it can't extract nerf texture even with 24GB VRAM. So I think this is a bug.

GCChen97 avatar Sep 08 '23 08:09 GCChen97

Hi, num-rays is updated here: https://github.com/autonomousvision/sdfstudio/blob/master/scripts/exporter.py#L248 could you check if this is indeed change the num-rays?

niujinshuchong avatar Sep 08 '23 20:09 niujinshuchong

Hi, num-rays is updated here: https://github.com/autonomousvision/sdfstudio/blob/master/scripts/exporter.py#L248 could you check if this is indeed change the num-rays?

I checked the code and this update was already there which means it did not work in my case.

I added print(ray_samples.shape) at line 306 in nerfacto_field.py and found it still sampled 32768 rays when extracting nerf texture.

GCChen97 avatar Sep 09 '23 02:09 GCChen97