| 360 | } |
| 361 | |
| 362 | int main(int argc, char* argv[]) |
| 363 | { |
| 364 | // Commented : Updated to a common interface, include, if possible, mask is type unsigned short, uses Quantification, Comments |
| 365 | // Name follows standard scheme with Class Name::Feature Name |
| 366 | // Commented 2: Updated to use automatic inclusion of list of parameters if required. |
| 367 | mitk::GIFImageDescriptionFeatures::Pointer ipCalculator = mitk::GIFImageDescriptionFeatures::New(); // Commented 2, Tested |
| 368 | mitk::GIFFirstOrderStatistics::Pointer firstOrderCalculator = mitk::GIFFirstOrderStatistics::New(); //Commented 2 |
| 369 | mitk::GIFFirstOrderHistogramStatistics::Pointer firstOrderHistoCalculator = mitk::GIFFirstOrderHistogramStatistics::New(); // Commented 2, Tested |
| 370 | mitk::GIFFirstOrderNumericStatistics::Pointer firstOrderNumericCalculator = mitk::GIFFirstOrderNumericStatistics::New(); // Commented 2, Tested |
| 371 | mitk::GIFVolumetricStatistics::Pointer volCalculator = mitk::GIFVolumetricStatistics::New(); // Commented 2, Tested |
| 372 | mitk::GIFVolumetricDensityStatistics::Pointer voldenCalculator = mitk::GIFVolumetricDensityStatistics::New(); // Commented 2, Tested |
| 373 | mitk::GIFCooccurenceMatrix::Pointer coocCalculator = mitk::GIFCooccurenceMatrix::New(); // Commented 2, Will not be tested |
| 374 | mitk::GIFCooccurenceMatrix2::Pointer cooc2Calculator = mitk::GIFCooccurenceMatrix2::New(); //Commented 2 |
| 375 | mitk::GIFNeighbouringGreyLevelDependenceFeature::Pointer ngldCalculator = mitk::GIFNeighbouringGreyLevelDependenceFeature::New(); //Commented 2, Tested |
| 376 | mitk::GIFGreyLevelRunLength::Pointer rlCalculator = mitk::GIFGreyLevelRunLength::New(); // Commented 2 |
| 377 | mitk::GIFGreyLevelSizeZone::Pointer glszCalculator = mitk::GIFGreyLevelSizeZone::New(); // Commented 2, Tested |
| 378 | mitk::GIFGreyLevelDistanceZone::Pointer gldzCalculator = mitk::GIFGreyLevelDistanceZone::New(); //Commented 2, Tested |
| 379 | mitk::GIFLocalIntensity::Pointer lociCalculator = mitk::GIFLocalIntensity::New(); //Commented 2, Tested |
| 380 | mitk::GIFIntensityVolumeHistogramFeatures::Pointer ivohCalculator = mitk::GIFIntensityVolumeHistogramFeatures::New(); // Commented 2 |
| 381 | mitk::GIFNeighbourhoodGreyToneDifferenceFeatures::Pointer ngtdCalculator = mitk::GIFNeighbourhoodGreyToneDifferenceFeatures::New(); //Commented 2, Tested |
| 382 | mitk::GIFCurvatureStatistic::Pointer curvCalculator = mitk::GIFCurvatureStatistic::New(); //Commented 2, Tested |
| 383 | |
| 384 | std::vector<mitk::AbstractGlobalImageFeature::Pointer> features; |
| 385 | features.push_back(volCalculator.GetPointer()); |
| 386 | features.push_back(voldenCalculator.GetPointer()); |
| 387 | features.push_back(curvCalculator.GetPointer()); |
| 388 | features.push_back(firstOrderCalculator.GetPointer()); |
| 389 | features.push_back(firstOrderNumericCalculator.GetPointer()); |
| 390 | features.push_back(firstOrderHistoCalculator.GetPointer()); |
| 391 | features.push_back(ivohCalculator.GetPointer()); |
| 392 | features.push_back(lociCalculator.GetPointer()); |
| 393 | features.push_back(coocCalculator.GetPointer()); |
| 394 | features.push_back(cooc2Calculator.GetPointer()); |
| 395 | features.push_back(ngldCalculator.GetPointer()); |
| 396 | features.push_back(rlCalculator.GetPointer()); |
| 397 | features.push_back(glszCalculator.GetPointer()); |
| 398 | features.push_back(gldzCalculator.GetPointer()); |
| 399 | features.push_back(ipCalculator.GetPointer()); |
| 400 | features.push_back(ngtdCalculator.GetPointer()); |
| 401 | |
| 402 | mitkCommandLineParser parser; |
| 403 | parser.setArgumentPrefix("--", "-"); |
| 404 | mitk::cl::GlobalImageFeaturesParameter param; |
| 405 | param.AddParameter(parser); |
| 406 | |
| 407 | parser.addArgument("--","-", mitkCommandLineParser::String, "---", "---", us::Any(),true); |
| 408 | for (auto cFeature : features) |
| 409 | { |
| 410 | cFeature->AddArguments(parser); |
| 411 | } |
| 412 | |
| 413 | parser.addArgument("--", "-", mitkCommandLineParser::String, "---", "---", us::Any(), true); |
| 414 | parser.addArgument("description","d",mitkCommandLineParser::String,"Text","Description that is added to the output",us::Any()); |
| 415 | parser.addArgument("direction", "dir", mitkCommandLineParser::String, "Int", "Allows to specify the direction for Cooc and RL. 0: All directions, 1: Only single direction (Test purpose), 2,3,4... Without dimension 0,1,2... ", us::Any()); |
| 416 | parser.addArgument("slice-wise", "slice", mitkCommandLineParser::String, "Int", "Allows to specify if the image is processed slice-wise (number giving direction) ", us::Any()); |
| 417 | parser.addArgument("output-mode", "omode", mitkCommandLineParser::Int, "Int", "Defines the format of the output. 0: (Default) results of an image / slice are written in a single row;" |
| 418 | " 1: results of an image / slice are written in a single column; 2: store the result of on image as structured radiomocs report (XML)."); |
| 419 |
nothing calls this directly
no test coverage detected