Filters
Filter values by
Classification object
  • Classifier context - predefined CNN
  • Classifier context - tree ensemble
  • Dataset context - images
  • Dataset context - features
  • Training context - CNN
  • Training context - tree ensemble
  • Training result buffer - CNN or tree ensemble
  • Prediction result buffer - CNN or tree ensemble
| Customize Help
| Save Settings

MclassControl



Function Map
Synopsis
Control a classifier context, a dataset context, class definitions, a training context, a training result buffer, or a prediction result buffer.
Syntax
void MclassControl(
MIL_ID ContextOrResultClassId, //in
MIL_INT64 LabelOrIndex, //in
MIL_INT64 ControlType, //in
MIL_DOUBLE ControlValue //in
)
Description

This function allows you to control a setting of a classifier context (or a class definition therein), a dataset context (or a class definition therein), a training context, a training result buffer, or a prediction result buffer. You can typically inquire these settings, using MclassInquire(). These settings can affect the execution of MclassTrain() or MclassPredict().

Note that when using a C compiler (not a C++ or other compiler) in 64-bit mode, MclassControl() internally calls the MIL_DOUBLE version of this function (MclassControlDouble()). If you need to pass integer values, call the MIL_INT64 version of this function (MclassControlInt64()).
Note that this function reference has not been updated for a MIL system added during a MIL update. Refer to the MIL system's release note to see which MIL system’s documentation you should use in its place and any possible differences.
Parameters
This function is not supported on the selected boards.
This function reference has not been updated for the selected MIL system. To show the content of this page, choose a second MIL system; refer to the MIL system's release note to see which MIL system’s documentation to choose and any possible differences.
Parameters
ContextOrResultClassId

Specifies the identifier of a context or result buffer to control. Set this parameter to one of the following values.

function map For specifying the context or result buffer
Click to summarizeValue Description
Click to summarize ContextClassifierId

Specifies the identifier of a predefined CNN or tree ensemble classifier context. These contexts must have been previously allocated on the required system using MclassAlloc() with M_CLASSIFIER_CNN_PREDEFINED or M_CLASSIFIER_TREE_ENSEMBLE.

(summarize)
Click to summarize ContextDatasetId

Specifies the identifier of an images or features dataset context. These contexts must have been previously allocated on the required system using MclassAlloc() with M_DATASET_IMAGES or M_DATASET_FEATURES.

(summarize)
Click to summarize ContextTrainId

Specifies the identifier of a CNN or tree ensemble training context. These contexts must have been previously allocated on the required system using MclassAlloc() with M_TRAIN_CNN or M_TRAIN_TREE_ENSEMBLE.

(summarize)
Click to summarize ResultPredictId

Specifies the identifier of a CNN or tree ensemble prediction result buffer. These buffers must have been previously allocated on the required system using MclassAllocResult() with M_PREDICT_CNN_RESULT or M_PREDICT_TREE_ENSEMBLE_RESULT.

(summarize)
Click to summarize ResultTrainId

Specifies the identifier of a CNN or tree ensemble training result buffer. These buffers must have been previously allocated on the required system using MclassAllocResult() with M_TRAIN_CNN_RESULT or M_TRAIN_TREE_ENSEMBLE_RESULT.

(summarize)
LabelOrIndex

Specifies what to control. Set this parameter to one of the following values.

function map For specifying what to control
Click to summarizeValue Description
Click to summarize M_DEFAULT

Same as M_CONTEXT.

Click to summarize

Specifies to control an author in a dataset context.

(summarize)
Parameters

Set this parameter to the following:

0 <= Value < M_NUMBER_OF_AUTHORS

Specifies the index of the author to control. You can inquire the total number of authors, using M_NUMBER_OF_AUTHORS.

Click to summarize

Specifies to control a class definition in a classifier context or a dataset context.

(summarize)
Parameters

Set this parameter to the following:

0 <= Value < M_NUMBER_OF_CLASSES

Specifies the index of the class definition to control. You can inquire the total number of class definition indices, using M_NUMBER_OF_CLASSES.

Click to summarize M_CONTEXT

Specifies to control a global setting of a classifier context or a dataset context.

Click to summarize M_GENERAL

Specifies to control a general setting of a classification result buffer.

ControlType

Specifies the type of control to set.

See the Parameter associations section for possible values that can be specified.

ControlValue

Specifies the required value for the control.

See the Parameter associations section for possible values that can be specified.

To control a global setting of a predefined CNN classifier context, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. In this case, set the ContextOrResultClassId parameter to the identifier of a predefined CNN classifier context, and set the LabelOrIndex parameter to M_CONTEXT.

function map For a classifier context (predefined CNN)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_TARGET_IMAGE_SIZE_X

Sets the X-size of the target image with which to call MclassPredict(). By default, MIL assumes the target image size is the same as the default source layer size, which you can retrieve, using MclassInquire() with M_SIZE_X and M_SIZE_Y.

M_TARGET_IMAGE_SIZE_X and M_TARGET_IMAGE_SIZE_Y must both be set to M_DEFAULT (or 0), or they must both be greater or equal to M_SIZE_X and M_SIZE_Y. The increment by which you can increase the dimensions of the target image depends on the size of the classifier's source layer and step. The following calculations indicate how to establish these dimensions:

If the target image size is the same as the source layer size, you are performing a typical image classification process (default). If the target image size is larger than the source layer size, you are performing coarse segmentation. The target image size must never be smaller than the source layer size. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 0. By default, MIL assumes the target image size is the same as the default source layer size.

(summarize)
Click to summarize Value >= 0

Specifies the X-size.

Click to summarize M_TARGET_IMAGE_SIZE_Y

Sets the Y-size of the target image with which to call MclassPredict(). By default, MIL assumes the target image size is the same as the default source layer size, which you can retrieve, using MclassInquire() with M_SIZE_X and M_SIZE_Y.

M_TARGET_IMAGE_SIZE_X and M_TARGET_IMAGE_SIZE_Y must both be set to M_DEFAULT (or 0), or they must both be greater or equal to M_SIZE_X and M_SIZE_Y. The increment by which you can increase the dimensions of the target image depends on the size of the classifier's source layer and step. The following calculations indicate how to establish these dimensions:

If the target image size is the same as the source layer size, you are performing a typical image classification process (default). If the target image size is larger than the source layer size, you are performing coarse segmentation. The target image size must never be smaller than the source layer size. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 0. By default, MIL assumes the target image size is the same as the default source layer size.

(summarize)
Click to summarize Value >= 0

Specifies the Y-size.

To control a global setting of a dataset context, the ControlType and corresponding ControlValue parameter settings can be set to the following values. In this case, set the ContextOrResultClassId parameter to the identifier of a dataset context. Unless otherwise specified, the following values apply to an images or features dataset context and you should set the LabelOrIndex parameter to M_CONTEXT.

