Collection of regression information inside a regression sample list.
More...
Inherits SampleList.LabelInfoCollection< TLabelInformation, TData >.
|
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.
|
|
bool | HasValue (float[] value) |
| Check if a given value is already present in the values collection.
|
|
void | Remove (float[] label) |
| Remove all samples for a specific label.
|
|
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 .
|
|
void | Clear () |
| Remove all labels (and their associated data) from the Sample List.
|
|
void | Remove (int Index) |
| Remove a class by Index.
|
|
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 .
|
|
TInfo[] | ToArray () |
| Converts this collection into an array.
|
|
|
override ImageRegressionLabelInfo | GetInfo (int index) |
| Parent class calls this method to extract one info object by index.
|
|
override int | GetCount () |
| Parent class calls this method to determine the number of objects in the collection.
|
|
| InfoCollection (TParent parent) |
| Constructor.
|
|
int | GetCount () |
| Function with which the collection queries the number of elements.
|
|
TInfo | GetInfo (int index) |
| Function with which the collection retrieves the information object with the given index.
|
|
|
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.
◆ Add()
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.
- Parameters
-
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. |
- Exceptions
-
ObjectDisposedException | If the image list has already been disposed. |
◆ GetInfo()
Parent class calls this method to extract one info object by index.
- Parameters
-
index | index at which to extract |
- Returns
- extracted object
- Exceptions
-
ObjectDisposedException | If the SampleImageList has already been disposed |
ArgumentOutOfRangeException | If the index is invalid |
◆ HasValue()
bool HasValue |
( |
float[] | value | ) |
|
Check if a given value is already present in the values collection.
- Parameters
-
- Returns
- True if an entry with the specified value already exists; false otherwise.
◆ MergeClasses()
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 .
- Parameters
-
fromLabel | Class to merge to the other classes. |
toLabel | Class to merge the samples to. |
◆ Remove()
void Remove |
( |
float[] | label | ) |
|
Remove all samples for a specific label.
- Parameters
-
label | label to be removed from the data base |
◆ label
Access a sample collection by label.
- Parameters
-
- Returns