Skip to content
Snippets Groups Projects
Commit da0d1c16 authored by Thomas Müller's avatar Thomas Müller
Browse files

Add exposure setting to run.py

parent 1345878f
No related branches found
No related tags found
No related merge requests found
...@@ -14,7 +14,7 @@ import commentjson as json ...@@ -14,7 +14,7 @@ import commentjson as json
import numpy as np import numpy as np
import sys import shutil
import time import time
from common import * from common import *
...@@ -24,12 +24,11 @@ from tqdm import tqdm ...@@ -24,12 +24,11 @@ from tqdm import tqdm
import pyngp as ngp # noqa import pyngp as ngp # noqa
def parse_args(): def parse_args():
parser = argparse.ArgumentParser(description="Run neural graphics primitives testbed with additional configuration & output options") parser = argparse.ArgumentParser(description="Run neural graphics primitives testbed with additional configuration & output options")
parser.add_argument("--scene", "--training_data", default="", help="The scene to load. Can be the scene's name or a full path to the training data.") parser.add_argument("--scene", "--training_data", default="", help="The scene to load. Can be the scene's name or a full path to the training data.")
parser.add_argument("--mode", default="", const="nerf", nargs="?", choices=["nerf", "sdf", "image", "volume"], help="Mode can be 'nerf', 'sdf', or 'image' or 'volume'. Inferred from the scene if unspecified.") parser.add_argument("--mode", default="", const="nerf", nargs="?", choices=["nerf", "sdf", "image", "volume"], help="Mode can be 'nerf', 'sdf', 'image' or 'volume'. Inferred from the scene if unspecified.")
parser.add_argument("--network", default="", help="Path to the network config. Uses the scene's default if unspecified.") parser.add_argument("--network", default="", help="Path to the network config. Uses the scene's default if unspecified.")
parser.add_argument("--load_snapshot", default="", help="Load this snapshot before training. recommended extension: .msgpack") parser.add_argument("--load_snapshot", default="", help="Load this snapshot before training. recommended extension: .msgpack")
...@@ -37,7 +36,8 @@ def parse_args(): ...@@ -37,7 +36,8 @@ def parse_args():
parser.add_argument("--nerf_compatibility", action="store_true", help="Matches parameters with original NeRF. Can cause slowness and worse results on some scenes.") parser.add_argument("--nerf_compatibility", action="store_true", help="Matches parameters with original NeRF. Can cause slowness and worse results on some scenes.")
parser.add_argument("--test_transforms", default="", help="Path to a nerf style transforms json from which we will compute PSNR.") parser.add_argument("--test_transforms", default="", help="Path to a nerf style transforms json from which we will compute PSNR.")
parser.add_argument("--near_distance", default=-1, type=float, help="set the distance from the camera at which training rays start for nerf. <0 means use ngp default") parser.add_argument("--near_distance", default=-1, type=float, help="Set the distance from the camera at which training rays start for nerf. <0 means use ngp default")
parser.add_argument("--exposure", default=0.0, type=float, help="Controls the brightness of the image. Positive numbers increase brightness, negative numbers decrease it.")
parser.add_argument("--screenshot_transforms", default="", help="Path to a nerf style transforms.json from which to save screenshots.") parser.add_argument("--screenshot_transforms", default="", help="Path to a nerf style transforms.json from which to save screenshots.")
parser.add_argument("--screenshot_frames", nargs="*", help="Which frame(s) to take screenshots of.") parser.add_argument("--screenshot_frames", nargs="*", help="Which frame(s) to take screenshots of.")
...@@ -103,7 +103,7 @@ if __name__ == "__main__": ...@@ -103,7 +103,7 @@ if __name__ == "__main__":
testbed = ngp.Testbed(mode) testbed = ngp.Testbed(mode)
testbed.nerf.sharpen = float(args.sharpen) testbed.nerf.sharpen = float(args.sharpen)
testbed.exposure = args.exposure
if mode == ngp.TestbedMode.Sdf: if mode == ngp.TestbedMode.Sdf:
testbed.tonemap_curve = ngp.TonemapCurve.ACES testbed.tonemap_curve = ngp.TonemapCurve.ACES
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment