add_samples_image_class_gmm — Add training samples from an image to the training data of a
Gaussian Mixture Model.
add_samples_image_class_gmm adds training samples from the
Image to the Gaussian Mixture Model (GMM) given by
add_samples_image_class_gmm is used to
store the training samples before a classifier to be used for the
pixel classification of multichannel images with
classify_image_class_gmm is trained.
add_samples_image_class_gmm works analogously to
Image must have a number
of channels equal to
NumDim, as specified with
create_class_gmm. The training regions for the
NumClasses pixel classes are passed in
ClassRegions must be a tuple
NumClasses regions. The order of the regions
ClassRegions determines the class of the pixels. If
there are no samples for a particular class in
empty region must be passed at the position of the class in
ClassRegions. With this mechanism it is possible to use
multiple images to add training samples for all relevant classes to
the GMM by calling
times with the different images and suitably chosen regions. The
ClassRegions should contain representative
training samples for the respective classes. Hence, they need not
cover the entire image. The regions in
not overlap each other, because this would lead to the fact that in
the training data the samples from the overlapping areas would be
assigned to multiple classes, which may lead to a lower
classification performance. Image data of integer type can be
particularly badly suited for modeling with a
Randomize can be used to overcome this problem, as
This operator modifies the state of the following input parameter:
During execution of this operator, access to the value of this parameter must be synchronized if it is used across multiple threads.
→object (byte / cyclic / direction / int1 / int2 / uint2 / int4 / real)
Regions of the classes to be trained.
GMMHandle(input_control, state is modified) class_gmm
Standard deviation of the Gaussian noise added to the training data.
Default value: 0.0
Suggested values: 0.0, 1.5, 2.0
Randomize >= 0.0
If the parameters are valid, the operator
add_samples_image_class_gmm returns the value 2 (H_MSG_TRUE). If
necessary an exception is raised.