function map For a dataset context (images or features)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_ACTIVE_AUTHOR_INDEX

Sets the author that is automatically added to labeling operations performed on a dataset context. MIL uses the active author unless you specify a different one. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_CURRENT_USER.

Click to summarize

Specifies the index identifying the author that is automatically defined for each dataset entry.

You can only specify the index of an existing author. Use M_AUTHOR_ADD to add a new author.

(summarize)
Parameters

Set this parameter to the following.

0 <= Value <M_NUMBER_OF_AUTHORS

Specifies the index. You can inquire the total number of author indices, using M_NUMBER_OF_AUTHORS.

Click to summarize M_CURRENT_USER

Specifies the system's current username as the author that is automatically defined for each dataset entry. If the system's current user name does not exist in the dataset, MIL adds at its end. Note that, in this case, authors are considered the same if their respective names are the same (regardless of their index).

(summarize)
Click to summarize M_ACTIVE_AUTHOR_UPDATE

Sets the behavior of the entry's author after a modification was performed on the entry. When disabled, changing an entry will never change its author's name. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_ENABLE.

Click to summarize M_DISABLE

Specifies to keep the existing author's information.

Click to summarize M_ENABLE

Specifies that when an entry's information (an entry's region information) is modified, its author is automatically modified according to M_ACTIVE_AUTHOR_INDEX. Note, entries only have one region.

(summarize)
Click to summarize M_AUTHOR_ADD

Adds a new author to a dataset context, according to the specified name. Added authors are given an index and a key (UUID). Once you add an author, you can refer to it in a dataset's entries.

(summarize)
Click to summarize
M_PTR_TO_DOUBLE(
MIL_CONST_TEXT_PTR String
)

Casts the address of the string identifying the author to add, from a MIL_CONST_TEXT_PTR to a MIL_DOUBLE.

(summarize)
Parameters

This parameter specifies the string whose address to cast.

MIL_TEXT("NewAuthorName") 1

Specifies the name of the author to add.

Click to summarize M_AUTHOR_DELETE

Deletes authors from a dataset context, according to the specified index.

(summarize)
Click to summarize M_DEFAULT

Same as M_ALL.

Click to summarize

Specifies the authors to delete from the dataset context.

Note that you cannot delete the active author specified with M_ACTIVE_AUTHOR_INDEX.

(summarize)
Parameters

Set this parameter to the following:

IndexValue

Specifies the index of the author to delete.

Click to summarize M_ALL

Specifies to delete all explicitly added authors. MIL does not delete the active author (M_ACTIVE_AUTHOR_INDEX).

(summarize)
Click to summarize M_AUTHOR_DELETE_BY_KEY

Deletes an author from a dataset context, according to the specified key (UUID).

(summarize)
Click to summarize MIL_UUID Value

Specifies the key of the author to delete. The key is defined as a MIL universal unique identifier (UUID).

To specify a MIL_UUID value when using a C compiler, you must call the MIL_UUID version of this function (MclassControlMilUuid). When using a C++ or other compiler, MclassControl() internally calls the MIL_UUID version of this function.

MIL_UUID version of MclassControl

void MclassControlMilUuid

(MIL_ID ContextOrResultClassId, MIL_INT64 LabelOrIndex, MIL_INT64 ControlType, MIL_UUID ControlValue)

(summarize)
Click to summarize M_AUTHOR_NAME

Sets the name of an author in the dataset context. You must set the LabelOrIndex parameter to M_AUTHOR_INDEX(). INQ

(summarize)
Click to summarize
M_PTR_TO_DOUBLE(
MIL_CONST_TEXT_PTR String
)

Casts the address of the string identifying the name of the author, from a MIL_CONST_TEXT_PTR to a MIL_DOUBLE.

(summarize)
Parameters

This parameter specifies the string whose address to cast.

MIL_TEXT("AuthorName") 1

Specifies the name of an author. This name replaces the current author's name.

Click to summarize M_CLASS_ADD

Adds a new class definition to a dataset context, according to the specified name. MIL assigns an index to the new class definition that is 1 greater than the highest existing class definition index.

Note, you cannot add a class definition to a classifier context.

(summarize)
Click to summarize M_NULL

Specifies to add a new class definition with no explicitly defined name. MIL defines a default name, in a "Class ##" format, where "##" is the index value.

(summarize)
Click to summarize
M_PTR_TO_DOUBLE(
MIL_CONST_TEXT_PTR String
)

Casts the address of the string identifying the name of the class definition to add, from a MIL_CONST_TEXT_PTR to a MIL_DOUBLE.

(summarize)
Parameters

This parameter specifies the string whose address to cast.

MIL_TEXT("NewClassName") 1

Specifies the name of the class definition to add.

Click to summarize M_CLASS_DELETE

Deletes a class definition from a dataset context, according to the specified index. If an entry in a dataset context references this deleted class definition, that reference is also deleted. Dataset entries without class definitions will cause an error when you call MclassTrain().

(summarize)
Click to summarize M_DEFAULT

Same as M_ALL.

Click to summarize

Specifies a class definition to delete.

(summarize)
Parameters

Set this parameter to the following:

0 <= Value <M_NUMBER_OF_CLASSES

Specifies the index. You can inquire the total number of class definition indices, using M_NUMBER_OF_CLASSES.

Click to summarize M_ALL

Specifies to delete all class definitions.

Click to summarize M_CLASS_DELETE_BY_KEY

Deletes a class definition from a dataset context, according to the specified key (UUID). If an entry in a dataset context references this deleted class definition, that reference is also deleted. Dataset entries without class definitions will cause an error when you call MclassTrain().

(summarize)
Click to summarize MIL_UUID Value

Specifies the key of the class definition to delete. The key is defined as a MIL universal unique identifier (UUID).

To specify a MIL_UUID value when using a C compiler, you must call the MIL_UUID version of this function (MclassControlMilUuid). When using a C++ or other compiler, MclassControl() internally calls the MIL_UUID version of this function.

MIL_UUID version of MclassControl

void MclassControlMilUuid

(MIL_ID ContextOrResultClassId, MIL_INT64 LabelOrIndex, MIL_INT64 ControlType, MIL_UUID ControlValue)

(summarize)
Click to summarize M_ENTRY_ADD

Adds a new entry to a dataset context. MIL adds a new entry after the last one. For every entry you add, MIL generates a key (MIL_UUID) to uniquely identify that entry.

For an images dataset, this automatically adds a full frame region that you can refer to using index 0.

You can import data, such as entries, from a CSV file to a dataset context, using MclassImport(). You can also use MIL CoPilot to interactively create, modify, and export datasets and their entries.

(summarize)
Click to summarize M_DEFAULT

Implements the default behavior.

