public class ClassificationScoreCalculator extends org.deeplearning4j.earlystopping.scorecalc.base.BaseIEvaluationScoreCalculator<org.deeplearning4j.nn.api.Model,ClassificationEvaluation>
Evaluation.Metric such
as accuracy, F1 score, etc.
Used for both MultiLayerNetwork and ComputationGraph| Modifier and Type | Field and Description |
|---|---|
protected LookupCacheEncoder |
encoder |
protected Tagger |
tagger |
| Constructor and Description |
|---|
ClassificationScoreCalculator(Tagger tagger,
LookupCacheEncoder encoder,
org.nd4j.linalg.dataset.api.iterator.DataSetIterator iterator) |
ClassificationScoreCalculator(Tagger tagger,
LookupCacheEncoder encoder,
org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator iterator) |
| Modifier and Type | Method and Description |
|---|---|
double |
calculateScore(org.deeplearning4j.nn.api.Model network) |
protected void |
evaluate(org.deeplearning4j.nn.graph.ComputationGraph net,
ClassificationEvaluation evaluation,
org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator iterator)
Override evaluation to use average of forward/backward layers in a single score.
|
protected double |
finalScore(ClassificationEvaluation e) |
boolean |
minimizeScore() |
protected ClassificationEvaluation |
newEval() |
protected Tagger tagger
protected LookupCacheEncoder encoder
public ClassificationScoreCalculator(Tagger tagger, LookupCacheEncoder encoder, org.nd4j.linalg.dataset.api.iterator.DataSetIterator iterator)
public ClassificationScoreCalculator(Tagger tagger, LookupCacheEncoder encoder, org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator iterator)
protected ClassificationEvaluation newEval()
newEval in class org.deeplearning4j.earlystopping.scorecalc.base.BaseIEvaluationScoreCalculator<org.deeplearning4j.nn.api.Model,ClassificationEvaluation>public double calculateScore(org.deeplearning4j.nn.api.Model network)
calculateScore in interface org.deeplearning4j.earlystopping.scorecalc.ScoreCalculator<org.deeplearning4j.nn.api.Model>calculateScore in class org.deeplearning4j.earlystopping.scorecalc.base.BaseIEvaluationScoreCalculator<org.deeplearning4j.nn.api.Model,ClassificationEvaluation>protected void evaluate(org.deeplearning4j.nn.graph.ComputationGraph net,
ClassificationEvaluation evaluation,
org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator iterator)
protected double finalScore(ClassificationEvaluation e)
finalScore in class org.deeplearning4j.earlystopping.scorecalc.base.BaseIEvaluationScoreCalculator<org.deeplearning4j.nn.api.Model,ClassificationEvaluation>public boolean minimizeScore()
Copyright © 2019. All rights reserved.