Rename field heads

This commit is contained in:
Matt Tancik committed 2022-04-15 14:38:26 -07:00
1 parent 5e24cbf6fe
commit 8e852c5771
3 files changed
+19 -19

No files matched your search

@@ -5,15 +5,15 @@ import pytest
import torch
from torch import nn
from mattport.nerf.field_modules import render_heads
from mattport.nerf.field_modules import field_outputs
def test_render_head():
def test_field_output():
"""Test rgb render head"""
in_dim = 6
out_dim = 4
activation = nn.ReLU()
render_head = render_heads.RenderHead(in_dim=in_dim, out_dim=out_dim, activation=activation)
render_head = field_outputs.FieldOutput(in_dim=in_dim, out_dim=out_dim, activation=activation)
assert render_head.get_out_dim() == out_dim
x = torch.ones((9, in_dim))
@@ -27,9 +27,9 @@ def test_render_head():
def test_density_head():
"""Test rgb render head"""
"""Test rgb output"""
in_dim = 6
density_head = render_heads.DensityHead(in_dim)
density_head = field_outputs.DensityFieldOutput(in_dim)
assert density_head.get_out_dim() == 1
x = torch.ones((9, in_dim))
@@ -42,9 +42,9 @@ def test_density_head():
def test_rgb_head():
"""Test rgb render head"""
"""Test rgb output"""
in_dim = 6
rgb_head = render_heads.RGBHead(in_dim)
rgb_head = field_outputs.RGBFieldOutput(in_dim)
assert rgb_head.get_out_dim() == 3
x = torch.ones((9, in_dim))