sxyu / svox2

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

Beta loss is not canceled out in the case of early exit #40

Closed podgorskiy closed 1 year ago

podgorskiy commented 2 years ago

In the early exit here: https://github.com/sxyu/svox2/blob/master/svox2/csrc/render_lerp_kernel_cuvol.cu#L259 , beta loss is not canceled out as in https://github.com/sxyu/svox2/blob/master/svox2/csrc/render_lerp_kernel_cuvol.cu#L375 , thus affecting the computation of gradients for background if the ray didn't hit anything.

Probably just easier to move the block at L259 before L252.

sxyu commented 1 year ago

I think you're right, thank you for the pointer to the bug (and sorry for neglecting to respond to issues)

sxyu commented 1 year ago

It has been fixed in master now