From 2663ab472939afa6431197ee606145d64b8beb45 Mon Sep 17 00:00:00 2001 From: Anouk Liberge Date: Wed, 7 Aug 2019 15:15:22 +0200 Subject: [PATCH 1/6] [nodes][aliceVision] hdr: change input to accept list of folders --- meshroom/nodes/aliceVision/LDRToHDR.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/meshroom/nodes/aliceVision/LDRToHDR.py b/meshroom/nodes/aliceVision/LDRToHDR.py index 5952986546..6fff763357 100644 --- a/meshroom/nodes/aliceVision/LDRToHDR.py +++ b/meshroom/nodes/aliceVision/LDRToHDR.py @@ -7,13 +7,18 @@ class LDRToHDR(desc.CommandLineNode): commandLine = 'aliceVision_convertLDRToHDR {allParams}' inputs = [ - desc.File( - name='input', - label='Input', - description="List of LDR images or a folder containing them ", + desc.ListAttribute( + elementDesc=desc.File( + name='inputFolder', + label='Input File/Folder', + description="Folder containing LDR images", value='', uid=[0], ), + name="input", + label="Input Files or Folders", + description='Folders containing LDR images.', + ), desc.ChoiceParam( name='calibrationMethod', label='Calibration Method', From 158f02601978c40e24808a254c2a735b5a43bb6b Mon Sep 17 00:00:00 2001 From: Anouk Liberge Date: Wed, 7 Aug 2019 15:17:04 +0200 Subject: [PATCH 2/6] [nodes][aliceVision] hdr: add bool parameter for fisheye lenses --- meshroom/nodes/aliceVision/LDRToHDR.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/meshroom/nodes/aliceVision/LDRToHDR.py b/meshroom/nodes/aliceVision/LDRToHDR.py index 6fff763357..f1c0f07fe0 100644 --- a/meshroom/nodes/aliceVision/LDRToHDR.py +++ b/meshroom/nodes/aliceVision/LDRToHDR.py @@ -19,6 +19,13 @@ class LDRToHDR(desc.CommandLineNode): label="Input Files or Folders", description='Folders containing LDR images.', ), + desc.BoolParam( + name='fisheyeLens', + label='Fisheye Lens', + description="Check if fisheye lens", + value=True, + uid=[0], + ), desc.ChoiceParam( name='calibrationMethod', label='Calibration Method', From 6d377e1b7d07aa6dec7ccda20684ec8ce717d07c Mon Sep 17 00:00:00 2001 From: Anouk Liberge Date: Wed, 7 Aug 2019 15:19:43 +0200 Subject: [PATCH 3/6] [nodes][aliceVision] hdr: change descriptions and label parameters --- meshroom/nodes/aliceVision/LDRToHDR.py | 62 +++++++++++++++----------- 1 file changed, 35 insertions(+), 27 deletions(-) diff --git a/meshroom/nodes/aliceVision/LDRToHDR.py b/meshroom/nodes/aliceVision/LDRToHDR.py index f1c0f07fe0..2dc1e51fa3 100644 --- a/meshroom/nodes/aliceVision/LDRToHDR.py +++ b/meshroom/nodes/aliceVision/LDRToHDR.py @@ -12,9 +12,9 @@ class LDRToHDR(desc.CommandLineNode): name='inputFolder', label='Input File/Folder', description="Folder containing LDR images", - value='', - uid=[0], - ), + value='', + uid=[0], + ), name="input", label="Input Files or Folders", description='Folders containing LDR images.', @@ -33,62 +33,62 @@ class LDRToHDR(desc.CommandLineNode): " * linear \n" " * robertson \n" " * debevec \n" - " * beta: grossberg", + " * grossberg", values=['linear', 'robertson', 'debevec', 'grossberg'], value='linear', exclusive=True, uid=[0], - ), + ), desc.File( name='inputResponse', label='Input Response', description="external camera response file path to fuse all LDR images together.", value='', uid=[0], - ), + ), desc.StringParam( name='targetExposureImage', label='Target Exposure Image', - description="LDR image at the target exposure for the output HDR image to be centered.", + description="LDR image(s) name(s) at the target exposure for the output HDR image(s) to be centered.", value='', uid=[0], - ), + ), desc.ChoiceParam( name='calibrationWeight', label='Calibration Weight', - description="Weight function type (default, gaussian, triangle, plateau).", + description="Weight function used to calibrate camera response \n" + " * default \n" + " * gaussian \n" + " * triangle \n"" + " * plateau", value='default', values=['default', 'gaussian', 'triangle', 'plateau'], exclusive=True, uid=[0], - ), + ), desc.ChoiceParam( name='fusionWeight', label='Fusion Weight', - description="Weight function used to fuse all LDR images together (gaussian, triangle, plateau).", + description="Weight function used to fuse all LDR images together \n"" + " * gaussian \n" + " * triangle \n" + " * plateau", value='gaussian', values=['gaussian', 'triangle', 'plateau'], exclusive=True, uid=[0], - ), + ), desc.FloatParam( - name='oversaturatedCorrection', - label='Oversaturated Correction', - description="Oversaturated correction for pixels oversaturated in all images: \n" + name='expandDynamicRange', + label='Expand Dynamic Range', + description="Correction of clamped high values in dynamic range: \n" " - use 0 for no correction \n" " - use 0.5 for interior lighting \n" " - use 1 for outdoor lighting", value=1, range=(0, 1, 0.1), uid=[0], - ), - desc.File( - name='recoverPath', - label='Recover Path', - description="Path to write recovered LDR image at the target exposure by applying inverse response on HDR image.", - value='', - uid=[0], - ), + ), desc.ChoiceParam( name='verboseLevel', label='Verbose Level', @@ -97,7 +97,15 @@ class LDRToHDR(desc.CommandLineNode): values=['fatal', 'error', 'warning', 'info', 'debug', 'trace'], exclusive=True, uid=[], - ), + ), + desc.File( + name='recoverPath', + label='Output Recovered Files', + description="(debug) Folder for recovered LDR images at target exposures.", + advanced=True, + value='', + uid=[], + ), ] outputs = [ @@ -107,12 +115,12 @@ class LDRToHDR(desc.CommandLineNode): description="Output HDR image path.", value=desc.Node.internalFolder + 'hdr.exr', uid=[], - ), + ), desc.File( name='outputResponse', label='Output Response', description="Output response function path.", - value=desc.Node.internalFolder + 'response.ods', + value=desc.Node.internalFolder + 'response.csv', uid=[], - ), + ), ] From fe158917f102e0a0dea150c1e11e071a56a75045 Mon Sep 17 00:00:00 2001 From: Anouk Liberge Date: Wed, 7 Aug 2019 15:21:57 +0200 Subject: [PATCH 4/6] [nodes][aliceVision] hdr: change output parameter from path to folder --- meshroom/nodes/aliceVision/LDRToHDR.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meshroom/nodes/aliceVision/LDRToHDR.py b/meshroom/nodes/aliceVision/LDRToHDR.py index 2dc1e51fa3..2ea303eda2 100644 --- a/meshroom/nodes/aliceVision/LDRToHDR.py +++ b/meshroom/nodes/aliceVision/LDRToHDR.py @@ -111,9 +111,9 @@ class LDRToHDR(desc.CommandLineNode): outputs = [ desc.File( name='output', - label='Output', - description="Output HDR image path.", - value=desc.Node.internalFolder + 'hdr.exr', + label='Output Folder', + description="Output folder for HDR images", + value=desc.Node.internalFolder, uid=[], ), desc.File( From 6bb89397f309e141a218fddb39676321c4c31860 Mon Sep 17 00:00:00 2001 From: Anouk Liberge Date: Wed, 7 Aug 2019 15:27:41 +0200 Subject: [PATCH 5/6] [nodes][aliceVision] hdr: delete forgotten quotes --- meshroom/nodes/aliceVision/LDRToHDR.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meshroom/nodes/aliceVision/LDRToHDR.py b/meshroom/nodes/aliceVision/LDRToHDR.py index 2ea303eda2..f859e30d02 100644 --- a/meshroom/nodes/aliceVision/LDRToHDR.py +++ b/meshroom/nodes/aliceVision/LDRToHDR.py @@ -59,7 +59,7 @@ class LDRToHDR(desc.CommandLineNode): description="Weight function used to calibrate camera response \n" " * default \n" " * gaussian \n" - " * triangle \n"" + " * triangle \n" " * plateau", value='default', values=['default', 'gaussian', 'triangle', 'plateau'], @@ -69,7 +69,7 @@ class LDRToHDR(desc.CommandLineNode): desc.ChoiceParam( name='fusionWeight', label='Fusion Weight', - description="Weight function used to fuse all LDR images together \n"" + description="Weight function used to fuse all LDR images together \n" " * gaussian \n" " * triangle \n" " * plateau", From 2881b712e60085052f99070f6a0d63d4b7921ec4 Mon Sep 17 00:00:00 2001 From: Anouk Liberge Date: Thu, 8 Aug 2019 11:23:34 +0200 Subject: [PATCH 6/6] [nodes][aliceVision] hdr: clarify descriptions --- meshroom/nodes/aliceVision/LDRToHDR.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/meshroom/nodes/aliceVision/LDRToHDR.py b/meshroom/nodes/aliceVision/LDRToHDR.py index f859e30d02..ad36c17d85 100644 --- a/meshroom/nodes/aliceVision/LDRToHDR.py +++ b/meshroom/nodes/aliceVision/LDRToHDR.py @@ -22,7 +22,9 @@ class LDRToHDR(desc.CommandLineNode): desc.BoolParam( name='fisheyeLens', label='Fisheye Lens', - description="Check if fisheye lens", + description="Enable if a fisheye lens has been used.\n " + "This will improve the estimation of the Camera's Response Function by considering only the pixels in the center of the image\n" + "and thus ignore undefined/noisy pixels outside the circle defined by the fisheye lens.", value=True, uid=[0], ), @@ -57,7 +59,7 @@ class LDRToHDR(desc.CommandLineNode): name='calibrationWeight', label='Calibration Weight', description="Weight function used to calibrate camera response \n" - " * default \n" + " * default (automatically selected according to the calibrationMethod) \n" " * gaussian \n" " * triangle \n" " * plateau", @@ -70,7 +72,7 @@ class LDRToHDR(desc.CommandLineNode): name='fusionWeight', label='Fusion Weight', description="Weight function used to fuse all LDR images together \n" - " * gaussian \n" + " * gaussian \n" " * triangle \n" " * plateau", value='gaussian',