Click to summarize M_ENTRY_DELETE

Deletes an entry from a dataset context, according to the specified index.

(summarize)
Click to summarize 0 <= Value <= M_NUMBER_OF_ENTRIES

Specifies the index of the entry to delete.

The default value is 0.

(summarize)
Click to summarize M_ENTRY_DELETE_ALL

Deletes all entries in a dataset context.

(summarize)
Click to summarize M_DEFAULT

Implements the default behavior.

Click to summarize M_ENTRY_DELETE_BY_KEY

Deletes an entry from a dataset context, according to the specified key (UUID).

(summarize)
Click to summarize MIL_UUID Value

Specifies the key of the entry to delete. The key is defined as a MIL universal unique identifier (UUID).

To specify a MIL_UUID value when using a C compiler, you must call the MIL_UUID version of this function (MclassControlMilUuid). When using a C++ or other compiler, MclassControl() internally calls the MIL_UUID version of this function.

MIL_UUID version of MclassControl

void MclassControlMilUuid

(MIL_ID ContextOrResultClassId, MIL_INT64 LabelOrIndex, MIL_INT64 ControlType, MIL_UUID ControlValue)

(summarize)
Click to summarize M_MAKE_FILE_PATHS_ABSOLUTE

Makes the file path of every entry in a dataset context into an absolute path. This is done by concatenating the current root path (M_ROOT_PATH value) to the relative path of all entries. This results in every entry having a complete path, and the root path (M_ROOT_PATH) being replaced with an empty string (MIL_TEXT("")).

This value only applies to an images dataset context.

(summarize)
Click to summarize M_DEFAULT

Implements the default behavior.

Click to summarize M_MAKE_FILE_PATHS_RELATIVE

Makes the file path of every entry in a dataset context into a relative path. This is done by parsing the absolute file path (M_FILE_PATH_ABS) of all entries to find a common root path. If a common root path is found, the file paths of all entries are modified to use relative paths, and the root path (M_ROOT_PATH) is set to the newly found common root path.

Note, if MobjInquire() with M_OBJECT_FILE_FOLDER returns a non-empty string value, and the common path has a part that is the same as the object's file folder, MIL will substitute this value with "///DATASET/". If M_OBJECT_FILE_FOLDER returns an empty string, MIL uses the common root path that was found.

For example, if the file paths of two dataset entries are A:\work\examples\ProcessingRocks\Classification\Image1.mim and A:\work\examples\ProcessingRocks\Classification\Image2.mim, MIL would establish the common path as A:\work\examples\ProcessingRocks\Classification. In this case, if M_OBJECT_FILE_FOLDER returns A:\work\examples\ProcessingRocks\Classification, MIL would set the root path (M_ROOT_PATH) to ///DATASET///. However, if M_OBJECT_FILE_FOLDER returns an empty string, MIL would set the root path to A:\work\examples\ProcessingRocks\Classification.

This value only applies to an images dataset context.

(summarize)
Click to summarize M_DEFAULT

Implements the default behavior.

Click to summarize M_MOVE_ENTRIES

Copies and reorganizes dataset entries according to the dataset classes and the specified destination folder. Within this folder, subfolders are created for each class and the files referenced in your entries are copied into them according to their ground truth class label. The source path and root path information for all entries are updated to the new copied location. The original source files are not deleted and remain unaffected.

It is recommended that you specify an empty destination folder each time you use M_MOVE_ENTRIES. Class folders that already exist in the destination are not recreated. Existing files within that folder that have conflicting names are overwritten. Existing files without conflicting names remain unaffected. Entries without a ground truth are placed in a subfolder called 'UnlabeledImages'.

Characters that are illegal in Windows file paths are replaced by the underscore character regardless of the operating system used. The maximum size of the file path is 259 characters. If this maximum is exceeded, MIL attempts to shorten the folder class names.

This value only applies to an images dataset context.

(summarize)
Click to summarize
M_PTR_TO_DOUBLE(
MIL_CONST_TEXT_PTR String
)

Casts the address of the string identifying the directory path, from a MIL_CONST_TEXT_PTR to a MIL_DOUBLE.

(summarize)
Parameters

This parameter specifies the string whose address to cast.

MIL_TEXT("PATH\\TO DST_FOLDER") 1

Specifies the file path. For example, you can specify "C:\\ILoveMatrox\\Dest". Note, relative paths are supported; paths must not end with '\\'.

Click to summarize M_ROOT_PATH

Sets the root path that is used for the file path of a dataset's entries. The full path of the entries is the root path and the file path. The file path is set, using MclassControlEntry() with M_FILE_PATH.

This value only applies to an images dataset context. INQ

(summarize)
Click to summarize
M_PTR_TO_DOUBLE(
MIL_CONST_TEXT_PTR String
)

Casts the address of the string identifying the specified root file path, from a MIL_CONST_TEXT_PTR to a MIL_DOUBLE.

(summarize)
Parameters

This parameter specifies the string whose address to cast.

MIL_TEXT("") 1

Specifies an empty path. This indicates that all entries' file paths are absolute paths.

MIL_TEXT("///DATASET///") 1

Specifies the path where the dataset context is saved after MclassSave().

Note, if this path does not exist, MIL uses the path in which your application's executable file is located.

MIL_TEXT("RootFilePath") 1

Specifies the root file path. For example, you can specify the root path as, MIL_TEXT("E:\\Manual\LabeledIt\Good").

1 If you are passing the value in a variable, don't enclose it in MIL_TEXT().

To control a class definition, the ControlType and corresponding ControlValue parameter settings can be set to the following values. Unless otherwise specified, set the ContextOrResultClassId parameter to the identifier of a classifier context (predefined CNN or tree ensemble) or a dataset context (images or features), and set the LabelOrIndex parameter to M_CLASS_INDEX().

Note, class definitions are added to a dataset context, using M_CLASS_ADD.

function map For a class definition in a classifier or dataset context (any)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_CLASS_DRAW_COLOR

Sets the color assigned to a class definition. This color is used as a visual label and helps to identify class definitions. Draw operations use the class definition color. INQ

(summarize)
Click to summarize
M_RGB888(
MIL_INT Red,
MIL_INT Green,
MIL_INT Blue
)

Specifies an RGB value to draw in an 8-bit, 3-band buffer. The red, green, and blue values must be values between 0 and 255, inclusive.

(summarize)
Parameters

Specifies the red component, as a value between 0 and 255.

Specifies the green component, as a value between 0 and 255.

Specifies the blue component, as a value between 0 and 255.

Click to summarize M_COLOR_BLACK

Specifies the color black.

Click to summarize M_COLOR_BLUE

Specifies the color blue.

Click to summarize M_COLOR_BRIGHT_GRAY

Specifies the color bright gray.

Click to summarize M_COLOR_CYAN

Specifies the color cyan.

Click to summarize M_COLOR_DARK_BLUE

Specifies the color dark blue.

Click to summarize M_COLOR_DARK_CYAN

Specifies the color dark cyan.

Click to summarize M_COLOR_DARK_GREEN

Specifies the color dark green.

Click to summarize M_COLOR_DARK_MAGENTA

Specifies the color dark magenta.

Click to summarize M_COLOR_DARK_RED

Specifies the color dark red.

Click to summarize M_COLOR_DARK_YELLOW

Specifies the color dark yellow.

Click to summarize M_COLOR_GRAY

Specifies the color gray.

Click to summarize M_COLOR_GREEN

Specifies the color green.

Click to summarize M_COLOR_LIGHT_BLUE

Specifies the color light blue.

Click to summarize M_COLOR_LIGHT_GRAY

Specifies the color light gray.

Click to summarize M_COLOR_LIGHT_GREEN

Specifies the color light green.

Click to summarize M_COLOR_LIGHT_WHITE

Specifies the color light white.

Click to summarize M_COLOR_MAGENTA

Specifies the color magenta.

Click to summarize M_COLOR_RED

Specifies the color red.

Click to summarize M_COLOR_WHITE

Specifies the color white.

Click to summarize M_COLOR_YELLOW

Specifies the color yellow.

Click to summarize Value

Specifies a grayscale value.

When drawing in a multi-band buffer, the grayscale value is cast to the type of the destination buffer's bands. This value will be replicated in each band.

Note that a grayscale value can be any integer or floating-point number. If the given value exceeds the range of the possible values that can be stored in each band of the destination buffer, the least significant bits of the value are used.

(summarize)
Click to summarize M_CLASS_ICON_ID

Sets the class definition's sample image. This image helps visually identify the class definition. This does not affect calculations.

When you call MclassControl() with M_CLASS_ICON_ID, MIL copies the image to the context and assigns it a new identifier. MIL returns this new identifier, if you inquire M_CLASS_ICON_ID. INQ

(summarize)
Click to summarize M_NULL

Specifies that the image associated with the class definition is freed.

Note that if the specified class definition does not have an associated image, this setting has no effect.

(summarize)
Click to summarize MIL image identifier

Specifies the identifier of the image buffer to use for the class definition's sample image.

Click to summarize M_CLASS_NAME

Sets the name of a class definition that is currently in the dataset context. INQ

(summarize)
Click to summarize
M_PTR_TO_DOUBLE(
MIL_CONST_TEXT_PTR String
)

Casts the address of the string identifying the name of the class definition, from a MIL_CONST_TEXT_PTR to a MIL_DOUBLE.

(summarize)
Parameters

This parameter specifies the string whose address to cast.

MIL_TEXT("ClassDefinitionName") 1

Specifies the name of a class definition. This name replaces the current class definition's name.

Click to summarize M_CLASS_WEIGHT

Sets the class definition's weight. In this case, you must set the ContextOrResultClassId parameter to the identifier of a features dataset context or a tree ensemble classifier context.

The specified weight can only have an effect if M_CLASS_WEIGHT_MODE is set to M_USER_DEFINED. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 1.0.

Click to summarize Value >= 0.0

Specifies the weight.

1 If you are passing the value in a variable, don't enclose it in MIL_TEXT().

To control a global setting of a CNN training context, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. In this case, set the ContextOrResultClassId parameter to the identifier of a CNN training context, and set the LabelOrIndex parameter to M_CONTEXT.

function map For a training context (CNN)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_CNN_TRAIN_ENGINE

Sets the engine (processing unit) that MIL uses to perform the training process. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_AUTO.

Click to summarize M_AUTO

Specifies the engine automatically. Typically, MIL uses the best available GPU.

(summarize)
Click to summarize M_CPU

Specifies the CPU.

Click to summarize M_GPU

Specifies the GPU.

Click to summarize M_INITIAL_LEARNING_RATE

Sets the initial learning rate for training. The learning rate determines the degree to which the classifier's weights are modified at each mini-batch during training.

You can automatically modify this setting, if you modify M_RESET_TRAINING_VALUES. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 0.005.

Click to summarize Value > 0.0

Specifies the learning rate.

Click to summarize M_LEARNING_RATE_DECAY

Sets the learning rate decay for training. The learning rate decay determines how fast the learning rate decreases during training. This can help prevent excessive weights.

You can automatically modify this setting, if you modify M_RESET_TRAINING_VALUES. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 0.1.

Click to summarize Value > 0.0

Specifies the learning rate decay.

Click to summarize M_MAX_EPOCH

Sets the maximum number of epochs. An epoch refers to one complete cycle through the data that the classifier must learn during training.

You can automatically modify this setting, if you modify M_RESET_TRAINING_VALUES. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 60.

Click to summarize Value >= 0

Specifies the maximum number.

Click to summarize M_MINI_BATCH_SIZE

Sets the size of each mini-batch. MIL uses mini-batches to split the training dataset to help make the training process more efficient.

You can automatically modify this setting, if you modify M_RESET_TRAINING_VALUES. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 32.

Click to summarize Value > 0

Specifies the size.

Click to summarize M_RESET_TRAINING_VALUES

Sets the value of all training mode controls (hyperparameters) automatically, according to the specified training mode. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_COMPLETE.

Click to summarize M_COMPLETE

Specifies a complete training mode. Typically, this is for completely restarting the training of a CNN classifier context, or for training a CNN classifier context that is not trained.

The training mode controls, and what M_COMPLETE automatically sets them to, are as follows:

M_INITIAL_LEARNING_RATE

0.005

M_LEARNING_RATE_DECAY

0.1

M_MAX_EPOCH

60

M_MINI_BATCH_SIZE

32

M_SCHEDULER_TYPE M_CYCLICAL_DECAY

When using M_COMPLETE, the classifier architecture adapts to certain qualities of the training dataset (image X- and Y-size, image bands, and the number of classes). All of the classifier's weights (learnable parameters) are randomly initialized prior to a complete training.

(summarize)
Click to summarize M_FINE_TUNING

Specifies a fine tuning training mode. Typically, this is for a CNN classifier context that was already trained on a specific classification problem, and that you must fine tune with new data. If you specify M_FINE_TUNING with a classifier context that was not sufficiently trained, you will get an error.

The training mode controls, and what M_FINE_TUNING automatically sets them to, are as follows:

M_INITIAL_LEARNING_RATE

0.001

M_LEARNING_RATE_DECAY

0.1

M_MAX_EPOCH

60

M_MINI_BATCH_SIZE

32

M_SCHEDULER_TYPE M_DECAY

When using M_FINE_TUNING, the classifier architecture is unchangeable. Therefore, the classifier's weights must be complete, and all the related qualities of the training dataset (image X- and Y-size, image bands, and the number of classes) must comply to the classifier's architecture. A fine-tuning training starts by using the classifier's current weights (learnable parameters).

(summarize)
Click to summarize M_TRANSFER_LEARNING

Specifies a transfer learning mode. Typically, this is for a CNN classifier context that was already trained on a specific classification problem, and that you must train on a similar (but new) problem. If you specify M_TRANSFER_LEARNING with a context that was not sufficiently trained, you will get an error.

The training mode controls, and what M_TRANSFER_LEARNING automatically sets them to, are as follows:

M_INITIAL_LEARNING_RATE

0.005

M_LEARNING_RATE_DECAY

0.1

M_MAX_EPOCH

60

M_MINI_BATCH_SIZE

32

M_SCHEDULER_TYPE M_CYCLICAL_DECAY

When using M_TRANSFER_LEARNING, the classifier architecture adapts to certain qualities of the training dataset (image X- and Y-size, and the number of classes). During training, some of the classifier's weights (learnable parameters) are randomly initialized and affected by the training (those related to classifying features), while others remain unaffected by the training (those related to extracting features).

(summarize)
Click to summarize M_SCHEDULER_TYPE

Sets the schedule with which to adjust the learning rate.

You can automatically modify this setting, if you modify M_RESET_TRAINING_VALUES. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_CYCLICAL_DECAY.

Click to summarize M_CYCLICAL_DECAY

Specifies to decay the learning rate at an internally established cyclical schedule.

Click to summarize M_DECAY

Specifies to decay the learning rate, as weights are updated.

To control a global setting of a tree ensemble training context, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. In this case, set the ContextOrResultClassId parameter to the identifier of a tree ensemble training context, and set the LabelOrIndex parameter to M_CONTEXT.

function map For a training context (tree ensemble)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_BOOTSTRAP

Sets whether to use bootstrap aggregation for the training dataset entries to produce multiple and separate training sets when building trees. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_WITH_REPLACEMENT.

Click to summarize M_DISABLE

Specifies not to use bootstrap aggregation.

Click to summarize M_WITH_REPLACEMENT

Specifies to use bootstrap aggregation, and allow replacement (chosen entries in a training set can be chosen again).

Click to summarize M_WITHOUT_REPLACEMENT

Specifies to use bootstrap aggregation, and not allow replacement (chosen entries in a training set cannot be chosen again).

Click to summarize M_CLASS_WEIGHT_MODE

Sets how to establish the weight of a class definition. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_NONE.

Click to summarize M_BALANCE

Specifies a balanced weight.

Click to summarize M_NONE

Specifies no weight.

Click to summarize M_USER_DEFINED

Specifies to use the weight defined with M_CLASS_WEIGHT.

Click to summarize M_COMPUTE_OUT_OF_BAG_RESULTS

Sets whether to use out-of-bag dataset entries to estimate the generalization accuracy during training.

Note, bagging information is typically unreliable if your training dataset has augmented entries. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_ENABLE.

Click to summarize M_DISABLE

Specifies not to use out-of-bag entries.

Click to summarize M_ENABLE

Specifies to use out-of-bag entries.

Click to summarize M_COMPUTE_PROXIMITY_MATRIX

Sets whether to calculate the proximity measure matrix when building trees.

This is an N x N matrix, where N is the number of entries. The intersection value between pairs of entries in the matrix defines their proximity, which refers to the average number of trees that occupy the same terminal node for those entries. For example, if entries i and j are in the same terminal node, their proximity increases by one. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_DISABLE.

Click to summarize M_DISABLE

Specifies not to calculate the proximity measure matrix when building trees.

Click to summarize M_ENABLE

Specifies to calculate the proximity measure matrix when building trees.

Click to summarize M_FEATURE_IMPORTANCE_MODE

Sets how to establish the importance of the features.

Every entry in a features dataset refers to a set of features. For example, every entry can refer to a set of blob features, such as area, perimeter, and Feret diameter. Specific values for these features are specified, for each entry, using MclassControlEntry() with M_RAW_DATA.

By enabling a feature importance mode, MIL establishes, during training, whether certain features are more important than others in determining the class to which the input data belongs. For example, the perimeter feature can end up being very important to establishing a successful classification, while the area feature can end up being almost irrelevant.

To retrieve the resulting importance of features after training, call MclassGetResult() with M_FEATURE_IMPORTANCE. You can then modify your set of features and retrain, which can help improve the tree ensemble classifier's performance and accuracy.

Note, M_FEATURE_IMPORTANCE_MODE does not directly affect training. It allows you to retrieve which features are more important; you can then use this information to modify your dataset (for example, you can specify only the important features) and retrain.

In general, the fastest modes with which to establish the feature importance are M_MEAN_DECREASE_IMPURITY, M_PERMUTATION, and M_DROP_COLUMN, while the modes with which to most accurately establish the feature importance are M_DROP_COLUMN, M_PERMUTATION, and M_MEAN_DECREASE_IMPURITY. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_MEAN_DECREASE_IMPURITY.

Click to summarize M_DISABLE

Specifies to disable the feature importance mode. In this case, you cannot retrieve any information about the feature importance.

(summarize)
Click to summarize M_DROP_COLUMN

Specifies that the feature importance is based on the drop column of features. In this case, the more the elimination of a feature affects accuracy, the more importance that feature is given. To specify the set with which to calculate this type of feature importance, use M_FEATURE_IMPORTANCE_SET. To use M_DROP_COLUMN, you must train with a development dataset or compute out-of-bag results (that is, enable M_COMPUTE_OUT_OF_BAG_RESULTS).

(summarize)
Click to summarize M_MEAN_DECREASE_IMPURITY

Specifies that the feature importance is based on a decreasing impurity process. In this case, the more a feature affects a proper node splitting, the more important it is. Proper splitting means that the two sets resulting from splitting the node are significantly purer (better) than the set that was input to the node.

(summarize)
Click to summarize M_PERMUTATION

Specifies that the feature importance is based on feature permutation. In this case, the more the shuffling of a feature affects accuracy, the more importance that feature is given. To specify the set with which to calculate this type of feature importance, use M_FEATURE_IMPORTANCE_SET. To use M_PERMUTATION, you must train with a development dataset or compute out-of-bag results (that is, enable M_COMPUTE_OUT_OF_BAG_RESULTS).

(summarize)
Click to summarize M_FEATURE_IMPORTANCE_SET

Sets how to establish the group of features with which to determine feature importance when using drop column or permutation. M_FEATURE_IMPORTANCE_SET only has an effect if M_FEATURE_IMPORTANCE_MODE is set to M_DROP_COLUMN or M_PERMUTATION. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_AUTO.

Click to summarize M_AUTO

Specifies to automatically establish the feature set to use. If available, MIL uses M_DEV_DATASET; otherwise, MIL uses M_OUT_OF_BAG.

(summarize)
Click to summarize M_DEV_DATASET

Specifies to use the development dataset.

Click to summarize M_OUT_OF_BAG

Specifies to use the out-of-bag set. In this case, you must not disable M_BOOTSTRAP.

Note, bagging information is typically unreliable if your data is augmented.

(summarize)
Click to summarize M_MIN_IMPURITY_DECREASE

Sets a decrease of impurity requirement for splitting a node. That is, MIL will split a node if it induces a decrease of impurity greater than or equal to the specified value.

The weighted impurity decrease equation is as follows: N_t / N * (impurity - N_t_R / N_t * right_impurity - N_t_L / N_t * left_impurity), where N is the total number of dataset entries, N_t is the number of dataset entries related to the current node, N_t_L is the number of dataset entries related to the left child, and N_t_R is the number of dataset entries related to the right child. N, N_t, N_t_R, and N_t_L all refer to the weighted sum, if weights (entry weights and class weights) are used. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 0.0.

Click to summarize Value >= 0.0

Specifies the impurity value.

Click to summarize M_MIN_NUMBER_OF_ENTRIES_LEAF

Sets the minimum number of training dataset entries, or a percentage of the minimum number of related dataset entries, that MIL uses to identify a leaf node. MIL uses this value to establish M_MIN_NUMBER_OF_ENTRIES_LEAF_MODE. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 1.

Click to summarize 0.0 < MinNumPercent <= 100.0

Specifies the minimum number of entries, as a percentage. You should only use a percentage when M_MIN_NUMBER_OF_ENTRIES_LEAF_MODE is set to M_USER_DEFINED_PERCENTAGE.

If you specify a percentage value that results in the minimum number of entries equaling 0, MIL uses 1 as the minimum number; that is, if Round((Value/100) * NumberEntriesInTrainDataset) == 0, then MinNumberEntriesLeaf = 1.

(summarize)
Click to summarize Value >= 1

Specifies the minimum number of entries. You should only use this value when M_MIN_NUMBER_OF_ENTRIES_LEAF_MODE is set to M_USER_DEFINED_VALUE.

(summarize)
Click to summarize M_MIN_NUMBER_OF_ENTRIES_LEAF_MODE

Sets how to establish the minimum number of related dataset entries required to be at a leaf node. A split point at any depth will only be considered if it leaves at least the minimum number of entries (leaf training entries) in each of the left and right branches. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_USER_DEFINED_VALUE.

Click to summarize M_USER_DEFINED_PERCENTAGE

Specifies to use a percentage, determined from the minimum number of entries defined with M_MIN_NUMBER_OF_ENTRIES_LEAF.

Click to summarize M_USER_DEFINED_VALUE

Specifies to use the minimum number of entries defined with M_MIN_NUMBER_OF_ENTRIES_LEAF.

Click to summarize M_MIN_NUMBER_OF_ENTRIES_SPLIT

Sets the minimum number of training dataset entries, or a percentage of the minimum number of related dataset entries, that MIL uses to determine how to best split the internal nodes of the trees. MIL uses this value to establish M_MIN_NUMBER_OF_ENTRIES_SPLIT_MODE. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 2.

Click to summarize 0.0 < MinNumPercent <= 100.0

Specifies the minimum number of entries, as a percentage. This only has an effect if M_MIN_NUMBER_OF_ENTRIES_SPLIT_MODE is set to M_USER_DEFINED_PERCENTAGE.

If you specify a percentage value that results in the minimum number of entries equaling 0, MIL uses 2 as the minimum number; that is, if Round((Value/100) * NumberEntriesInTrainDataset) == 0, then MinNumberEntriesSplit = 2.

(summarize)
Click to summarize Value >= 1

Specifies the minimum number of entries. This only has an effect if M_MIN_NUMBER_OF_ENTRIES_SPLIT_MODE is set to M_USER_DEFINED_VALUE.

(summarize)
Click to summarize M_MIN_NUMBER_OF_ENTRIES_SPLIT_MODE

Sets how to establish the minimum number of related dataset entries required to split an internal node. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_USER_DEFINED_VALUE.

Click to summarize M_USER_DEFINED_PERCENTAGE

Specifies to use a percentage, determined from the minimum number of entries defined with M_MIN_NUMBER_OF_ENTRIES_SPLIT.

Click to summarize M_USER_DEFINED_VALUE

Specifies to use the minimum number of entries defined with M_MIN_NUMBER_OF_ENTRIES_SPLIT.

Click to summarize M_MIN_WEIGHT_FRACTION_LEAF

Sets the minimum weighted fraction of the sum total of weights (of all the dataset entries) required to be at a leaf node. Entries have equal weight when M_CLASS_WEIGHT_MODE is set to M_NONE. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 0.0.

Click to summarize 0.0 <= Value <= 0.5

Specifies the minimum weighted fraction.

Click to summarize M_NODE_MAX_NUMBER_OF_FEATURES

Sets the maximum number of features in the training dataset, or a percentage of the maximum number of features, that MIL can use to determine how to best split the nodes of the trees. M_NODE_MAX_NUMBER_OF_FEATURES only has an effect if M_NODE_MAX_NUMBER_OF_FEATURES_MODE is set to M_USER_DEFINED_VALUE or M_USER_DEFINED_PERCENTAGE.

If M_NODE_MAX_NUMBER_OF_FEATURES_MODE is set to M_LOG2, and the number of features in the dataset is 1, MIL trains with 1 feature, even though the calculation results in 0; that is, log(1) = 0.

If M_NODE_MAX_NUMBER_OF_FEATURES_MODE is equal to M_USER_DEFINED_VALUE, and M_NODE_MAX_NUMBER_OF_FEATURES is higher than the actual number of features in the training dataset, MIL uses all the features in the dataset. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_ALL.

Click to summarize M_ALL

Specifies no maximum.

Click to summarize 0.0 <= MaxNumPercent <= 100.0

Specifies the percentage with which to determine the maximum number of features. This only has an effect if M_NODE_MAX_NUMBER_OF_FEATURES_MODE is set to M_USER_DEFINED_PERCENTAGE.

If you specify a percentage value that results in the maximum number of features equaling 0, MIL uses 1 feature as the maximum number; that is, if Round((Value/100)*NumberOfFeaturesInTrainDataset) == 0, then MaxNumberOfFeatures = 1 (see M_NODE_MAX_NUMBER_OF_FEATURES_MODE).

(summarize)
Click to summarize Value >= 1

Specifies the value with which to determine the maximum number of features. This only has an effect if M_NODE_MAX_NUMBER_OF_FEATURES_MODE is set to M_USER_DEFINED_VALUE.

If you specify a maximum value that is greater than the total number of features available, MIL uses the total number of features available.

(summarize)
Click to summarize M_NODE_MAX_NUMBER_OF_FEATURES_MODE

Sets how to establish the maximum number of features that MIL uses to determine how to best split the nodes of the trees. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_SQUARE_ROOT.

Click to summarize M_ALL

Specifies that all available features are used.

Click to summarize M_LOG2

Specifies to use a base 2 logarithm, determined from the total number of features. This can be described as: M_LOG2 = Round(Log2(NumberOfFeatures)).

(summarize)
Click to summarize M_SQUARE_ROOT

Specifies to use a square root, determined from the total number of features. This can be described as: M_SQUARE_ROOT = Round(Log2(NumberOfFeatures)).

(summarize)
Click to summarize M_USER_DEFINED_PERCENTAGE

Specifies to use a percentage, determined from the total number of features, where the percentage is set by M_NODE_MAX_NUMBER_OF_FEATURES. This can be described as: M_USER_DEFINED_PERCENTAGE = Round(NumberOfFeatures* MaxNumberOfFeatures/100).

(summarize)
Click to summarize M_USER_DEFINED_VALUE

Specifies to use the maximum number of features defined with M_NODE_MAX_NUMBER_OF_FEATURES.

Click to summarize M_NUMBER_OF_TREES

Sets the number of trees in the tree ensemble train context.

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 10.

Click to summarize Value >= 1

Specifies the amount of trees in the tree ensemble.

Click to summarize M_SEED_MODE

Sets the mode with which to initialize the seed used for training.

MIL uses the seed value to generate the random numbers needed to train a tree ensemble. Specifically, MIL uses randomness to: INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_USER_DEFINED.

Click to summarize M_AUTO

Specifies that the seed is chosen at random, and that MIL generates and uses a new seed each time you call MclassTrain(). To retrieve the used seed, call MclassGetResult() with M_GENERAL and M_SEED_VALUE. If you retrain with the same seed, you can reproduce the same training (MIL uses the same random values).

(summarize)
Click to summarize M_USER_DEFINED

Specifies the user-defined seed set with M_SEED_VALUE.

Click to summarize M_SEED_VALUE

Sets the seed value that MIL uses to generate the random numbers needed to train a tree ensemble.

MIL ignores this explicitly specified seed value if M_SEED_MODE is set to M_AUTO. INQ

(summarize)
Click to summarize M_DEFAULT

Specifies the default value; the default value is 1.

Click to summarize Value >= 1

Specifies the seed value.

Click to summarize M_SPLIT_QUALITY_TYPE

Sets how to measure the quality of a node split. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_GINI.

Click to summarize M_ENTROPY

Specifies that MIL uses an Entropy based function to measure the quality of a node split.

Click to summarize M_GINI

Specifies that MIL uses a Gini based function to measure the quality of a node split.

Click to summarize M_TREE_MAX_DEPTH

Sets the maximum depth of the trees in the tree ensemble.

The depth of a tree (M_TREE_MAX_DEPTH) is the depth of its deepest node. The depth of a node is the number of edges (connectors) from that node to the tree's root node. A root node has a depth of 0.

To retrieve the actual depth achieved after training, call MclassGetResult() with M_TREE_DEPTHS_ACHIEVED. The depth achieved is always less than or equal to the maximum tree depth (M_TREE_MAX_DEPTH). INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_NONE.

Click to summarize M_NONE

Specifies no maximum depth.

Click to summarize Value >= 0

Specifies the maximum depth.

Click to summarize M_TREE_MAX_NUMBER_OF_LEAF_NODES

Sets the maximum number of terminal nodes in the tree. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_NONE.

Click to summarize M_NONE

Specifies no maximum.

Click to summarize Value >= 1

Specifies the maximum number of terminal nodes in the tree.

To control a global setting of a training context, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. In this case, set the ContextOrResultClassId parameter to the identifier of a CNN or tree ensemble training context, and set the LabelOrIndex parameter to M_CONTEXT.

function map For a training context (CNN or tree ensemble)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_SUPPORT_MISSING_GROUND_TRUTH

Sets whether the training process allows the training and development datasets to contain entries that do not have a ground truth. Note, an entry's ground truth is specified using MclassControlEntry() with M_CLASS_INDEX_GROUND_TRUTH. INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_DISABLE.

Click to summarize M_DISABLE

Specifies that entries without a ground truth are not allowed. In this case, if you call MclassTrain(), and one or more entries in the training or development datasets do not have a ground truth, you will get an error.

(summarize)
Click to summarize M_ENABLE

Specifies that entries without a ground truth are allowed. In this case, if you call MclassTrain(), and one or more entries in the training or development datasets do not have a ground truth, MIL ignores them.

(summarize)

To control a global setting of a classifier context or a training context, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. In this case, set the ContextOrResultClassId parameter to the identifier of a predefined CNN or tree ensemble training or classifier context, and set the LabelOrIndex parameter to M_CONTEXT.

function map For a classifier or training context (CNN or tree ensemble)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_TIMEOUT

Sets the maximum calculation time, in msec. If you specify a training context, the timeout applies to MclassTrain(). If you specify a classifier context, the timeout applies to MclassPredict(). INQ

(summarize)
Click to summarize M_DEFAULT

Same as M_DISABLE.

Click to summarize M_DISABLE

Specifies an infinite amount of time.

Click to summarize Value > 0.0

Specifies the maximum time, in msec.

To control a general setting of a training result buffer, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. In this case, set the ContextOrResultClassId parameter to the identifier of either a CNN or tree ensemble training result buffer, unless otherwise specified, and set the LabelOrIndex parameter to M_GENERAL.

function map For a training result buffer (CNN or tree ensemble)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_STOP_TRAIN

Stops the current execution of MclassTrain(). This can only be done from another thread of higher priority, or from a user-defined classification hook function.

If you stop training a CNN classifier context, and 1 or more epochs are completed, results are typically available, except those related to development accuracy, training accuracy, development error rate, and training error rate. If you stop training a tree ensemble classifier context, and 1 or more trees are completed, all results are available.

If 1 or more epochs are completed, MIL saves the trained classifier results that MclassTrain() produces up to the point that you stop training. You can copy these results into a classifier context, using MclassCopyResult().

(summarize)
Click to summarize M_DEFAULT

Specifies the default behavior.

Click to summarize M_UPDATE_TRAINED_CNN_PARAMS

Updates the internal and hidden parameters (weights) of the classifier.

This only applies when training a CNN classifier, which you must specify with the ContextOrResultClassId parameter.

(summarize)
Click to summarize M_DEFAULT

Same as M_NOW.

Click to summarize M_NOW

Specifies to immediately update the training parameters network.

