<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/neural-structured-learning/blob/v1.4.0/neural_structured_learning/tools/graph_utils.py#L136-L154) |

Writes the given `graph` to the file `filename` in TSV format.

#### View aliases


**Main aliases**

[`nsl.tools.graph_utils.write_tsv_graph`](https://www.tensorflow.org/neural_structured_learning/api_docs/python/nsl/tools/write_tsv_graph)

<br />

    nsl.tools.write_tsv_graph(
        filename, graph
    )

<br />

<br />

<br />

| ## Args ||
|---|---|
| `filename` | Name of the file to which TSV output is written. The TSV lines are written in the same form as the input expected by `read_tsv_graph()`. |
| `graph` | A `dict` source_id -\> (target_id -\> weight) representing the graph. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| `None`. Instead, this has the side-effect or writing output to a file. ||

<br />