nerfstudio icon indicating copy to clipboard operation
nerfstudio copied to clipboard

Viewer crash

Open jb-ye opened this issue 2 months ago • 2 comments

Describe the bug

I am training splatfacto, during which I open the viewer. In the viewer, I tried to reset the resolution from default 512 to 1024, I got the above crash and the viewer basically freeze. It happens during early stage of training when coarse-to-fine training is active.

Exception in thread Thread-11:
Traceback (most recent call last):
  File "/opt/conda/envs/nerfstudio/lib/python3.10/threading.py", line 1009, in _bootstrap_inner
    self.run()
  File "/eames-efs/eames-nerf/jianboye/projects/nerfstudio/nerfstudio/viewer/render_state_machine.py", line 222, in run
    outputs = self._render_img(action.camera_state)
  File "/eames-efs/eames-nerf/jianboye/projects/nerfstudio/nerfstudio/viewer/render_state_machine.py", line 182, in _render_img
    scale = min(desired_depth_pixels / current_depth_pixels, 1.0)
ZeroDivisionError: division by zero

jb-ye avatar Apr 10 '24 16:04 jb-ye

@brentyi This seems related to the depth rendering scaling factor

kerrj avatar Apr 11 '24 18:04 kerrj

Yeah, the error implies we're getting 0 from current_depth_pixels = outputs["depth"].shape[0] * outputs["depth"].shape[1]. Probably there's an edge case in _calculate_image_res, or how client camera aspect ratios are read/used?

brentyi avatar Apr 11 '24 20:04 brentyi

It also happen to me with same exact error message...

ichsan2895 avatar Apr 28 '24 15:04 ichsan2895