Show / Hide Table of Contents

Class ShapeContextDistanceExtractor

Implementation of the Shape Context descriptor and matching algorithm

Inheritance
System.Object
DisposableObject
DisposableCvObject
Algorithm
ShapeDistanceExtractor
ShapeContextDistanceExtractor
Implements
ICvPtrHolder
Inherited Members
ShapeDistanceExtractor.ComputeDistance(InputArray, InputArray)
Algorithm.Write(FileStorage)
Algorithm.Read(FileNode)
Algorithm.Empty
Algorithm.Save(String)
Algorithm.GetDefaultName()
DisposableCvObject.ptr
DisposableCvObject.CvPtr
DisposableObject.DataHandle
DisposableObject.IsDisposed
DisposableObject.IsEnabledDispose
DisposableObject.AllocatedMemory
DisposableObject.AllocatedMemorySize
DisposableObject.Dispose()
DisposableObject.Dispose(Boolean)
DisposableObject.AllocGCHandle(Object)
DisposableObject.AllocMemory(Int32)
DisposableObject.NotifyMemoryPressure(Int64)
DisposableObject.ThrowIfDisposed()
Namespace: OpenCvSharp
Assembly: OpenCvSharp.dll
Syntax
public class ShapeContextDistanceExtractor : ShapeDistanceExtractor, ICvPtrHolder
Remarks

proposed by Belongie et al. in "Shape Matching and Object Recognition Using Shape Contexts" (PAMI2002). This implementation is packaged in a generic scheme, in order to allow you the implementation of the common variations of the original pipeline.

Constructors

| Improve this Doc View Source

ShapeContextDistanceExtractor(IntPtr)

Declaration
protected ShapeContextDistanceExtractor(IntPtr p)
Parameters
Type Name Description
IntPtr p

Properties

| Improve this Doc View Source

AngularBins

The number of angular bins in the shape context descriptor.

Declaration
public int AngularBins { get; set; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

BendingEnergyWeight

The weight of the Bending Energy in the final distance value.

Declaration
public float BendingEnergyWeight { get; set; }
Property Value
Type Description
System.Single
| Improve this Doc View Source

ImageAppearanceWeight

The weight of the appearance cost in the final distance value.

Declaration
public float ImageAppearanceWeight { get; set; }
Property Value
Type Description
System.Single
| Improve this Doc View Source

InnerRadius

The value of the inner radius.

Declaration
public float InnerRadius { get; set; }
Property Value
Type Description
System.Single
| Improve this Doc View Source

Iterations

Declaration
public int Iterations { get; set; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

OuterRadius

The value of the outer radius.

Declaration
public float OuterRadius { get; set; }
Property Value
Type Description
System.Single
| Improve this Doc View Source

RadialBins

The number of radial bins in the shape context descriptor.

Declaration
public int RadialBins { get; set; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

RotationInvariant

Declaration
public bool RotationInvariant { get; set; }
Property Value
Type Description
System.Boolean
| Improve this Doc View Source

ShapeContextWeight

The weight of the shape context distance in the final distance value.

Declaration
public float ShapeContextWeight { get; set; }
Property Value
Type Description
System.Single
| Improve this Doc View Source

StdDev

The value of the standard deviation for the Gaussian window for the image appearance cost.

Declaration
public float StdDev { get; set; }
Property Value
Type Description
System.Single

Methods

| Improve this Doc View Source

Create(Int32, Int32, Single, Single, Int32)

Complete constructor

Declaration
public static ShapeContextDistanceExtractor Create(int nAngularBins = 12, int nRadialBins = 4, float innerRadius = 0.2F, float outerRadius = 2F, int iterations = 3)
Parameters
Type Name Description
System.Int32 nAngularBins

The number of angular bins in the shape context descriptor.

System.Int32 nRadialBins

The number of radial bins in the shape context descriptor.

System.Single innerRadius

The value of the inner radius.

System.Single outerRadius

The value of the outer radius.

System.Int32 iterations
Returns
Type Description
ShapeContextDistanceExtractor
| Improve this Doc View Source

DisposeManaged()

Releases managed resources

Declaration
protected override void DisposeManaged()
Overrides
DisposableObject.DisposeManaged()
| Improve this Doc View Source

DisposeUnmanaged()

Declaration
protected override void DisposeUnmanaged()
Overrides
DisposableCvObject.DisposeUnmanaged()
| Improve this Doc View Source

Get()

Declaration
public override IntPtr Get()
Returns
Type Description
IntPtr
| Improve this Doc View Source

GetImages(OutputArray, OutputArray)

Get the images that correspond to each shape. This images are used in the calculation of the Image Appearance cost.

Declaration
public void GetImages(OutputArray image1, OutputArray image2)
Parameters
Type Name Description
OutputArray image1

Image corresponding to the shape defined by contours1.

OutputArray image2

Image corresponding to the shape defined by contours2.

| Improve this Doc View Source

SetImages(InputArray, InputArray)

Set the images that correspond to each shape. This images are used in the calculation of the Image Appearance cost.

Declaration
public void SetImages(InputArray image1, InputArray image2)
Parameters
Type Name Description
InputArray image1

Image corresponding to the shape defined by contours1.

InputArray image2

Image corresponding to the shape defined by contours2.

Implements

ICvPtrHolder
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX