moving around files (#616)

moved around files
This commit is contained in:
Ethan Weber authored and GitHub committed 2022-10-02 16:54:34 -07:00
1 parent 9d15ba6a2a
commit c20fed83bb
61 files changed
+226 -332

No files matched your search

@@ -31,8 +31,8 @@ from nerfstudio.cameras.rays import RayBundle
from nerfstudio.configs.base_config import InstantiateConfig
from nerfstudio.configs.config_utils import to_immutable_dict
from nerfstudio.data.scene_box import SceneBox
from nerfstudio.engine.callbacks import TrainingCallback, TrainingCallbackAttributes
from nerfstudio.model_components.scene_colliders import NearFarCollider
from nerfstudio.utils.callbacks import TrainingCallback, TrainingCallbackAttributes
# Model related configs
+12 -12
View File
@@ -30,22 +30,22 @@ from torchmetrics.functional import structural_similarity_index_measure
from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.engine.callbacks import (
TrainingCallback,
TrainingCallbackAttributes,
TrainingCallbackLocation,
)
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.fields.instant_ngp_field import TCNNInstantNGPField
from nerfstudio.model_components.loss import MSELoss
from nerfstudio.model_components.ray_sampler import VolumetricSampler
from nerfstudio.model_components.losses import MSELoss
from nerfstudio.model_components.ray_samplers import VolumetricSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
RGBRenderer,
)
from nerfstudio.models.base import Model, ModelConfig
from nerfstudio.utils import colors, visualization
from nerfstudio.utils.callbacks import (
TrainingCallback,
TrainingCallbackAttributes,
TrainingCallbackLocation,
)
from nerfstudio.models.base_model import Model, ModelConfig
from nerfstudio.utils import colormaps, colors
@dataclass
@@ -223,12 +223,12 @@ class NGPModel(Model):
image = batch["image"].to(self.device)
rgb = outputs["rgb"]
acc = visualization.apply_colormap(outputs["accumulation"])
depth = visualization.apply_depth_colormap(
acc = colormaps.apply_colormap(outputs["accumulation"])
depth = colormaps.apply_depth_colormap(
outputs["depth"],
accumulation=outputs["accumulation"],
)
alive_ray_mask = visualization.apply_colormap(outputs["alive_ray_mask"])
alive_ray_mask = colormaps.apply_colormap(outputs["alive_ray_mask"])
combined_rgb = torch.cat([image, rgb], dim=1)
combined_acc = torch.cat([acc], dim=1)
+10 -10
View File
@@ -26,18 +26,18 @@ from torchmetrics.functional import structural_similarity_index_measure
from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.field_components.encoding import NeRFEncoding
from nerfstudio.field_components.encodings import NeRFEncoding
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.fields.nerf_field import NeRFField
from nerfstudio.model_components.loss import MSELoss
from nerfstudio.model_components.ray_sampler import PDFSampler, UniformSampler
from nerfstudio.fields.vanilla_nerf_field import NeRFField
from nerfstudio.model_components.losses import MSELoss
from nerfstudio.model_components.ray_samplers import PDFSampler, UniformSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
RGBRenderer,
)
from nerfstudio.models.base import Model, ModelConfig
from nerfstudio.utils import colors, misc, visualization
from nerfstudio.models.base_model import Model, ModelConfig
from nerfstudio.utils import colormaps, colors, misc
class MipNerfModel(Model):
@@ -150,15 +150,15 @@ class MipNerfModel(Model):
image = batch["image"].to(outputs["rgb_coarse"].device)
rgb_coarse = outputs["rgb_coarse"]
rgb_fine = outputs["rgb_fine"]
acc_coarse = visualization.apply_colormap(outputs["accumulation_coarse"])
acc_fine = visualization.apply_colormap(outputs["accumulation_fine"])
depth_coarse = visualization.apply_depth_colormap(
acc_coarse = colormaps.apply_colormap(outputs["accumulation_coarse"])
acc_fine = colormaps.apply_colormap(outputs["accumulation_fine"])
depth_coarse = colormaps.apply_depth_colormap(
outputs["depth_coarse"],
accumulation=outputs["accumulation_coarse"],
near_plane=self.config.collider_params["near_plane"],
far_plane=self.config.collider_params["far_plane"],
)
depth_fine = visualization.apply_depth_colormap(
depth_fine = colormaps.apply_depth_colormap(
outputs["depth_fine"],
accumulation=outputs["accumulation_fine"],
near_plane=self.config.collider_params["near_plane"],
+10 -11
View File
@@ -27,20 +27,19 @@ from torchmetrics.functional import structural_similarity_index_measure
from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.field_components.encoding import NeRFEncoding
from nerfstudio.field_components.encodings import NeRFEncoding
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.field_components.spatial_distortions import SceneContraction
from nerfstudio.fields.nerf_field import NeRFField
from nerfstudio.model_components.loss import MSELoss
from nerfstudio.model_components.ray_losses import distortion_loss
from nerfstudio.model_components.ray_sampler import PDFSampler, UniformSampler
from nerfstudio.fields.vanilla_nerf_field import NeRFField
from nerfstudio.model_components.losses import MSELoss, distortion_loss
from nerfstudio.model_components.ray_samplers import PDFSampler, UniformSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
RGBRenderer,
)
from nerfstudio.models.base import Model, ModelConfig
from nerfstudio.utils import colors, misc, visualization
from nerfstudio.models.base_model import Model, ModelConfig
from nerfstudio.utils import colormaps, colors, misc
class MipNerf360Model(Model):
@@ -165,15 +164,15 @@ class MipNerf360Model(Model):
image = batch["image"].to(outputs["rgb_coarse"].device)
rgb_coarse = outputs["rgb_coarse"]
rgb_fine = outputs["rgb_fine"]
acc_coarse = visualization.apply_colormap(outputs["accumulation_coarse"])
acc_fine = visualization.apply_colormap(outputs["accumulation_fine"])
depth_coarse = visualization.apply_depth_colormap(
acc_coarse = colormaps.apply_colormap(outputs["accumulation_coarse"])
acc_fine = colormaps.apply_colormap(outputs["accumulation_fine"])
depth_coarse = colormaps.apply_depth_colormap(
outputs["depth_coarse"],
accumulation=outputs["accumulation_coarse"],
near_plane=self.config.collider_params["near_plane"],
far_plane=self.config.collider_params["far_plane"],
)
depth_fine = visualization.apply_depth_colormap(
depth_fine = colormaps.apply_depth_colormap(
outputs["depth_fine"],
accumulation=outputs["accumulation_fine"],
near_plane=self.config.collider_params["near_plane"],
+12 -12
View File
@@ -29,25 +29,25 @@ from torchmetrics.functional import structural_similarity_index_measure
from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.engine.callbacks import (
TrainingCallback,
TrainingCallbackAttributes,
TrainingCallbackLocation,
)
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.field_components.spatial_distortions import SceneContraction
from nerfstudio.fields.density_fields import HashMLPDensityField
from nerfstudio.fields.nerfacto_field import TCNNNerfactoField
from nerfstudio.model_components.loss import MSELoss, distortion_loss, interlevel_loss
from nerfstudio.model_components.ray_sampler import ProposalNetworkSampler
from nerfstudio.model_components.losses import MSELoss, distortion_loss, interlevel_loss
from nerfstudio.model_components.ray_samplers import ProposalNetworkSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
RGBRenderer,
)
from nerfstudio.model_components.scene_colliders import NearFarCollider
from nerfstudio.models.base import Model, ModelConfig
from nerfstudio.utils import colors, visualization
from nerfstudio.utils.callbacks import (
TrainingCallback,
TrainingCallbackAttributes,
TrainingCallbackLocation,
)
from nerfstudio.models.base_model import Model, ModelConfig
from nerfstudio.utils import colormaps, colors
@dataclass
@@ -224,8 +224,8 @@ class NerfactoModel(Model):
image = batch["image"].to(self.device)
rgb = outputs["rgb"]
acc = visualization.apply_colormap(outputs["accumulation"])
depth = visualization.apply_depth_colormap(
acc = colormaps.apply_colormap(outputs["accumulation"])
depth = colormaps.apply_depth_colormap(
outputs["depth"],
accumulation=outputs["accumulation"],
)
@@ -250,7 +250,7 @@ class NerfactoModel(Model):
for i in range(self.config.num_proposal_network_iterations):
key = f"prop_depth_{i}"
prop_depth_i = visualization.apply_depth_colormap(
prop_depth_i = colormaps.apply_depth_colormap(
outputs[key],
accumulation=outputs["accumulation"],
)
+10 -10
View File
@@ -28,12 +28,12 @@ from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.configs.config_utils import to_immutable_dict
from nerfstudio.field_components.encoding import NeRFEncoding
from nerfstudio.field_components.encodings import NeRFEncoding
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.fields.nerf_field import NeRFField
from nerfstudio.fields.nerfw_field import VanillaNerfWField
from nerfstudio.model_components.loss import MSELoss
from nerfstudio.model_components.ray_sampler import PDFSampler, UniformSampler
from nerfstudio.fields.vanilla_nerf_field import NeRFField
from nerfstudio.model_components.losses import MSELoss
from nerfstudio.model_components.ray_samplers import PDFSampler, UniformSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
@@ -41,8 +41,8 @@ from nerfstudio.model_components.renderers import (
UncertaintyRenderer,
)
from nerfstudio.model_components.scene_colliders import AABBBoxCollider
from nerfstudio.models.base import Model, VanillaModelConfig
from nerfstudio.utils import colors, misc, visualization
from nerfstudio.models.base_model import Model, VanillaModelConfig
from nerfstudio.utils import colormaps, colors, misc
@dataclass
@@ -255,10 +255,10 @@ class NerfWModel(Model):
depth_fine_static = outputs["depth_fine_static"]
uncertainty = outputs["uncertainty"]
depth_coarse = visualization.apply_depth_colormap(depth_coarse)
depth_fine = visualization.apply_depth_colormap(depth_fine)
depth_fine_static = visualization.apply_depth_colormap(depth_fine_static)
uncertainty = visualization.apply_depth_colormap(uncertainty)
depth_coarse = colormaps.apply_depth_colormap(depth_coarse)
depth_fine = colormaps.apply_depth_colormap(depth_fine)
depth_fine_static = colormaps.apply_depth_colormap(depth_fine_static)
uncertainty = colormaps.apply_depth_colormap(uncertainty)
row0 = torch.cat([image, uncertainty, torch.ones_like(rgb_fine)], dim=-2)
row1 = torch.cat([rgb_fine, rgb_fine_static, rgb_coarse], dim=-2)
+3 -3
View File
@@ -24,13 +24,13 @@ from torch import nn
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.data.dataparsers.base_dataparser import Semantics
from nerfstudio.field_components.encoding import NeRFEncoding
from nerfstudio.field_components.encodings import NeRFEncoding
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.fields.nerf_field import NeRFField
from nerfstudio.fields.semantic_nerf_field import SemanticNerfField
from nerfstudio.fields.vanilla_nerf_field import NeRFField
from nerfstudio.model_components.renderers import SemanticRenderer
from nerfstudio.model_components.scene_colliders import AABBBoxCollider
from nerfstudio.models.base import ModelConfig
from nerfstudio.models.base_model import ModelConfig
from nerfstudio.models.vanilla_nerf import NeRFModel
from nerfstudio.utils import misc
+13 -13
View File
@@ -30,24 +30,24 @@ from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.configs.config_utils import to_immutable_dict
from nerfstudio.engine.callbacks import (
TrainingCallback,
TrainingCallbackAttributes,
TrainingCallbackLocation,
)
from nerfstudio.engine.optimizers import Optimizers
from nerfstudio.field_components.encoding import TensorVMEncoding
from nerfstudio.field_components.encodings import TensorVMEncoding
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.fields.nerf_field import NeRFField
from nerfstudio.model_components.loss import L1Loss, MSELoss
from nerfstudio.model_components.ray_sampler import PDFSampler, UniformSampler
from nerfstudio.fields.vanilla_nerf_field import NeRFField
from nerfstudio.model_components.losses import L1Loss, MSELoss
from nerfstudio.model_components.ray_samplers import PDFSampler, UniformSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
RGBRenderer,
)
from nerfstudio.models.base import Model, VanillaModelConfig
from nerfstudio.utils import colors, misc, visualization
from nerfstudio.utils.callbacks import (
TrainingCallback,
TrainingCallbackAttributes,
TrainingCallbackLocation,
)
from nerfstudio.models.base_model import Model, VanillaModelConfig
from nerfstudio.utils import colormaps, colors, misc
@dataclass
@@ -215,8 +215,8 @@ class TensoRFModel(Model):
) -> Tuple[Dict[str, float], Dict[str, torch.Tensor]]:
image = batch["image"].to(outputs["rgb"].device)
rgb = outputs["rgb"]
acc = visualization.apply_colormap(outputs["accumulation"])
depth = visualization.apply_depth_colormap(
acc = colormaps.apply_colormap(outputs["accumulation"])
depth = colormaps.apply_depth_colormap(
outputs["depth"],
accumulation=outputs["accumulation"],
near_plane=self.config.collider_params["near_plane"],
+10 -10
View File
@@ -27,18 +27,18 @@ from torchmetrics.functional import structural_similarity_index_measure
from torchmetrics.image.lpip import LearnedPerceptualImagePatchSimilarity
from nerfstudio.cameras.rays import RayBundle
from nerfstudio.field_components.encoding import NeRFEncoding
from nerfstudio.field_components.encodings import NeRFEncoding
from nerfstudio.field_components.field_heads import FieldHeadNames
from nerfstudio.fields.nerf_field import NeRFField
from nerfstudio.model_components.loss import MSELoss
from nerfstudio.model_components.ray_sampler import PDFSampler, UniformSampler
from nerfstudio.fields.vanilla_nerf_field import NeRFField
from nerfstudio.model_components.losses import MSELoss
from nerfstudio.model_components.ray_samplers import PDFSampler, UniformSampler
from nerfstudio.model_components.renderers import (
AccumulationRenderer,
DepthRenderer,
RGBRenderer,
)
from nerfstudio.models.base import Model, ModelConfig
from nerfstudio.utils import colors, misc, visualization
from nerfstudio.models.base_model import Model, ModelConfig
from nerfstudio.utils import colormaps, colors, misc
class NeRFModel(Model):
@@ -159,15 +159,15 @@ class NeRFModel(Model):
image = batch["image"].to(outputs["rgb_coarse"].device)
rgb_coarse = outputs["rgb_coarse"]
rgb_fine = outputs["rgb_fine"]
acc_coarse = visualization.apply_colormap(outputs["accumulation_coarse"])
acc_fine = visualization.apply_colormap(outputs["accumulation_fine"])
depth_coarse = visualization.apply_depth_colormap(
acc_coarse = colormaps.apply_colormap(outputs["accumulation_coarse"])
acc_fine = colormaps.apply_colormap(outputs["accumulation_fine"])
depth_coarse = colormaps.apply_depth_colormap(
outputs["depth_coarse"],
accumulation=outputs["accumulation_coarse"],
near_plane=self.config.collider_params["near_plane"],
far_plane=self.config.collider_params["far_plane"],
)
depth_fine = visualization.apply_depth_colormap(
depth_fine = colormaps.apply_depth_colormap(
outputs["depth_fine"],
accumulation=outputs["accumulation_fine"],
near_plane=self.config.collider_params["near_plane"],