kd.metrics.Accuracy#
- class kauldron.metrics.Accuracy(
- *,
- logits: typing.Annotated[typing.Any,
- <object object at 0x76412092fb90>] = '__KEY_REQUIRED__',
- labels: typing.Annotated[typing.Any,
- <object object at 0x76412092fb90>] = '__KEY_REQUIRED__',
- mask: typing.Annotated[typing.Any,
- <object object at 0x76412092fb90>] | None = None,
Bases:
kauldron.metrics.base.MetricClassification Accuracy.
- logits: Annotated[Any, <object object at 0x76412092fb90>] = '__KEY_REQUIRED__'
- labels: Annotated[Any, <object object at 0x76412092fb90>] = '__KEY_REQUIRED__'
- mask: Annotated[Any, <object object at 0x76412092fb90>] | None = None
- class State(
- total: "Float['']",
- count: "Float['']",
- *,
- parent: '_MetricT' = <_EMPTY_TYPE.EMPTY: 1>,
Bases:
kauldron.metrics.base_state.AverageState- merge(
- other: kauldron.metrics.base_state.AverageState,
Returns a new state that is the accumulation of self and other.
- replace(**updates)
Returns a new object replacing the specified fields with new values.
- get_state(
- logits: jaxtyping.Float[Array, '*b n'] | jaxtyping.Float[ndarray, '*b n'],
- labels: jaxtyping.Int[Array, '*b 1'] | jaxtyping.Int[ndarray, '*b 1'],
- mask: jaxtyping.Bool[Array, '*b 1'] | jaxtyping.Bool[ndarray, '*b 1'] | jaxtyping.Float[Array, '*b 1'] | jaxtyping.Float[ndarray, '*b 1'] | None = None,
- empty() kauldron.metrics.base.Metric.State[source]