f1
Description
Given an Observable of ground-truth labels and predictions, the f1 operator returns the f1 score.
API
f1([initialState={truePositives: 0, falsePositives: 0, falseNegatives: 0}])Since
0.5
Parameters
None
Options
initialState: Object {truePositives: Number, falsePositives: Number, falseNegatives: 0}: Sets a warm start value so that the calculation can continue from a non-zero starting point (instead of a blank state). The initialState should have these keys:truePositives: Numberis a count of the true positivesfalsePositives: Numberis a count of the false positivesfalseNegatives: Numberis a count of the false negatives
Returns
Number. (The current f1 score of the Observable.)
Examples
Last updated
Was this helpful?