sxyu / svox2

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

Negative density #20

Closed limacv closed 1 year ago

limacv commented 2 years ago

After training, I find that some voxels have negative density or zero density. I was wondering how the densities are defined if it's negative. Specifically, I find the negative density when I train using the default setting on the lego dataset.

wtiandong commented 2 years ago

After training, I find that some voxels have negative density or zero density. I was wondering how the densities are defined if it's negative. Specifically, I find the negative density when I train using the default setting on the lego dataset.

I notice that negative density too. In my opinion, maybe during rendering/optimization, sigma (density) below opt.sigma_thresh (opt.density_thresh) is ignored. The density itself is optimized without any constraints, so negative density doesn't mean anything because it's rectified.

universome commented 2 years ago

@wtiandong Note that you refer to a density value after it was linearly interpolated from its surrounding voxel values. The negative density of a voxel still contributes (it just might be the case that its neighbours have high positive densities).

What I found more interesting is that if you manually clamp negative density values to 0 during training after each iteration — the training diverges! So, the model really needs negative densities to balance things out.

limacv commented 2 years ago

邮件已送达 马力的邮箱

wtiandong commented 2 years ago

@wtiandong Note that you refer to a density value after it was linearly interpolated from its surrounding voxel values. The negative density of a voxel still contributes (it just might be the case that its neighbours have high positive densities).

What I found more interesting is that if you manually clamp negative density values to 0 during training after each iteration — the training diverges! So, the model really needs negative densities to balance things out.

That's interesting! Thank you for telling me!

sxyu commented 1 year ago

Hi, when rendering the density goes through a ReLU so it will always be positive. The negative voxel values allow it to have more general boundary shapes during interpolation.