Description
Return a prediction-set cardinality penalty.
A classification decision can compare expected losses or utilities under supplied probabilities and outcome costs. The resulting threshold depends on which outcomes are charged, the cost signs and whether abstention is allowed; arithmetic alone does not establish appropriate costs or reliable probabilities.
Return a prediction-set cardinality penalty.
When to use this tool
Use Prediction Set Cardinality Penalty when comparing the stated classification, rejection or utility terms under supplied assumptions.
How to use the tool and how it works
- Enter cardinality, freeLabels, costPerExtra. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read extra, penalty. Use the output convention below.
Return a prediction-set cardinality penalty. Require nonnegative whole cardinality/freeLabels and costPerExtra >= 0; extra = max(0,cardinality-freeLabels), penalty = extra*cost.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| cardinality | Cardinality | Required. Safe integer; minimum 0. |
| freeLabels | Free Labels | Required. Safe integer; minimum 0. |
| costPerExtra | Cost Per Extra | Required. Finite number; minimum 0. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| extra | Extra | Required. Safe integer. |
| penalty | Penalty | Required. Finite number. |
{
"input": {
"cardinality": 5,
"freeLabels": 2,
"costPerExtra": 0.5
},
"output": {
"extra": 3,
"penalty": 1.5
}
} Limitations and assumptions
- No actual set, coverage guarantee or appropriate penalty value is established.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Specify the full decision problem and validate probabilities and outcome costs before using a threshold; assess performance and consequences on relevant data.
References
Similar or alternative tools
- Binary Prediction Flip Cost Term
Compare expected binary prediction costs.
- Threshold Utility Indifference Probability
Return utility indifference probability for positive prediction.