L
- Type of label.public class ClassificationMetricsAggregator<L extends Serializable> extends Object implements MetricStatsAggregator<L,EmptyContext<L>,ClassificationMetricsAggregator<L>>
Constructor and Description |
---|
ClassificationMetricsAggregator()
Creates an instance of ClassificationMetricsAggregator.
|
ClassificationMetricsAggregator(long validAnswersCnt,
long totalNumOfExamples)
Creates an instance of ClassificationMetricsAggregator.
|
Modifier and Type | Method and Description |
---|---|
void |
aggregate(IgniteModel<Vector,L> mdl,
LabeledVector<L> vector)
Aggregates statistics for metric computation given model and vector with answer.
|
EmptyContext<L> |
createInitializedContext()
Returns initialized context.
|
long |
getTotalNumberOfExamples()
Returns totalNumberOfExamples.
|
long |
getValidAnswersCount()
Returns validAnswersCount.
|
void |
initByContext(EmptyContext<L> ctx)
Inits this aggtegator by evaluation context.
|
ClassificationMetricsAggregator<L> |
mergeWith(ClassificationMetricsAggregator<L> other)
Merges statistics of two aggregators to new aggreagator.
|
public ClassificationMetricsAggregator()
public ClassificationMetricsAggregator(long validAnswersCnt, long totalNumOfExamples)
validAnswersCnt
- Valid answers count.totalNumOfExamples
- Total number of examples.public void aggregate(IgniteModel<Vector,L> mdl, LabeledVector<L> vector)
aggregate
in interface MetricStatsAggregator<L extends Serializable,EmptyContext<L extends Serializable>,ClassificationMetricsAggregator<L extends Serializable>>
mdl
- Model.vector
- Vector.public ClassificationMetricsAggregator<L> mergeWith(ClassificationMetricsAggregator<L> other)
mergeWith
in interface MetricStatsAggregator<L extends Serializable,EmptyContext<L extends Serializable>,ClassificationMetricsAggregator<L extends Serializable>>
other
- Other aggregator.public EmptyContext<L> createInitializedContext()
createInitializedContext
in interface MetricStatsAggregator<L extends Serializable,EmptyContext<L extends Serializable>,ClassificationMetricsAggregator<L extends Serializable>>
public void initByContext(EmptyContext<L> ctx)
initByContext
in interface MetricStatsAggregator<L extends Serializable,EmptyContext<L extends Serializable>,ClassificationMetricsAggregator<L extends Serializable>>
ctx
- Evaluation context.public long getValidAnswersCount()
public long getTotalNumberOfExamples()
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.11.0 Release Date : September 11 2021