mirror of
https://github.com/graphdeco-inria/gaussian-splatting
synced 2024-12-02 00:55:46 +00:00
Merge pull request #1 from graphdeco-inria/main
Random background flag added
This commit is contained in:
commit
2c5c6553cb
@ -86,6 +86,7 @@ class OptimizationParams(ParamGroup):
|
||||
self.densify_from_iter = 500
|
||||
self.densify_until_iter = 15_000
|
||||
self.densify_grad_threshold = 0.0002
|
||||
self.random_background = False
|
||||
super().__init__(parser, "Optimization Parameters")
|
||||
|
||||
def get_combined_args(parser : ArgumentParser):
|
||||
|
5
train.py
5
train.py
@ -83,7 +83,10 @@ def training(dataset, opt, pipe, testing_iterations, saving_iterations, checkpoi
|
||||
# Render
|
||||
if (iteration - 1) == debug_from:
|
||||
pipe.debug = True
|
||||
render_pkg = render(viewpoint_cam, gaussians, pipe, background)
|
||||
|
||||
bg = torch.rand((3), device="cuda") if opt.random_background else background
|
||||
|
||||
render_pkg = render(viewpoint_cam, gaussians, pipe, bg)
|
||||
image, viewspace_point_tensor, visibility_filter, radii = render_pkg["render"], render_pkg["viewspace_points"], render_pkg["visibility_filter"], render_pkg["radii"]
|
||||
|
||||
# Loss
|
||||
|
Loading…
Reference in New Issue
Block a user