Commit 9e810e2d authored by Manuel Grizonnet's avatar Manuel Grizonnet

ENH: Example pipeline of MRF classification of an image into four classes...

ENH: Example pipeline of MRF classification of an image into four classes using the Fisher-distribution as likelihood term (contribution J Wegner)
parent cd3a8524
......@@ -9,6 +9,9 @@ TARGET_LINK_LIBRARIES(MarkovClassification1Example OTBMarkov OTBCommon OTBIO ITK
ADD_EXECUTABLE(MarkovClassification2Example MarkovClassification2Example.cxx )
TARGET_LINK_LIBRARIES(MarkovClassification2Example OTBMarkov OTBCommon OTBIO ITKNumerics)
ADD_EXECUTABLE(MarkovClassification3Example MarkovClassification3Example.cxx )
TARGET_LINK_LIBRARIES(MarkovClassification3Example OTBMarkov OTBCommon OTBIO ITKNumerics)
ADD_EXECUTABLE(MarkovRestaurationExample MarkovRestaurationExample.cxx )
TARGET_LINK_LIBRARIES(MarkovRestaurationExample OTBMarkov OTBCommon OTBIO ITKNumerics)
......@@ -52,6 +55,17 @@ ADD_TEST(maTeMarkovClassification2ExampleTest ${EXE_TESTS}
1 # true to use always the same rand() sample, false otherwise
)
ADD_TEST(maTeMarkovClassification3ExampleTest ${EXE_TESTS}
--compare-image ${EPSILON}
${BASELINE}/MarkovClassification3.png
${TEMP}/MarkovClassification3.png
MarkovClassification3ExampleTest
${INPUTDATA}/QB_Suburb.png
${TEMP}/MarkovClassification3.png
${TEMP}/MarkovClassification3_1.png
1.0 20 1.0 1
)
ADD_TEST(maTeMarkovRestaurationExampleTest ${EXE_TESTS}
--compare-image ${EPSILON}
${BASELINE}/MarkovRestauration.png
......
......@@ -55,7 +55,6 @@
#include "otbMRFSamplerRandomMAP.h"
#include "otbMRFOptimizerICM.h"
// Software Guide : EndCodeSnippet
//#include "otbMRFSamplerRandom.h"
int main(int argc, char* argv[])
{
......
This diff is collapsed.
......@@ -27,6 +27,7 @@ void RegisterTests()
{
REGISTER_TEST(MarkovClassification1ExampleTest);
REGISTER_TEST(MarkovClassification2ExampleTest);
REGISTER_TEST(MarkovClassification3ExampleTest);
REGISTER_TEST(MarkovRestaurationExampleTest);
REGISTER_TEST(MarkovRegularizationExampleTest);
}
......@@ -39,6 +40,10 @@ void RegisterTests()
#define main MarkovClassification2ExampleTest
#include "MarkovClassification2Example.cxx"
#undef main
#define main MarkovClassification3ExampleTest
#include "MarkovClassification3Example.cxx"
#undef main
#define main MarkovRestaurationExampleTest
#include "MarkovRestaurationExample.cxx"
......
......@@ -38,7 +38,7 @@ int otbMRFEnergyFisherClassificationNew(int argc, char * argv[])
return EXIT_SUCCESS;
}
int otbMRFEnergyFisherClassification(int argc, char * argv[])
{
const char * outputFile = argv[1];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment