# cirq.contrib.Unique

A wrapper for a value that doesn't compare equal to other instances.

For example: 5 == 5 but Unique(5) != Unique(5).

Unique is used by CircuitDag to wrap operations because nodes in a graph are considered the same node if they compare equal to each other. For example, `X(q0)` in one moment of a circuit, and `X(q0)` in another moment of the circuit are wrapped by `cirq.Unique(X(q0))` so they are distinct nodes in the graph.

## Methods

### `__ge__`

Return a >= b. Computed by @total_ordering from (not a < b).

### `__gt__`

Return a > b. Computed by @total_ordering from (not a < b) and (a != b).

### `__le__`

Return a <= b. Computed by @total_ordering from (a < b) or (a == b).

### `__lt__`

View source

Return self<value.

[{ "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" }]