# tf_agents.utils.object_identity.Reference

<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/object_identity.py#L106-L137) |

Reference that refers an object.

    tf_agents.utils.object_identity.Reference(
        wrapped
    )

    x = [1]
    y = [1]

    x_ref1 = Reference(x)
    x_ref2 = Reference(x)
    y_ref2 = Reference(y)

    print(x_ref1 == x_ref2)
    ==> True

    print(x_ref1 == y)
    ==> False

<br />

<br />

<br />

| ## Attributes ||
|---|---|
| `unwrapped` | <br /> <br /> |

<br />

## Methods

### `deref`

[View source](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/object_identity.py#L128-L137)

    deref()

Returns the referenced object.

    x_ref = Reference(x)
    print(x is x_ref.deref())
    ==> True

### `__eq__`

[View source](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/object_identity.py#L77-L81)

    __eq__(
        other
    )

Return self==value.

### `__gt__`

[View source](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/object_identity.py#L73-L75)

    __gt__(
        other
    )

Return self\>value.

### `__lt__`

[View source](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/object_identity.py#L69-L71)

    __lt__(
        other
    )

Return self\<value.

### `__ne__`

[View source](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/object_identity.py#L83-L84)

    __ne__(
        other
    )

Return self!=value.