desplat
desplat copied to clipboard
Dynamic Rendering
How can I render dynamics?
By default, the evaluation dataset is the clean data. However, you can enable debug mode to render the dynamic part of the training (cluttered) dataset by using the --eval_train flag.
Then before this line: https://github.com/AaltoML/desplat/blob/966b1f4ba68dc4e1fc900fc416e3f4244ee88902/desplat/desplat_model.py#L1381
you can insert the following:
if hasattr(self.dataparser_config, "eval_train") and self.dataparser_config.eval_train:
if "img_dyn" in outputs:
images_dict["img_dyn"] = outputs["img_dyn"]
images_dict["alpha_2d"] = outputs["alpha_2d"].float()
images_dict["rgb_static"] = outputs["rgb_static"]
images_dict["accumulation"] = outputs["accumulation"].float()