org.encog.ml.data
Interface MLDataSet
-
- All Superinterfaces:
- java.lang.Iterable<MLDataPair>
- All Known Subinterfaces:
- MLSequenceSet, NeuralDataSet
- All Known Implementing Classes:
- AutoFloatDataSet, BasicMLDataSet, BasicMLSequenceSet, BasicNeuralDataSet, BatchDataSet, BufferedMLDataSet, CSVNeuralDataSet, EnsembleDataSet, FoldedDataSet, ImageMLDataSet, MarketMLDataSet, MatrixMLDataSet, SQLNeuralDataSet, TemporalMLDataSet, VersatileMLDataSet
public interface MLDataSet extends java.lang.Iterable<MLDataPair>
An interface designed to abstract classes that store machine learning data. This interface is designed to provide EngineDataSet objects. These can be used to train machine learning methods using both supervised and unsupervised training. Some implementations of this interface are memory based. That is they store the entire contents of the dataset in memory. Other implementations of this interface are not memory based. These implementations read in data as it is needed. This allows very large datasets to be used. Typically the add methods are not supported on non-memory based datasets.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description voidadd(MLData data1)Add a object to the dataset.voidadd(MLData inputData, MLData idealData)Add a set of input and ideal data to the dataset.voidadd(MLDataPair inputData)Add a an object to the dataset.voidclose()Close this datasource and release any resources obtained by it, including any iterators created.MLDataPairget(int index)intgetIdealSize()intgetInputSize()voidgetRecord(long index, MLDataPair pair)Read an individual record, specified by index, in random order.longgetRecordCount()Determine the total number of records in the set.booleanisSupervised()MLDataSetopenAdditional()Opens an additional instance of this dataset.intsize()
-
-
-
Method Detail
-
getIdealSize
int getIdealSize()
- Returns:
- The size of the ideal data.
-
getInputSize
int getInputSize()
- Returns:
- The size of the input data.
-
isSupervised
boolean isSupervised()
- Returns:
- True if this is a supervised training set.
-
getRecordCount
long getRecordCount()
Determine the total number of records in the set.- Returns:
- The total number of records in the set.
-
getRecord
void getRecord(long index, MLDataPair pair)Read an individual record, specified by index, in random order.- Parameters:
index- The index to read.pair- The pair that the record will be copied into.
-
openAdditional
MLDataSet openAdditional()
Opens an additional instance of this dataset.- Returns:
- The new instance.
-
add
void add(MLData data1)
Add a object to the dataset. This is used with unsupervised training, as no ideal output is provided. Note: not all implemenations support the add methods.- Parameters:
data1- The data item to be added.
-
add
void add(MLData inputData, MLData idealData)
Add a set of input and ideal data to the dataset. This is used with supervised training, as ideal output is provided. Note: not all implementations support the add methods.- Parameters:
inputData- Input data.idealData- Ideal data.
-
add
void add(MLDataPair inputData)
Add a an object to the dataset. This is used with unsupervised training, as no ideal output is provided. Note: not all implementations support the add methods.- Parameters:
inputData- A MLDataPair object that contains both input and ideal data.
-
close
void close()
Close this datasource and release any resources obtained by it, including any iterators created.
-
size
int size()
-
get
MLDataPair get(int index)
-
-
DMelt 3.0 © DataMelt by jWork.ORG