From f182c6df99b6cb044ca6a303fd66eef040d323a1 Mon Sep 17 00:00:00 2001 From: AntonioMacaronio Date: Thu, 6 Feb 2025 12:27:15 -0800 Subject: [PATCH] fixing assertion issues for a successful poissonMesh and pointcloud export --- nerfstudio/scripts/exporter.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/nerfstudio/scripts/exporter.py b/nerfstudio/scripts/exporter.py index be8d48a24e..528b2f3aaf 100644 --- a/nerfstudio/scripts/exporter.py +++ b/nerfstudio/scripts/exporter.py @@ -141,8 +141,9 @@ def main(self) -> None: pipeline.datamanager, (VanillaDataManager, ParallelDataManager), ) - assert pipeline.datamanager.train_pixel_sampler is not None - pipeline.datamanager.train_pixel_sampler.num_rays_per_batch = self.num_rays_per_batch + if isinstance(pipeline.datamanager, VanillaDataManager): + assert pipeline.datamanager.train_pixel_sampler is not None + pipeline.datamanager.train_pixel_sampler.num_rays_per_batch = self.num_rays_per_batch # Whether the normals should be estimated based on the point cloud. estimate_normals = self.normal_method == "open3d" @@ -329,8 +330,9 @@ def main(self) -> None: pipeline.datamanager, (VanillaDataManager, ParallelDataManager), ) - assert pipeline.datamanager.train_pixel_sampler is not None - pipeline.datamanager.train_pixel_sampler.num_rays_per_batch = self.num_rays_per_batch + if isinstance(pipeline.datamanager, VanillaDataManager): + assert pipeline.datamanager.train_pixel_sampler is not None + pipeline.datamanager.train_pixel_sampler.num_rays_per_batch = self.num_rays_per_batch # Whether the normals should be estimated based on the point cloud. estimate_normals = self.normal_method == "open3d"