sxyu / svox2

Plenoxels: Radiance Fields without Neural Networks
BSD 2-Clause "Simplified" License
2.79k stars 360 forks source link

warn("CUDA extension svox2.csrc could not be loaded! #70

Open UestcJay opened 2 years ago

UestcJay commented 2 years ago
ssh://root@123.56.109.56:22/root/anaconda3/envs/plenoxel/bin/python -u /root/lkq/svox2/opt/opt.py 

/root/lkq/svox2/data/nerf_llff_data/fern -t /root/lkq/svox2/ckpt/llff_c2f_fasttv_10e/fern -c configs/llff.json
/root/lkq/svox2/svox2/utils.py:39: UserWarning: CUDA extension svox2.csrc could not be loaded! Operations will be slow.
Please do not import svox in the svox2 source directory.
  warn("CUDA extension svox2.csrc could not be loaded! " +
Using pre-scaled images from /root/lkq/svox2/data/nerf_llff_data/fern/images_4
Loaded LLFF data /root/lkq/svox2/data/nerf_llff_data/fern 16.985296178676084 80.00209740336334
recentered (3, 4)
[1.3765233 5.48648  ]
Overriding offset 250-> 250
dmin = 1.376523, dmax = 5.486480, invz = 0, offset = 250
100%|███████████████████████████████████████████| 17/17 [00:00<00:00, 27.15it/s]
z_bounds from LLFF: [1.3765232563018799, 5.486480236053467] (not used)
scene_radius [1.496031746031746, 1.6613756613756614, 1.0]
 Generating rays, scaling factor 1
Using pre-scaled images from /root/lkq/svox2/data/nerf_llff_data/fern/images_4
Loaded LLFF data /root/lkq/svox2/data/nerf_llff_data/fern 16.985296178676084 80.00209740336334
recentered (3, 4)
[1.3765233 5.48648  ]
Overriding offset 250-> 250
dmin = 1.376523, dmax = 5.486480, invz = 0, offset = 250
100%|█████████████████████████████████████████████| 3/3 [00:00<00:00, 29.27it/s]
100%|██████████████████████████████████████| 120/120 [00:00<00:00, 84662.15it/s]
z_bounds from LLFF: [1.3765232563018799, 5.486480236053467] (not used)
scene_radius [1.496031746031746, 1.6613756613756614, 1.0]
Morton code requires a cube grid of power-of-2 size, ignoring...
Render options RenderOptions(backend='cuvol', background_brightness=0.5, step_size=0.5, sigma_thresh=1e-08, stop_thresh=1e-07, last_sample_opaque=False, near_clip=0.0, use_spheric_clip=False, random_sigma_std=0.0, random_sigma_std_background=0.0)
 Selecting random rays
Eval step
  0%|                                                     | 0/3 [00:00<?, ?it/s]
Traceback (most recent call last):
  File "/root/lkq/svox2/opt/opt.py", line 471, in <module>
    eval_step()
  File "/root/lkq/svox2/opt/opt.py", line 406, in eval_step
    rgb_pred_test = grid.volume_render_image(cam, use_kernel=True)
  File "/root/lkq/svox2/svox2/svox2.py", line 1159, in volume_render_image
    if self.basis_type != BASIS_TYPE_MLP and imrend_fn_name in _C.__dict__ and not torch.is_grad_enabled() and not return_raylen:
AttributeError: 'NoneType' object has no attribute '__dict__'

many thanks for your great work! after I pip install ., python opt.py, the error occurs, can you give me some help?

RyannDaGreat commented 1 year ago

I have the same problem

kravrolens commented 1 year ago

cy

muxizju commented 1 year ago

Reason: the compiled package name and the folder name in the project are both "svox2", they will be mis-imported when using in the opt.py script. Solution: aftering "pip install .", just simply remove the folder"./svox2/svox2". Then everything will work

YujieOuO commented 1 year ago

same problem