To control a general setting of a prediction result buffer, the ControlType and corresponding ControlValue parameter settings can be set to one of the following values. Unless otherwise specified, set the ContextOrResultClassId parameter to the identifier of either a CNN or tree ensemble prediction result buffer, and set the LabelOrIndex parameter to M_GENERAL. Note, it is possible to specify M_STOP_PREDICT when calling MclassPredict() with a target dataset; this requires setting the ContextOrResultClassId parameter to the identifier of the output dataset (images or features), and setting the LabelOrIndex parameter to M_CONTEXT.

function map For a prediction result buffer (CNN or tree ensemble)
Click to summarize
ControlType
Description
ControlValue
Click to summarize M_RESET

Removes all results from the classification result buffer.

Note that this does not delete the result buffer identifier, as is the case with MclassFree().

(summarize)
Click to summarize M_DEFAULT

Specifies the default behavior.

Click to summarize M_STOP_PREDICT

Stops the current execution of MclassPredict(). This can only be done from another thread of higher priority, or from a user-defined classification hook function. If you stop the prediction, MIL does not return any results.

Note, to stop the prediction of a target dataset, you must set the ContextOrResultClassId parameter to the identifier of the output dataset (produced by MclassPredict()), and set the LabelOrIndex parameter to M_CONTEXT.

(summarize)
Click to summarize M_DEFAULT

Specifies the default behavior.

Type-specific versions of the function when using a C compiler under 64-bit
void MclassControlInt64 (MIL_ID ContextOrResultClassId, MIL_INT64 LabelOrIndex, MIL_INT64 ControlType, MIL_INT64 ControlValue)
Parameters

ContextOrResultClassId

See ContextOrResultClassId of the main function for a description.

LabelOrIndex

See LabelOrIndex of the main function for a description.

ControlType

See ControlType of the main function for a description.

ControlValue

See ControlValue of the main function for a description.

void MclassControlDouble (MIL_ID ContextOrResultClassId, MIL_INT64 LabelOrIndex, MIL_INT64 ControlType, MIL_DOUBLE ControlValue)
Parameters

ContextOrResultClassId

See ContextOrResultClassId of the main function for a description.

LabelOrIndex

See LabelOrIndex of the main function for a description.

ControlType

See ControlType of the main function for a description.

ControlValue

See ControlValue of the main function for a description.

Compilation information
Header Include mil.h.
Library Use mil.lib; milclass.lib.
DLL Requires mil.dll; milclass.dll.
DEFAULT NUMBER OF AUTHORS NUMBER OF CLASSES CONTEXT GENERAL TARGET IMAGE SIZE X DEFAULT TARGET IMAGE SIZE Y DEFAULT ACTIVE AUTHOR INDEX DEFAULT NUMBER OF AUTHORS CURRENT USER ACTIVE AUTHOR UPDATE DEFAULT DISABLE ENABLE AUTHOR ADD AUTHOR DELETE DEFAULT ALL AUTHOR DELETE BY KEY AUTHOR NAME CLASS ADD NULL CLASS DELETE DEFAULT NUMBER OF CLASSES ALL CLASS DELETE BY KEY ENTRY ADD DEFAULT ENTRY DELETE NUMBER OF ENTRIES ENTRY DELETE ALL DEFAULT ENTRY DELETE BY KEY MAKE FILE PATHS ABSOLUTE DEFAULT MAKE FILE PATHS RELATIVE DEFAULT MOVE ENTRIES ROOT PATH CLASS DRAW COLOR COLOR BLACK COLOR BLUE COLOR BRIGHT GRAY COLOR CYAN COLOR DARK BLUE COLOR DARK CYAN COLOR DARK GREEN COLOR DARK MAGENTA COLOR DARK RED COLOR DARK YELLOW COLOR GRAY COLOR GREEN COLOR LIGHT BLUE COLOR LIGHT GRAY COLOR LIGHT GREEN COLOR LIGHT WHITE COLOR MAGENTA COLOR RED COLOR WHITE COLOR YELLOW CLASS ICON ID NULL PROC CLASS NAME CLASS WEIGHT DEFAULT CNN TRAIN ENGINE DEFAULT AUTO CPU GPU INITIAL LEARNING RATE DEFAULT LEARNING RATE DECAY DEFAULT MAX EPOCH DEFAULT MINI BATCH SIZE DEFAULT RESET TRAINING VALUES DEFAULT COMPLETE FINE TUNING TRANSFER LEARNING SCHEDULER TYPE DEFAULT CYCLICAL DECAY DECAY BOOTSTRAP DEFAULT DISABLE WITH REPLACEMENT WITHOUT REPLACEMENT CLASS WEIGHT MODE DEFAULT BALANCE NONE USER DEFINED COMPUTE OUT OF BAG RESULTS DEFAULT DISABLE ENABLE COMPUTE PROXIMITY MATRIX DEFAULT DISABLE ENABLE FEATURE IMPORTANCE MODE DEFAULT DISABLE DROP COLUMN MEAN DECREASE IMPURITY PERMUTATION FEATURE IMPORTANCE SET DEFAULT AUTO DEV DATASET OUT OF BAG MIN IMPURITY DECREASE DEFAULT MIN NUMBER OF ENTRIES LEAF DEFAULT MIN NUMBER OF ENTRIES LEAF MODE DEFAULT USER DEFINED PERCENTAGE USER DEFINED VALUE MIN NUMBER OF ENTRIES SPLIT DEFAULT MIN NUMBER OF ENTRIES SPLIT MODE DEFAULT USER DEFINED PERCENTAGE USER DEFINED VALUE MIN WEIGHT FRACTION LEAF DEFAULT NODE MAX NUMBER OF FEATURES DEFAULT ALL NODE MAX NUMBER OF FEATURES MODE DEFAULT ALL LOG2 SQUARE ROOT USER DEFINED PERCENTAGE USER DEFINED VALUE NUMBER OF TREES DEFAULT SEED MODE DEFAULT AUTO USER DEFINED SEED VALUE DEFAULT SPLIT QUALITY TYPE DEFAULT ENTROPY GINI TREE MAX DEPTH DEFAULT NONE TREE MAX NUMBER OF LEAF NODES DEFAULT NONE SUPPORT MISSING GROUND TRUTH DEFAULT DISABLE ENABLE TIMEOUT DEFAULT DISABLE STOP TRAIN DEFAULT UPDATE TRAINED CNN PARAMS DEFAULT NOW RESET DEFAULT STOP PREDICT DEFAULT GENERAL GENERAL GENERAL GENERAL CONTEXT DEFAULT CLASS INDEX CONTEXT DEFAULT CLASS INDEX CONTEXT DEFAULT CLASS INDEX AUTHOR INDEX CONTEXT DEFAULT CLASS INDEX AUTHOR INDEX CONTEXT DEFAULT CONTEXT DEFAULT