View Source Evision.XImgProc.Segmentation.SelectiveSearchSegmentation (Evision v0.1.28)

Link to this section Summary

Types

t()

Type that represents an XImgProc.Segmentation.SelectiveSearchSegmentation struct.

Functions

Add a new graph segmentation in the list of graph segementations to process.

Add a new image in the list of images to process.

Add a new strategy in the list of strategy to process.

Clears the algorithm state

Clear the list of graph segmentations to process;

Clear the list of images to process

Clear the list of strategy to process;

Returns true if the Algorithm is empty (e.g. in the very beginning or after unsuccessful read

getDefaultName

Based on all images, graph segmentations and stragies, computes all possible rects and return them

Reads algorithm parameters from a file storage

Set a image used by switch* functions to initialize the class

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Initialize the class with the 'Single stragegy' parameters describled in @cite uijlings2013selective.

Initialize the class with the 'Single stragegy' parameters describled in @cite uijlings2013selective.

Stores algorithm parameters in a file storage

Link to this section Types

@type t() :: %Evision.XImgProc.Segmentation.SelectiveSearchSegmentation{
  ref: reference()
}

Type that represents an XImgProc.Segmentation.SelectiveSearchSegmentation struct.

  • ref. reference()

    The underlying erlang resource variable.

Link to this section Functions

Link to this function

addGraphSegmentation(self, g)

View Source
@spec addGraphSegmentation(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  Evision.XImgProc.GraphSegmentation.t()
) :: Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Add a new graph segmentation in the list of graph segementations to process.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

  • g: Evision.XImgProc.GraphSegmentation.t().

    The graph segmentation

Python prototype (for reference only):

addGraphSegmentation(g) -> None
@spec addImage(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  Evision.Mat.maybe_mat_in()
) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Add a new image in the list of images to process.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

  • img: Evision.Mat.t().

    The image

Python prototype (for reference only):

addImage(img) -> None
@spec addStrategy(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  Evision.XImgProc.SelectiveSearchSegmentationStrategy.t()
) :: Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Add a new strategy in the list of strategy to process.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

  • s: Evision.XImgProc.SelectiveSearchSegmentationStrategy.t().

    The strategy

Python prototype (for reference only):

addStrategy(s) -> None
@spec clear(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Clears the algorithm state

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

Python prototype (for reference only):

clear() -> None
Link to this function

clearGraphSegmentations(self)

View Source
@spec clearGraphSegmentations(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Clear the list of graph segmentations to process;

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

Python prototype (for reference only):

clearGraphSegmentations() -> None
@spec clearImages(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Clear the list of images to process

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

Python prototype (for reference only):

clearImages() -> None
@spec clearStrategies(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Clear the list of strategy to process;

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

Python prototype (for reference only):

clearStrategies() -> None
@spec empty(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  boolean() | {:error, String.t()}

Returns true if the Algorithm is empty (e.g. in the very beginning or after unsuccessful read

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Return
  • retval: bool

Python prototype (for reference only):

empty() -> retval
@spec getDefaultName(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  binary() | {:error, String.t()}

getDefaultName

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Return

Returns the algorithm string identifier. This string is used as top level xml/yml node tag when the object is saved to a file or string.

Python prototype (for reference only):

getDefaultName() -> retval
@spec process(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  [{number(), number(), number(), number()}] | {:error, String.t()}

Based on all images, graph segmentations and stragies, computes all possible rects and return them

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Return
  • rects: [Rect].

    The list of rects. The first ones are more relevents than the lasts ones.

Python prototype (for reference only):

process() -> rects
@spec read(Evision.XImgProc.SelectiveSearchSegmentation.t(), Evision.FileNode.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Reads algorithm parameters from a file storage

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
  • fn_: Evision.FileNode.t()

Python prototype (for reference only):

read(fn_) -> None
@spec save(Evision.XImgProc.SelectiveSearchSegmentation.t(), binary()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

save

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
  • filename: String

Saves the algorithm to a file. In order to make this method work, the derived class must implement Algorithm::write(FileStorage& fs).

Python prototype (for reference only):

save(filename) -> None
@spec setBaseImage(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  Evision.Mat.maybe_mat_in()
) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Set a image used by switch* functions to initialize the class

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()

  • img: Evision.Mat.t().

    The image

Python prototype (for reference only):

setBaseImage(img) -> None
Link to this function

switchToSelectiveSearchFast(self)

View Source
@spec switchToSelectiveSearchFast(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Keyword Arguments
  • base_k: int.

    The k parameter for the first graph segmentation

  • inc_k: int.

    The increment of the k parameter for all graph segmentations

  • sigma: float.

    The sigma parameter for the graph segmentation

Python prototype (for reference only):

switchToSelectiveSearchFast([, base_k[, inc_k[, sigma]]]) -> None
Link to this function

switchToSelectiveSearchFast(self, opts)

View Source
@spec switchToSelectiveSearchFast(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  [{atom(), term()}, ...] | nil
) :: Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Keyword Arguments
  • base_k: int.

    The k parameter for the first graph segmentation

  • inc_k: int.

    The increment of the k parameter for all graph segmentations

  • sigma: float.

    The sigma parameter for the graph segmentation

Python prototype (for reference only):

switchToSelectiveSearchFast([, base_k[, inc_k[, sigma]]]) -> None
Link to this function

switchToSelectiveSearchQuality(self)

View Source
@spec switchToSelectiveSearchQuality(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Keyword Arguments
  • base_k: int.

    The k parameter for the first graph segmentation

  • inc_k: int.

    The increment of the k parameter for all graph segmentations

  • sigma: float.

    The sigma parameter for the graph segmentation

Python prototype (for reference only):

switchToSelectiveSearchQuality([, base_k[, inc_k[, sigma]]]) -> None
Link to this function

switchToSelectiveSearchQuality(self, opts)

View Source
@spec switchToSelectiveSearchQuality(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  [{atom(), term()}, ...] | nil
) :: Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Initialize the class with the 'Selective search fast' parameters describled in @cite uijlings2013selective.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Keyword Arguments
  • base_k: int.

    The k parameter for the first graph segmentation

  • inc_k: int.

    The increment of the k parameter for all graph segmentations

  • sigma: float.

    The sigma parameter for the graph segmentation

Python prototype (for reference only):

switchToSelectiveSearchQuality([, base_k[, inc_k[, sigma]]]) -> None
Link to this function

switchToSingleStrategy(self)

View Source
@spec switchToSingleStrategy(Evision.XImgProc.SelectiveSearchSegmentation.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Initialize the class with the 'Single stragegy' parameters describled in @cite uijlings2013selective.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Keyword Arguments
  • k: int.

    The k parameter for the graph segmentation

  • sigma: float.

    The sigma parameter for the graph segmentation

Python prototype (for reference only):

switchToSingleStrategy([, k[, sigma]]) -> None
Link to this function

switchToSingleStrategy(self, opts)

View Source
@spec switchToSingleStrategy(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  [{atom(), term()}, ...] | nil
) :: Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Initialize the class with the 'Single stragegy' parameters describled in @cite uijlings2013selective.

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
Keyword Arguments
  • k: int.

    The k parameter for the graph segmentation

  • sigma: float.

    The sigma parameter for the graph segmentation

Python prototype (for reference only):

switchToSingleStrategy([, k[, sigma]]) -> None
@spec write(Evision.XImgProc.SelectiveSearchSegmentation.t(), Evision.FileStorage.t()) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

Stores algorithm parameters in a file storage

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
  • fs: Evision.FileStorage.t()

Python prototype (for reference only):

write(fs) -> None
@spec write(
  Evision.XImgProc.SelectiveSearchSegmentation.t(),
  Evision.FileStorage.t(),
  binary()
) ::
  Evision.XImgProc.SelectiveSearchSegmentation.t() | {:error, String.t()}

write

Positional Arguments
  • self: Evision.XImgProc.Segmentation.SelectiveSearchSegmentation.t()
  • fs: Evision.FileStorage.t()
  • name: String

Has overloading in C++

Python prototype (for reference only):

write(fs, name) -> None