diff --git a/meshroom/aliceVision/ImageMatching.py b/meshroom/aliceVision/ImageMatching.py index e9860ee14f..8fcaa47519 100644 --- a/meshroom/aliceVision/ImageMatching.py +++ b/meshroom/aliceVision/ImageMatching.py @@ -1,4 +1,4 @@ -__version__ = "2.0" +__version__ = "2.1" from meshroom.core import desc from meshroom.core.utils import VERBOSE_LEVEL @@ -51,6 +51,7 @@ class ImageMatching(desc.AVCommandLineNode): label="Features Folders", description="Folder(s) containing the extracted features and descriptors.", exposed=True, + enabled=lambda node: node.method.value not in ("Exhaustive", "Sequential"), ), desc.ChoiceParam( name="method", diff --git a/meshroom/aliceVision/ImageMatchingMultiSfM.py b/meshroom/aliceVision/ImageMatchingMultiSfM.py index b4cda96869..4672cc7adc 100644 --- a/meshroom/aliceVision/ImageMatchingMultiSfM.py +++ b/meshroom/aliceVision/ImageMatchingMultiSfM.py @@ -1,4 +1,4 @@ -__version__ = "1.1" +__version__ = "2.1" from meshroom.core import desc from meshroom.core.utils import VERBOSE_LEVEL @@ -43,6 +43,7 @@ class ImageMatchingMultiSfM(desc.AVCommandLineNode): label="Features Folders", description="Folder(s) containing the extracted features and descriptors.", exposed=True, + enabled=lambda node: node.method.value not in ("Exhaustive", "Sequential"), ), desc.ChoiceParam( name="method", diff --git a/meshroom/cameraTracking.mg b/meshroom/cameraTracking.mg index 77244d51f6..c1a316d238 100644 --- a/meshroom/cameraTracking.mg +++ b/meshroom/cameraTracking.mg @@ -16,8 +16,8 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.1", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationSam3": "2.0", "IntrinsicsTransforming": "1.1", "KeyframeSelection": "5.0", diff --git a/meshroom/cameraTrackingDepth.mg b/meshroom/cameraTrackingDepth.mg index 3c1083bf4d..f3806588a5 100644 --- a/meshroom/cameraTrackingDepth.mg +++ b/meshroom/cameraTrackingDepth.mg @@ -17,8 +17,8 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.1", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationSam3": "2.0", "IntrinsicsTransforming": "1.1", "KeyframeSelection": "5.0", diff --git a/meshroom/cameraTrackingLegacy.mg b/meshroom/cameraTrackingLegacy.mg index 9992eeebfc..4ecdfba363 100644 --- a/meshroom/cameraTrackingLegacy.mg +++ b/meshroom/cameraTrackingLegacy.mg @@ -16,8 +16,8 @@ "FeatureExtraction": "1.3", "FeatureMatching": "2.0", "ImageDetectionPrompt": "1.0", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationBox": "1.0", "KeyframeSelection": "5.0", "MeshDecimate": "1.0", diff --git a/meshroom/cameraTrackingLidarExperimental.mg b/meshroom/cameraTrackingLidarExperimental.mg index c18e0f17f2..dc465f45a9 100644 --- a/meshroom/cameraTrackingLidarExperimental.mg +++ b/meshroom/cameraTrackingLidarExperimental.mg @@ -13,8 +13,8 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.1", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationSam3": "2.0", "InputFile": "1.0", "IntrinsicsTransforming": "1.1", diff --git a/meshroom/cameraTrackingWithoutCalibration.mg b/meshroom/cameraTrackingWithoutCalibration.mg index a5c571e72f..7fa77276cb 100644 --- a/meshroom/cameraTrackingWithoutCalibration.mg +++ b/meshroom/cameraTrackingWithoutCalibration.mg @@ -15,8 +15,8 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.1", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationSam3": "2.0", "IntrinsicsTransforming": "1.1", "KeyframeSelection": "5.0", diff --git a/meshroom/cameraTrackingWithoutCalibrationLegacy.mg b/meshroom/cameraTrackingWithoutCalibrationLegacy.mg index 2ba5c9918b..7738f14fe2 100644 --- a/meshroom/cameraTrackingWithoutCalibrationLegacy.mg +++ b/meshroom/cameraTrackingWithoutCalibrationLegacy.mg @@ -15,8 +15,8 @@ "FeatureExtraction": "1.3", "FeatureMatching": "2.0", "ImageDetectionPrompt": "1.0", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationBox": "1.0", "KeyframeSelection": "5.0", "MeshDecimate": "1.0", diff --git a/meshroom/multi-viewPhotometricStereo.mg b/meshroom/multi-viewPhotometricStereo.mg index 2c90c41923..df48337e07 100644 --- a/meshroom/multi-viewPhotometricStereo.mg +++ b/meshroom/multi-viewPhotometricStereo.mg @@ -9,7 +9,7 @@ "DepthMapFilter": "4.0", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "LightingCalibration": "1.0", "MeshFiltering": "3.0", "Meshing": "7.0", diff --git a/meshroom/nodalCameraTracking.mg b/meshroom/nodalCameraTracking.mg index fa317cab06..969d05b450 100644 --- a/meshroom/nodalCameraTracking.mg +++ b/meshroom/nodalCameraTracking.mg @@ -14,7 +14,7 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "ImageSegmentationSam3": "2.0", "IntrinsicsTransforming": "1.1", "NodalSfM": "2.1", diff --git a/meshroom/nodalCameraTrackingWithoutCalibration.mg b/meshroom/nodalCameraTrackingWithoutCalibration.mg index 796f4546db..6a21e17ef4 100644 --- a/meshroom/nodalCameraTrackingWithoutCalibration.mg +++ b/meshroom/nodalCameraTrackingWithoutCalibration.mg @@ -12,7 +12,7 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "ImageSegmentationSam3": "2.0", "IntrinsicsTransforming": "1.1", "NodalSfM": "2.1", diff --git a/meshroom/panoramaFisheyeHdr.mg b/meshroom/panoramaFisheyeHdr.mg index 5dcd1e7348..917dd38e6b 100644 --- a/meshroom/panoramaFisheyeHdr.mg +++ b/meshroom/panoramaFisheyeHdr.mg @@ -7,7 +7,7 @@ "CopyFiles": "1.3", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "LdrToHdrCalibration": "3.2", "LdrToHdrMerge": "4.2", "LdrToHdrSampling": "4.0", diff --git a/meshroom/panoramaHdr.mg b/meshroom/panoramaHdr.mg index 72c6b6ebb1..296c3c7773 100644 --- a/meshroom/panoramaHdr.mg +++ b/meshroom/panoramaHdr.mg @@ -7,7 +7,7 @@ "CopyFiles": "1.3", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "LdrToHdrCalibration": "3.2", "LdrToHdrMerge": "4.2", "LdrToHdrSampling": "4.0", diff --git a/meshroom/photogrammetry.mg b/meshroom/photogrammetry.mg index c204ff0f53..03212c93fc 100644 --- a/meshroom/photogrammetry.mg +++ b/meshroom/photogrammetry.mg @@ -10,7 +10,7 @@ "ExportImages": "1.0", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "IntrinsicsTransforming": "1.0", "MeshFiltering": "3.0", "Meshing": "7.0", diff --git a/meshroom/photogrammetryAndCameraTracking.mg b/meshroom/photogrammetryAndCameraTracking.mg index c921bfbc7d..4474ef8034 100644 --- a/meshroom/photogrammetryAndCameraTracking.mg +++ b/meshroom/photogrammetryAndCameraTracking.mg @@ -16,8 +16,8 @@ "ExportImages": "1.1", "FeatureExtraction": "1.3", "FeatureMatching": "2.1", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationSam3": "2.0", "IntrinsicsTransforming": "1.1", "KeyframeSelection": "5.0", diff --git a/meshroom/photogrammetryAndCameraTrackingLegacy.mg b/meshroom/photogrammetryAndCameraTrackingLegacy.mg index d9526a9abc..c9d1955677 100644 --- a/meshroom/photogrammetryAndCameraTrackingLegacy.mg +++ b/meshroom/photogrammetryAndCameraTrackingLegacy.mg @@ -16,8 +16,8 @@ "FeatureExtraction": "1.3", "FeatureMatching": "2.0", "ImageDetectionPrompt": "1.0", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationBox": "1.0", "KeyframeSelection": "5.0", "MeshDecimate": "1.0", diff --git a/meshroom/photogrammetryDraft.mg b/meshroom/photogrammetryDraft.mg index f6a27eb6f0..6133d5b1b2 100644 --- a/meshroom/photogrammetryDraft.mg +++ b/meshroom/photogrammetryDraft.mg @@ -7,7 +7,7 @@ "CopyFiles": "1.3", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "MeshFiltering": "3.0", "Meshing": "7.0", "PrepareDenseScene": "3.1", diff --git a/meshroom/photogrammetryLegacy.mg b/meshroom/photogrammetryLegacy.mg index 0c23b527f9..6353b4f6be 100644 --- a/meshroom/photogrammetryLegacy.mg +++ b/meshroom/photogrammetryLegacy.mg @@ -9,7 +9,7 @@ "DepthMapFilter": "4.0", "FeatureExtraction": "1.3", "FeatureMatching": "2.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "MeshFiltering": "3.0", "Meshing": "7.0", "PrepareDenseScene": "3.1", diff --git a/meshroom/photogrammetryObject.mg b/meshroom/photogrammetryObject.mg index 3b3982c3b2..dcf082622a 100644 --- a/meshroom/photogrammetryObject.mg +++ b/meshroom/photogrammetryObject.mg @@ -10,7 +10,7 @@ "FeatureExtraction": "1.3", "FeatureMatching": "2.0", "ImageDetectionPrompt": "1.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "ImageSegmentationBox": "1.0", "MeshFiltering": "3.0", "Meshing": "7.0", diff --git a/meshroom/photogrammetryObjectTurntable.mg b/meshroom/photogrammetryObjectTurntable.mg index 76a4d03bda..6422a50627 100644 --- a/meshroom/photogrammetryObjectTurntable.mg +++ b/meshroom/photogrammetryObjectTurntable.mg @@ -10,7 +10,7 @@ "FeatureExtraction": "1.3", "FeatureMatching": "2.0", "ImageDetectionPrompt": "1.0", - "ImageMatching": "2.0", + "ImageMatching": "2.1", "ImageSegmentationBox": "1.0", "MeshFiltering": "3.0", "Meshing": "7.0", diff --git a/meshroom/photogrammetryObjectTwoSides.mg b/meshroom/photogrammetryObjectTwoSides.mg index 5899233ca6..bf8b905fa3 100644 --- a/meshroom/photogrammetryObjectTwoSides.mg +++ b/meshroom/photogrammetryObjectTwoSides.mg @@ -11,8 +11,8 @@ "FeatureExtraction": "1.3", "FeatureMatching": "2.0", "ImageDetectionPrompt": "1.0", - "ImageMatching": "2.0", - "ImageMatchingMultiSfM": "1.1", + "ImageMatching": "2.1", + "ImageMatchingMultiSfM": "2.1", "ImageSegmentationBox": "1.0", "MeshFiltering": "3.0", "Meshing": "7.0", diff --git a/src/software/pipeline/main_imageMatching.cpp b/src/software/pipeline/main_imageMatching.cpp index a3a04a0656..43347a7741 100644 --- a/src/software/pipeline/main_imageMatching.cpp +++ b/src/software/pipeline/main_imageMatching.cpp @@ -30,7 +30,7 @@ // These constants define the current software version. // They must be updated when the command line is changed. -#define ALICEVISION_SOFTWARE_VERSION_MAJOR 1 +#define ALICEVISION_SOFTWARE_VERSION_MAJOR 2 #define ALICEVISION_SOFTWARE_VERSION_MINOR 1 using namespace aliceVision; @@ -83,13 +83,13 @@ int aliceVision_main(int argc, char** argv) requiredParams.add_options() ("input,i", po::value(&sfmDataFilenameA)->required(), "SfMData file.") - ("featuresFolders,f", po::value>(&featuresFolders)->multitoken()->required(), - "Path to folder(s) containing the extracted features.") ("output,o", po::value(&outputFile)->required(), "Filepath to the output file with the list of selected image pairs."); po::options_description optionalParams("Optional parameters"); optionalParams.add_options() + ("featuresFolders,f", po::value>(&featuresFolders)->multitoken(), + "Path to folder(s) containing the extracted features (not used by the Exhaustive and Sequential methods).") ("method", po::value(&method)->default_value(method), "Method used to select the image pairs to match:\n" " * VocabularyTree: select images that appear to share content\n" @@ -186,6 +186,12 @@ int aliceVision_main(int argc, char** argv) if (method != EImageMatchingMethod::EXHAUSTIVE && method != EImageMatchingMethod::SEQUENTIAL) { + if (featuresFolders.empty()) + { + ALICEVISION_LOG_ERROR("The selected image matching method requires features folders."); + return EXIT_FAILURE; + } + // load descriptor filenames aliceVision::voctree::getListOfDescriptorFiles(sfmDataA, featuresFolders, descriptorsFilesA);