public abstract class BaseDataFetcher extends Object implements DataSetFetcher
| Modifier and Type | Field and Description |
|---|---|
protected DataSet |
curr |
protected int |
cursor |
protected int |
inputColumns |
protected static org.slf4j.Logger |
log |
protected int |
numOutcomes |
protected int |
totalExamples |
| Constructor and Description |
|---|
BaseDataFetcher() |
| Modifier and Type | Method and Description |
|---|---|
protected INDArray |
createInputMatrix(int numRows)
Creates a feature vector
|
protected INDArray |
createOutputMatrix(int numRows) |
protected INDArray |
createOutputVector(int outcomeLabel)
Creates an output label matrix
|
int |
cursor()
Direct access to a number represenative of iterating through a dataset
|
boolean |
hasMore()
Whether the dataset has more to load
|
protected void |
initializeCurrFromList(List<DataSet> examples)
Initializes this data transform fetcher from the passed in datasets
|
int |
inputColumns()
The length of a feature vector for an individual example
|
DataSet |
next()
Returns the next data applyTransformToDestination
|
void |
reset()
Returns the fetcher back to the beginning of the dataset
|
int |
totalExamples()
The total number of examples
|
int |
totalOutcomes()
The number of labels for a dataset
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitfetchprotected static final org.slf4j.Logger log
protected int cursor
protected int numOutcomes
protected int inputColumns
protected DataSet curr
protected int totalExamples
protected INDArray createInputMatrix(int numRows)
numRows - the number of examplesprotected INDArray createOutputVector(int outcomeLabel)
outcomeLabel - the outcome label to useprotected INDArray createOutputMatrix(int numRows)
protected void initializeCurrFromList(List<DataSet> examples)
examples - the examples to usepublic boolean hasMore()
DataSetFetcherhasMore in interface DataSetFetcherpublic DataSet next()
DataSetFetchernext in interface DataSetFetcherpublic int totalOutcomes()
DataSetFetchertotalOutcomes in interface DataSetFetcherpublic int inputColumns()
DataSetFetcherinputColumns in interface DataSetFetcherpublic int totalExamples()
DataSetFetchertotalExamples in interface DataSetFetcherpublic void reset()
DataSetFetcherreset in interface DataSetFetcherpublic int cursor()
DataSetFetchercursor in interface DataSetFetcherCopyright © 2021. All rights reserved.