From cee293d254ef05554b95ac12f5edc1bf86a1a050 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Candice=20Bent=C3=A9jac?= Date: Wed, 25 Jan 2023 09:37:26 +0100 Subject: [PATCH] [nodes] KeyframeSelection: Add options to visualise computed motion vectors Add two debug options to export the computed motion vectors in HSV as PNG images. --- .../nodes/aliceVision/KeyframeSelection.py | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/meshroom/nodes/aliceVision/KeyframeSelection.py b/meshroom/nodes/aliceVision/KeyframeSelection.py index f049ea5a..43a873b7 100644 --- a/meshroom/nodes/aliceVision/KeyframeSelection.py +++ b/meshroom/nodes/aliceVision/KeyframeSelection.py @@ -233,6 +233,32 @@ You can extract frames at regular interval by configuring only the min/maxFrameS ) ] ), + desc.GroupAttribute( + name="opticalFlowVisualisation", + label="Optical Flow Visualisation", + description="Visualise the motion vectors for each input frame in HSV.", + group=None, # skip group from command line + enabled=lambda node: node.debugOptions.enabled, + groupDesc=[ + desc.BoolParam( + name="exportFlowVisualisation", + label="Visualise Optical Flow", + description="Export each frame's optical flow HSV visualisation as PNG images.", + value=False, + uid=[0], + enabled=lambda node: node.debugOptions.opticalFlowVisualisation.enabled + ), + desc.BoolParam( + name="flowVisualisationOnly", + label="Only Visualise Optical Flow", + description="Export each frame's optical flow HSV visualisation as PNG images, but do not perform any score computation or frame selection.\n" + "If this option is selected, all the other options will be ignored.", + value=False, + uid=[0], + enabled=lambda node: node.debugOptions.opticalFlowVisualisation.enabled + ) + ] + ), desc.BoolParam( name="skipSelection", label="Skip Frame Selection",