This commit is contained in:
Justin committed 2023-06-21 22:25:01 +00:00
1 parent a73d892f21
commit 1d8cef26f7
3 files changed
+8 -7

No files matched your search

+2 -1
View File
@@ -168,7 +168,8 @@ method_configs["nerfacto-huge"] = TrainerConfig(
max_num_iterations=100000, max_num_iterations=100000,
mixed_precision=True, mixed_precision=True,
pipeline=VanillaPipelineConfig( pipeline=VanillaPipelineConfig(
datamanager=VanillaDataManagerConfig( # datamanager=VanillaDataManagerConfig(
datamanager=ParallelDataManagerConfig(
dataparser=NerfstudioDataParserConfig(), dataparser=NerfstudioDataParserConfig(),
train_num_rays_per_batch=16384, train_num_rays_per_batch=16384,
eval_num_rays_per_batch=4096, eval_num_rays_per_batch=4096,
+4 -4
View File
@@ -67,10 +67,10 @@ class PixelSampler:
chosen_indices = random.sample(range(len(nonzero_indices)), k=batch_size) chosen_indices = random.sample(range(len(nonzero_indices)), k=batch_size)
indices = nonzero_indices[chosen_indices] indices = nonzero_indices[chosen_indices]
else: else:
randids = torch.rand((batch_size, 3), device=device)* torch.tensor([num_images, image_height, image_width], device=device) indices = (
# indices = randids.floor() torch.rand((batch_size, 3), device=device)
# print("done floor") * torch.tensor([num_images, image_height, image_width], device=device).long()
indices = randids.long() )
return indices return indices
@@ -181,8 +181,8 @@ class RenderStateMachine(threading.Thread):
# if we got interrupted, don't send the output to the viewer # if we got interrupted, don't send the output to the viewer
continue continue
self._send_output_to_viewer(outputs) self._send_output_to_viewer(outputs)
# if self.state == "high": if self.state == "high":
# self.viewer.update_camera_poses() self.viewer.update_camera_poses()
# if we rendered a static low res, we need to self-trigger a static high-res # if we rendered a static low res, we need to self-trigger a static high-res
if self.next_action is None: 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 # if there hasn't been an action, wait for 1/target_fps seconds in case we get another move command