# tf.contrib.copy_graph.copy_variable_to_graph

<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/tensorflow/blob/v1.15.0/tensorflow/contrib/copy_graph/python/util/copy_elements.py#L41-L98) |

Given a `Variable` instance from one `Graph`, initializes and returns

    tf.contrib.copy_graph.copy_variable_to_graph(
        org_instance, to_graph, scope=''
    )

a copy of it from another `Graph`, under the specified scope
(default `""`).

<br />

<br />

<br />

| ## Args ||
|---|---|
| `org_instance` | A `Variable` from some `Graph`. |
| `to_graph` | The `Graph` to copy the `Variable` to. |
| `scope` | A scope for the new `Variable` (default `""`). |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| The copied `Variable` from `to_graph`. ||

<br />

<br />

<br />

<br />

| ## Raises ||
|---|---|
| `TypeError` | If `org_instance` is not a `Variable`. |

<br />