# Module: tf.sets

<br />

Public API for tf._api.v2.sets namespace

## Functions

[`difference(...)`](https://www.tensorflow.org/api_docs/python/tf/sets/difference): Compute set difference of elements in last dimension of `a` and `b`.

[`intersection(...)`](https://www.tensorflow.org/api_docs/python/tf/sets/intersection): Compute set intersection of elements in last dimension of `a` and `b`.

[`size(...)`](https://www.tensorflow.org/api_docs/python/tf/sets/size): Compute number of unique elements along last dimension of `a`.

[`union(...)`](https://www.tensorflow.org/api_docs/python/tf/sets/union): Compute set union of elements in last dimension of `a` and `b`.