Class SelectiveSearchSegmentation
- Namespace
- OpenCvSharp.XImgProc.Segmentation
- Assembly
- OpenCvSharp.dll
Selective search segmentation algorithm. The class implements the algorithm described in @cite uijlings2013selective.
public class SelectiveSearchSegmentation : Algorithm, IDisposable, ICvPtrHolder
- Inheritance
-
SelectiveSearchSegmentation
- Implements
- Inherited Members
Constructors
SelectiveSearchSegmentation(nint)
Creates instance by raw pointer
protected SelectiveSearchSegmentation(nint p)
Parameters
pnint
Methods
AddGraphSegmentation(GraphSegmentation)
Add a new graph segmentation in the list of graph segmentations to process.
public virtual void AddGraphSegmentation(GraphSegmentation g)
Parameters
gGraphSegmentationThe graph segmentation
AddImage(InputArray)
Add a new image in the list of images to process.
public virtual void AddImage(InputArray img)
Parameters
imgInputArrayThe image
AddStrategy(SelectiveSearchSegmentationStrategy)
Add a new strategy in the list of strategy to process.
public virtual void AddStrategy(SelectiveSearchSegmentationStrategy s)
Parameters
sSelectiveSearchSegmentationStrategyThe strategy
ClearGraphSegmentations()
Clear the list of graph segmentations to process
public virtual void ClearGraphSegmentations()
ClearImages()
Clear the list of images to process
public virtual void ClearImages()
ClearStrategies()
Clear the list of strategy to process;
public virtual void ClearStrategies()
Create()
Create a new SelectiveSearchSegmentation class.
public static SelectiveSearchSegmentation Create()
Returns
DisposeManaged()
Releases managed resources
protected override void DisposeManaged()
Process(out Rect[])
Based on all images, graph segmentations and stragies, computes all possible rects and return them
public virtual void Process(out Rect[] rects)
Parameters
rectsRect[]The list of rects. The first ones are more relevents than the lasts ones.
SetBaseImage(InputArray)
Set a image used by switch* functions to initialize the class
public virtual void SetBaseImage(InputArray img)
Parameters
imgInputArrayThe image
SwitchToSelectiveSearchFast(int, int, float)
Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.
public virtual void SwitchToSelectiveSearchFast(int baseK = 150, int incK = 150, float sigma = 0.8)
Parameters
baseKintThe k parameter for the first graph segmentation
incKintThe increment of the k parameter for all graph segmentations
sigmafloatThe sigma parameter for the graph segmentation
SwitchToSelectiveSearchQuality(int, int, float)
Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.
public virtual void SwitchToSelectiveSearchQuality(int baseK = 150, int incK = 150, float sigma = 0.8)
Parameters
baseKintThe k parameter for the first graph segmentation
incKintThe increment of the k parameter for all graph segmentations
sigmafloatThe sigma parameter for the graph segmentation
SwitchToSingleStrategy(int, float)
Initialize the class with the 'Single stragegy' parameters describled in @cite uijlings2013selective.
public virtual void SwitchToSingleStrategy(int k = 200, float sigma = 0.8)