# tfg.nn.loss.hausdorff_distance.evaluate

<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/nn/loss/hausdorff_distance.py#L27-L85) |

Computes the Hausdorff distance from point_set_a to point_set_b.

    tfg.nn.loss.hausdorff_distance.evaluate(
        point_set_a: type_alias.TensorLike,
        point_set_b: type_alias.TensorLike,
        name: str = 'hausdorff_distance_evaluate'
    ) -> tf.Tensor

<br />

<br />

<br />

| ## Note ||
|---|---|
| Hausdorff distance from point_set_a to point_set_b is defined as the maximum of all distances from a point in point_set_a to the closest point in point_set_b. It is an asymmetric metric. ||

<br />

<br />

<br />

<br />

| ## Note ||
|---|---|
| This function returns the exact Hausdorff distance and not an approximation. ||

<br />

<br />

<br />

<br />

| ## Note ||
|---|---|
| In the following, A1 to An are optional batch dimensions, which must be broadcast compatible. ||

<br />

<br />

<br />

<br />

| ## Args ||
|---|---|
| `point_set_a` | A tensor of shape `[A1, ..., An, N, D]`, where the last axis represents points in a D dimensional space. |
| `point_set_b` | A tensor of shape `[A1, ..., An, M, D]`, where the last axis represents points in a D dimensional space. |
| `name` | A name for this op. Defaults to "hausdorff_distance_evaluate". |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A tensor of shape `[A1, ..., An]` storing the hausdorff distance from from point_set_a to point_set_b. ||

<br />

<br />

<br />

<br />

| ## Raises ||
|---|---|
| `ValueError` | if the shape of `point_set_a`, `point_set_b` is not supported. |

<br />