public class DataSetLossCalculatorCG extends java.lang.Object implements ScoreCalculator<ComputationGraph>
Constructor and Description |
---|
DataSetLossCalculatorCG(org.nd4j.linalg.dataset.api.iterator.DataSetIterator dataSetIterator,
boolean average)
Calculate the score (loss function value) on a given data set (usually a test set)
|
DataSetLossCalculatorCG(org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator dataSetIterator,
boolean average)
Calculate the score (loss function value) on a given data set (usually a test set)
|
Modifier and Type | Method and Description |
---|---|
double |
calculateScore(ComputationGraph network)
Calculate the score for the given MultiLayerNetwork
|
java.lang.String |
toString() |
public DataSetLossCalculatorCG(org.nd4j.linalg.dataset.api.iterator.DataSetIterator dataSetIterator, boolean average)
dataSetIterator
- Data set to calculate the score foraverage
- Whether to return the average (sum of loss / N) or just (sum of loss)public DataSetLossCalculatorCG(org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator dataSetIterator, boolean average)
dataSetIterator
- Data set to calculate the score foraverage
- Whether to return the average (sum of loss / N) or just (sum of loss)public double calculateScore(ComputationGraph network)
ScoreCalculator
calculateScore
in interface ScoreCalculator<ComputationGraph>
public java.lang.String toString()
toString
in class java.lang.Object