[Pattern Recognition]

SoGrayscaleCorrelationProcessing2d engine More...

`#include <ImageViz/Engines/GeometryAndMatching/PatternRecognition/SoGrayscaleCorrelationProcessing2d.h>`

Inheritance diagram for SoGrayscaleCorrelationProcessing2d:

## Classes | |

class | SbCorrelationDetail |

Results details of image correlation. More... | |

## Public Types | |

enum | CorrelationCriterion { SIGNCHANGE = 0, SUBSTRACT = 1, MULTIPLY = 2 } |

enum | OffsetMode { OFFSET_1 = 0, OFFSET_2 = 1, OFFSET_4 = 2, OFFSET_8 = 3 } |

enum | CorrelationMode { DIRECT = 0, MEAN = 1, VARIANCE = 2, MEAN_VARIANCE = 3 } |

## Public Member Functions | |

SoGrayscaleCorrelationProcessing2d () | |

## Public Attributes | |

SoSFEnum | correlationCriterion |

SoSFImageDataAdapter | inGrayImage |

SoSFImageDataAdapter | inKernelImage |

SoSFEnum | offsetMode |

SoSFEnum | correlationMode |

SoImageVizEngineOutput < SoSFImageDataAdapter, SoImageDataAdapter * > | outMatchingImage |

SoImageVizEngineAnalysisOutput < SbCorrelationDetail > | outResult |

The SoGrayscaleCorrelationProcessing2d image filter performs a correlation between a grey level image I and a grey level kernel K returning the correlation image O.

See Correlation for generalities.

Notations:

The different possibilities are presented below using a 1-D correlation between an image and kernel. In the image, the kernel appears 6 times with different contrast and luminosity.

**Figure 1: 1D image and kernel**

The 6 examples show the kernel appearing with different contrast and luminosity.

**Figure 2: Example of 1D correlations**

- The correlation is performed depending on SoGrayscaleCorrelationProcessing2d::CorrelationMode.

In this mode, we have detected 3 of the 6 patterns matching the kernel. Only high luminosity patterns have been detected. The best matching is obtained for the high contrast and luminosity pattern.

**Figure 3: Example of Multiply 1D direct correlation**

In this mode, we have detected 2 of the 6 patterns matching the kernel. Only high contrast patterns have been detected. The confidence rate is the same for the two 2 patterns.

**Figure 4: Example of Multiply 1D mean correlation**

In this mode, we have detected the 2 patterns matching the kernel with the same confidence rate.

**Figure 5: Example of Multiply 1D variance correlation**

In this mode, we have detected the 6 patterns matching the kernel with the same confidence rate.

**Figure 6: Example of Multiply 1D mean and variance correlation**

- The correlation is performed depending on SoGrayscaleCorrelationProcessing2d::CorrelationMode.

In this mode, we have detected 3 of the 6 patterns matching the kernel. Only similar luminosity patterns have been detected. The best matching is obtained with the similar contrast and luminosity pattern.

**Figure 7: Example of Difference 1D direct correlation**

In this mode, we have detected 2 of the 6 patterns matching the kernel. Only similar contrast patterns have been detected. The confidence rate is the same for the 2 patterns.

**Figure 8: Example of Difference 1D mean correlation**

In this mode, we have detected 3 of the 6 patterns matching the kernel. Only similar luminosity patterns have been detected. The confidence rate is the same for the 3 patterns.

**Figure 9: Example of Difference 1D variance correlation**

In this mode, we have detected the 6 patterns matching the kernel with the same confidence rate.

**Figure 10: Example of Difference 1D mean and variance correlation**

- The correlation is performed depending on SoGrayscaleCorrelationProcessing2d::CorrelationMode.

is the sign change criterion performed on the difference image. It corresponds to the number of sign changes calculated on every line.

**Figure 11: Example of sign correlation**

The object in the model and the object in the image have luminosity, contrast and noise differences. After normalization depending on the correlation type, the sign change criterion is applied on the difference image. The noise is supposed to be additive and zero mean. The statistical density function of the noise is supposed to be symmetrical. The best matching will correspond to the maximum number of sign changes.

This correlation gives very good results with big kernels. It was created for medical applications where images are often very noisy.

- GrayscaleCorrelationProcessing2d {

correlationCriterion | MULTIPLY |

inGrayImage | NULL |

inKernelImage | NULL |

offsetMode | OFFSET_1 |

correlationMode | DIRECT |

Library references: dcorrel mcorrel scorrel

See Correlation.

**Enumerator:***SIGNCHANGE**SUBSTRACT**MULTIPLY*See Multiply correlation.

See Correlation and for each SoGrayscaleCorrelationProcessing2d::CorrelationCriterion.

This field is ignored in the multiply correlation mode.

See Correlation

SoGrayscaleCorrelationProcessing2d::SoGrayscaleCorrelationProcessing2d | ( | ) |

Constructor.

Select the correlation operator.

Use enum CorrelationCriterion. Default is MULTIPLY

Select the normalization mode for correlation.

Use enum CorrelationMode. Default is DIRECT

The input grayscale image.

Default value is NULL. Supported types include: grayscale binary label image.

The correlation kernel.

Default value is NULL. Supported types include: grayscale binary label image.

Select the calculation offset (number of pixels).

Use enum OffsetMode. Default is OFFSET_1

SoImageVizEngineOutput<SoSFImageDataAdapter,SoImageDataAdapter*> SoGrayscaleCorrelationProcessing2d::outMatchingImage |

The output correlation image.

Default value is NULL. Supported types include: grayscale color image.

The correlation matching results.

Default value is NULL.

The documentation for this class was generated from the following file:

- ImageViz/Engines/GeometryAndMatching/PatternRecognition/SoGrayscaleCorrelationProcessing2d.h

Copyright © Thermo Fisher Scientific All rights reserved.