mirror of
https://github.com/nerfstudio-project/nerfstudio.git
synced 2026-12-07 00:09:14 +08:00
Eng/vis multi outputs (#131)
* added dynamic setting options based on graph outputs * added functionality to view different types of outputs * fixed first value set to nothing * moved try except in smaller scope * thinking I fixed the weird every so often python stops because of exception error * fixed many dropdown issue; fixed default value issue
This commit is contained in:
1 parent
ff4f1bb421
commit
069cf2c40f
4 files changed
+115
-66
No files matched your search
@@ -145,6 +145,22 @@ class NGPGraph(Graph):
|
||||
loss_dict = {"rgb_loss": rgb_loss}
|
||||
return loss_dict
|
||||
|
||||
def process_outputs_as_images(self, outputs): # pylint:disable=no-self-use
|
||||
"""Do preprocessing to make images valid"""
|
||||
# TODO: make log_test_image_outputs use this directly
|
||||
# TODO: implement across all the different graph implementations
|
||||
acc = visualization.apply_colormap(outputs["accumulation"])
|
||||
depth = visualization.apply_depth_colormap(
|
||||
outputs["depth"],
|
||||
accumulation=outputs["accumulation"],
|
||||
)
|
||||
combined_acc = torch.cat([acc], dim=1)
|
||||
outputs["accumulation"] = combined_acc
|
||||
combined_depth = torch.cat([depth], dim=1)
|
||||
outputs["depth"] = combined_depth
|
||||
depth = visualization.apply_depth_colormap(outputs["depth_occupancy_grid"])
|
||||
outputs["depth_occupancy_grid"] = combined_depth
|
||||
|
||||
def log_test_image_outputs(self, image_idx, step, batch, outputs):
|
||||
image = batch["image"]
|
||||
rgb = outputs["rgb"]
|
||||
|
||||
Reference in new issue
Block a user