public class SelectiveSearchSegmentationStrategy extends Algorithm
| Modifier | Constructor and Description |
|---|---|
protected |
SelectiveSearchSegmentationStrategy(long addr) |
| Modifier and Type | Method and Description |
|---|---|
static SelectiveSearchSegmentationStrategy |
__fromPtr__(long addr) |
protected void |
finalize() |
float |
get(int r1,
int r2)
Return the score between two regions (between 0 and 1)
|
void |
merge(int r1,
int r2)
Inform the strategy that two regions will be merged
|
void |
setImage(Mat img,
Mat regions,
Mat sizes)
Set a initial image, with a segmentation.
|
void |
setImage(Mat img,
Mat regions,
Mat sizes,
int image_id)
Set a initial image, with a segmentation.
|
clear, empty, getDefaultName, getNativeObjAddr, saveprotected SelectiveSearchSegmentationStrategy(long addr)
public static SelectiveSearchSegmentationStrategy __fromPtr__(long addr)
public float get(int r1,
int r2)
r1 - The first regionr2 - The second regionpublic void merge(int r1,
int r2)
r1 - The first regionr2 - The second regionpublic void setImage(Mat img, Mat regions, Mat sizes, int image_id)
img - The input image. Any number of channel can be providedregions - A segmentation of the image. The parameter must be the same size of img.sizes - The sizes of different regionsimage_id - If not set to -1, try to cache pre-computations. If the same set og (img, regions, size) is used, the image_id need to be the same.public void setImage(Mat img, Mat regions, Mat sizes)
img - The input image. Any number of channel can be providedregions - A segmentation of the image. The parameter must be the same size of img.sizes - The sizes of different regionsCopyright © 2020. All rights reserved.