Collection of regression information inside a regression sample list. More...
Inherits SampleList.LabelInfoCollection< TLabelInformation, TData >.
Public Member Functions | |
unsafe void | Add (float[] label, Image srcImage, Point2D extractionLocation, SampleExtractionMode mode=SampleExtractionMode.TopLeftCorner) |
Add a sample under a new value. If the value indicated by the label already exists the sample will be added to the existing label. More... | |
bool | HasValue (float[] value) |
Check if a given value is already present in the values collection. More... | |
void | Remove (float[] label) |
Remove all samples for a specific label. More... | |
void | MergeClasses (float[] fromLabel, float[] toLabel) |
Merge two classes into one class. The class label will be taken from the 2nd class index. Note that this operation will invalidate all indices higher than fromLabel . More... | |
![]() | |
void | Clear () |
Remove all labels (and their associated data) from the Sample List. More... | |
void | Remove (int Index) |
Remove a class by Index. More... | |
void | MergeClasses (int fromIndex, int toIndex) |
Merge two classes into one class. The class label will be taken from the 2nd class index. Note that this operation will invalidate all indices higher than fromIndex . More... | |
![]() | |
TInfo[] | ToArray () |
Converts this collection into an array. More... | |
Protected Member Functions | |
override ImageRegressionLabelInfo | GetInfo (int index) |
Parent class calls this method to extract one info object by index. More... | |
![]() | |
override int | GetCount () |
Parent class calls this method to determine the number of objects in the collection. More... | |
![]() | |
InfoCollection (TParent parent) | |
Constructor. More... | |
abstract int | GetCount () |
Function with which the collection queries the number of elements More... | |
abstract TInfo | GetInfo (int index) |
Function with which the collection retrieves the information object with the given index. More... | |
Properties | |
ImageRegressionLabelInfo this[float[] | label [get] |
Access a sample collection by label. More... | |
![]() | |
TLabelInformation | this[int index] [get] |
Index-based item access. More... | |
SampleList | ParentList [get] |
SampleList object to which this class file object is bound | |
![]() | |
int | Count [get] |
Number of elements in the collection. More... | |
![]() | |
SampleList | ParentList [get] |
Object through which the native handle may be accessed. | |
Additional Inherited Members | |
![]() | |
readonly TParent | Parent |
Parent image reference helps keeping track of the lifetime and provides the information basis for index access | |
Collection of regression information inside a regression sample list.
unsafe void Add | ( | float[] | label, |
Image | srcImage, | ||
Point2D | extractionLocation, | ||
SampleExtractionMode | mode = SampleExtractionMode.TopLeftCorner |
||
) |
Add a sample under a new value. If the value indicated by the label already exists the sample will be added to the existing label.
label | label of the new class. |
srcImage | Image from which to extract the first sample for the new class. |
extractionLocation | Location at which to extract the first sample for the new class. Note that what the extraction location actually refers dependent on the value of the mode parameter. |
mode | Interpretation hint for the extractionLocation parameter. |
ObjectDisposedException | If the image list has already been disposed. |
|
protectedvirtual |
Parent class calls this method to extract one info object by index.
index | index at which to extract |
ObjectDisposedException | If the SampleImageList has already been disposed |
ArgumentOutOfRangeException | If the index is invalid |
Implements InfoCollection< SampleList, TLabelInformation >.
bool HasValue | ( | float[] | value | ) |
Check if a given value is already present in the values collection.
value | Value to test for. |
void MergeClasses | ( | float[] | fromLabel, |
float[] | toLabel | ||
) |
Merge two classes into one class. The class label will be taken from the 2nd class index. Note that this operation will invalidate all indices higher than fromLabel .
fromLabel | Class to merge to the other classes. |
toLabel | Class to merge the samples to. |
void Remove | ( | float[] | label | ) |
Remove all samples for a specific label.
label | label to be removed from the data base |
|
get |
Access a sample collection by label.
label | Label to access |