tfma.metrics.BinaryCrossEntropy

Calculates the binary cross entropy.

Inherits From: `Metric`

The metric computes the cross entropy when there are only two label classes (0 and 1). See definition at: https://en.wikipedia.org/wiki/Cross_entropy

`name` The name of the metric.
`from_logits` (Optional) Whether output is expected to be a logits tensor. By default, we consider that output encodes a probability distribution.
`label_smoothing` Float in [0, 1]. If > `0` then smooth the labels by squeezing them towards 0.5 That is, using `1. - 0.5 * label_smoothing` for the target class and `0.5 * label_smoothing` for the non-target class.

`compute_confidence_interval` Whether to compute confidence intervals for this metric.

Note that this may not completely remove the computational overhead involved in computing a given metric. This is only respected by the jackknife confidence interval method.

Methods

`computations`

View source

Creates computations associated with metric.

View source

`get_config`

View source

Returns serializable config.

[{ "type": "thumb-down", "id": "missingTheInformationINeed", "label":"Missing the information I need" },{ "type": "thumb-down", "id": "tooComplicatedTooManySteps", "label":"Too complicated / too many steps" },{ "type": "thumb-down", "id": "outOfDate", "label":"Out of date" },{ "type": "thumb-down", "id": "samplesCodeIssue", "label":"Samples / code issue" },{ "type": "thumb-down", "id": "otherDown", "label":"Other" }]
[{ "type": "thumb-up", "id": "easyToUnderstand", "label":"Easy to understand" },{ "type": "thumb-up", "id": "solvedMyProblem", "label":"Solved my problem" },{ "type": "thumb-up", "id": "otherUp", "label":"Other" }]