4
0
mirror of https://github.com/nerfstudio-project/nerfstudio.git synced 2026-11-11 18:44:21 +08:00

Bug fix for SHRenderer() (#1526)

The current SHRenderer does not apply the activation function correctly due to a typo. Now it's fixed.
This commit is contained in:
Koke_Cacao 2023-02-28 02:40:17 +08:00 committed by GitHub
parent 955497fcb2
commit edb54602da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -183,7 +183,7 @@ class SHRenderer(nn.Module):
rgb = torch.sum(sh, dim=-1) + 0.5 # [..., num_samples, 3]
if self.activation is not None:
self.activation(rgb)
rgb = self.activation(rgb)
if not self.training:
rgb = torch.nan_to_num(rgb)