ImLab Scilab Function
Last update :
imhierarclusclassify - hierarchical clustering method, classification phase: third step of image segmentation using hierarchical clustering method.
Calling Sequence
-
[classes_image] = imhierarclusclassify(prototype,mask,weights,im1[,im2[,im3[,im4[,im5[,im6[,im7[,im8[,im9[,im10]]]]]]]]])
Parameters
-
prototype
: representative values of the classes. It can be obtained with 'imhierarclustrain' ImLab function or user defined.
-
mask
: matrix returned by an ImLab function or user-defined matrix allowing to define which pixels are considered in the segmentation (pixels with non null value). This mask must be the same as the one used in 'imlearningdata' ImLab function (image segmentation first step).
-
weights
: vector containing the weights for each image, in other words the relative importance of each image in clustering. These weights must be the same as the ones used in 'imlearningdata' ImLab function.
-
imx
: (hyper)matrix which contains interesting data for clustering. These images must be the same as the ones used in 'imlearningdata' ImLab function. All the images parameters must have the same dimension and the same size.
-
classes_image
: image which contains the class number of each pixel. This image has the same dimension and the same size than the image arguments. This is the result of the segmentation.
Description
Thanks to the prototype, this function classifies all the pixels of images that are defined by the mask. The value of a pixel in the classes image is the number of the class whose center is the closest (class numbers begin at 0). Note that the distance used is the euclidean one. This function is the same as 'imkmeansclassify'.