diff --git a/nerfstudio/configs/method_configs.py b/nerfstudio/configs/method_configs.py index 8c10ad579..801ef7ca3 100644 --- a/nerfstudio/configs/method_configs.py +++ b/nerfstudio/configs/method_configs.py @@ -168,7 +168,8 @@ method_configs["nerfacto-huge"] = TrainerConfig( max_num_iterations=100000, mixed_precision=True, pipeline=VanillaPipelineConfig( - datamanager=VanillaDataManagerConfig( + # datamanager=VanillaDataManagerConfig( + datamanager=ParallelDataManagerConfig( dataparser=NerfstudioDataParserConfig(), train_num_rays_per_batch=16384, eval_num_rays_per_batch=4096, diff --git a/nerfstudio/data/pixel_samplers.py b/nerfstudio/data/pixel_samplers.py index a51363a54..6a5eff0d1 100644 --- a/nerfstudio/data/pixel_samplers.py +++ b/nerfstudio/data/pixel_samplers.py @@ -67,10 +67,10 @@ class PixelSampler: chosen_indices = random.sample(range(len(nonzero_indices)), k=batch_size) indices = nonzero_indices[chosen_indices] else: - randids = torch.rand((batch_size, 3), device=device)* torch.tensor([num_images, image_height, image_width], device=device) - # indices = randids.floor() - # print("done floor") - indices = randids.long() + indices = ( + torch.rand((batch_size, 3), device=device) + * torch.tensor([num_images, image_height, image_width], device=device).long() + ) return indices diff --git a/nerfstudio/viewer_beta/render_state_machine.py b/nerfstudio/viewer_beta/render_state_machine.py index 9971338c8..bfbf9570a 100644 --- a/nerfstudio/viewer_beta/render_state_machine.py +++ b/nerfstudio/viewer_beta/render_state_machine.py @@ -181,8 +181,8 @@ class RenderStateMachine(threading.Thread): # if we got interrupted, don't send the output to the viewer continue self._send_output_to_viewer(outputs) - # if self.state == "high": - # self.viewer.update_camera_poses() + if self.state == "high": + self.viewer.update_camera_poses() # if we rendered a static low res, we need to self-trigger a static high-res if self.next_action is None: # if there hasn't been an action, wait for 1/target_fps seconds in case we get another move command