Merge pull request #2696 from alicevision/dev/surveyInjecting

Node to inject survey points in the SFM
This commit is contained in:
Fabien Castan 2025-03-17 10:53:40 +01:00 committed by GitHub
commit 09720f6be1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 54 additions and 1 deletions

View file

@ -5,7 +5,7 @@ COLORSPACES = ["AUTO", "sRGB", "rec709", "Linear", "ACES2065-1", "ACEScg", "Line
"Log3G10 REDWideGamutRGB", "Linear Venice S-Gamut3.Cine", "S-Log3 Venice S-Gamut3.Cine", "no_conversion"] "Log3G10 REDWideGamutRGB", "Linear Venice S-Gamut3.Cine", "S-Log3 Venice S-Gamut3.Cine", "no_conversion"]
DESCRIBER_TYPES = ["sift", "sift_float", "sift_upright", "dspsift", "akaze", "akaze_liop", "akaze_mldb", "cctag3", DESCRIBER_TYPES = ["sift", "sift_float", "sift_upright", "dspsift", "akaze", "akaze_liop", "akaze_mldb", "cctag3",
"cctag4", "sift_ocv", "akaze_ocv", "tag16h5", "unknown"] "cctag4", "sift_ocv", "akaze_ocv", "tag16h5", "survey", "unknown"]
EXR_STORAGE_DATA_TYPE = ["float", "half", "halfFinite", "auto"] EXR_STORAGE_DATA_TYPE = ["float", "half", "halfFinite", "auto"]

View file

@ -80,6 +80,12 @@ It can also be used to remove specific parts of from an SfM scene (like filter a
description="Export observations.", description="Export observations.",
value=True, value=True,
), ),
desc.BoolParam(
name="surveys",
label="Surveys",
description="Export surveys.",
value=True,
),
desc.ChoiceParam( desc.ChoiceParam(
name="verboseLevel", name="verboseLevel",
label="Verbose Level", label="Verbose Level",

View file

@ -0,0 +1,47 @@
__version__ = "1.0"
from meshroom.core import desc
from meshroom.core.utils import VERBOSE_LEVEL
import json
class SfMSurveyInjecting(desc.AVCommandLineNode):
commandLine = "aliceVision_sfmSurveyInjecting {allParams}"
size = desc.DynamicNodeSize("input")
category = "Utils"
documentation = """
Use a JSON file to inject survey measurements inside the SfMData.
"""
inputs = [
desc.File(
name="input",
label="SfMData",
description="Input SfMData file.",
value="",
),
desc.File(
name="surveyFilename",
label="Survey",
description="Input JSON file containing the survey.",
value="",
),
desc.ChoiceParam(
name="verboseLevel",
label="Verbose Level",
description="Verbosity level (fatal, error, warning, info, debug, trace).",
values=VERBOSE_LEVEL,
value="info",
),
]
outputs = [
desc.File(
name="output",
label="SfMData",
description="Path to the output SfM file.",
value="{nodeCacheFolder}/sfmData.abc",
),
]