MyCaffe  1.12.2.41
Deep learning software for Windows C# programmers.
MyCaffe.db.image.LabelSet Class Reference

The LabelSet 'points' into the main image list via references objects that are already created in the main image list of the ImageSet. More...

Inheritance diagram for MyCaffe.db.image.LabelSet:

Public Member Functions

 LabelSet (LabelDescriptor lbl, CryptoRandom random)
 The LabelSet constructor. More...
 
void Clear ()
 Clears the list of images. More...
 
void Add (SimpleDatum s)
 Adds an image to the current index and then advances the internal index. More...
 
SimpleDatum GetImage (int nIdx, DB_ITEM_SELECTION_METHOD selectionMethod)
 Returns an image from the LabelSet using the image selection method. More...
 
void Unload ()
 Unload all images from the label set. More...
 
void Dispose ()
 Releases all resources used. More...
 

Static Public Member Functions

static SimpleDatum GetImage (SimpleDatum[] rgImages, List< int > rgIdx, int nCount, int nIdx, CryptoRandom random, DB_ITEM_SELECTION_METHOD selectionMethod, ref int nLastIndex, ref int nFixedIndex, out int nImageIdx)
 Returns an image from a list of images. More...
 

Protected Member Functions

virtual void Dispose (bool bDisposing)
 Releases all resources used. More...
 

Properties

LabelDescriptor Label [getset]
 Get/set the label of the LabelSet. More...
 
int Count [get]
 Returns the number of images in the label set. More...
 
SimpleDatum this[int nIdx] [getset]
 Get/set an image at an index within the LabelSet. More...
 
bool IsLoaded [get]
 Returns whether or not the label set is fully loaded or not (which is the case when first using LOAD_ON_DEMAND). More...
 

Detailed Description

The LabelSet 'points' into the main image list via references objects that are already created in the main image list of the ImageSet.

Definition at line 14 of file Labelset.cs.

Constructor & Destructor Documentation

◆ LabelSet()

MyCaffe.db.image.LabelSet.LabelSet ( LabelDescriptor  lbl,
CryptoRandom  random 
)

The LabelSet constructor.

Parameters
lblSpecifies the label.
randomSpecifies the random number generator.

Definition at line 27 of file Labelset.cs.

Member Function Documentation

◆ Add()

void MyCaffe.db.image.LabelSet.Add ( SimpleDatum  s)

Adds an image to the current index and then advances the internal index.

Parameters
sSpecifies the image.

Definition at line 88 of file Labelset.cs.

◆ Clear()

void MyCaffe.db.image.LabelSet.Clear ( )

Clears the list of images.

Definition at line 54 of file Labelset.cs.

◆ Dispose() [1/2]

void MyCaffe.db.image.LabelSet.Dispose ( )

Releases all resources used.

Definition at line 237 of file Labelset.cs.

◆ Dispose() [2/2]

virtual void MyCaffe.db.image.LabelSet.Dispose ( bool  bDisposing)
protectedvirtual

Releases all resources used.

Parameters
bDisposingSet to true when called from Dispose().

Definition at line 225 of file Labelset.cs.

◆ GetImage() [1/2]

SimpleDatum MyCaffe.db.image.LabelSet.GetImage ( int  nIdx,
DB_ITEM_SELECTION_METHOD  selectionMethod 
)

Returns an image from the LabelSet using the image selection method.

Parameters
nIdxSpecifies the index to use when performing sequential selection.
selectionMethodSpecifies the image selection method.
Returns
The image is returned.

Definition at line 103 of file Labelset.cs.

◆ GetImage() [2/2]

static SimpleDatum MyCaffe.db.image.LabelSet.GetImage ( SimpleDatum[]  rgImages,
List< int >  rgIdx,
int  nCount,
int  nIdx,
CryptoRandom  random,
DB_ITEM_SELECTION_METHOD  selectionMethod,
ref int  nLastIndex,
ref int  nFixedIndex,
out int  nImageIdx 
)
static

Returns an image from a list of images.

Parameters
rgImagesSpecifies the image list to select from.
rgIdxSpecifies the list of indexes to choose from.
nCountSpecifies the maximum count to use.
nIdxSpecifies the index to use when selecting sequentially or in pair selection.
randomSpecifies the random number generator to use.
selectionMethodSpecifies the image selection method.
nLastIndexSpecifies the last index used.
nFixedIndexSpecifies the fixed index to use.
nImageIdxReturns the image index used.
Returns

Definition at line 131 of file Labelset.cs.

◆ Unload()

void MyCaffe.db.image.LabelSet.Unload ( )

Unload all images from the label set.

Definition at line 213 of file Labelset.cs.

Property Documentation

◆ Count

int MyCaffe.db.image.LabelSet.Count
get

Returns the number of images in the label set.

Definition at line 46 of file Labelset.cs.

◆ IsLoaded

bool MyCaffe.db.image.LabelSet.IsLoaded
get

Returns whether or not the label set is fully loaded or not (which is the case when first using LOAD_ON_DEMAND).

Definition at line 74 of file Labelset.cs.

◆ Label

LabelDescriptor MyCaffe.db.image.LabelSet.Label
getset

Get/set the label of the LabelSet.

Definition at line 37 of file Labelset.cs.

◆ this[int nIdx]

SimpleDatum MyCaffe.db.image.LabelSet.this[int nIdx]
getset

Get/set an image at an index within the LabelSet.

Parameters
nIdxSpecifies the index.
Returns
The image at the index is returned.

Definition at line 65 of file Labelset.cs.


The documentation for this class was generated from the following file: