---
title: set_graph_output
description: "| 产品 | 是否支持 |"
url: https://www.hiascend.com/document/detail/zh/canncommercial/latest/API/ascendgraphapi/atlasgeapi_07_0784.html
sourcePath: /source/zh/canncommercial/900/API/ascendgraphapi/atlasgeapi_07_0784.html
indexId: bb10a6f1ed6b6575049a34197abaf4d496677864bfd470449bb5a7b41b777c8872
---
# set_graph_output

#### 产品支持情况

| 产品 | 是否支持 |
| --- | --- |
| Atlas 350 加速卡 | √ |
| Atlas A3 训练系列产品 / Atlas A3 推理系列产品 | √ |
| Atlas A2 训练系列产品 / Atlas A2 推理系列产品 | √ |
| Atlas 200I/500 A2 推理产品 | √ |
| Atlas 推理系列产品 | √ |
| Atlas 训练系列产品 | √ |


#### 功能说明

设置图输出。


#### 函数原型

```
set_graph_output(tensor: TensorHolder, output_index: int) -> None
```


#### 参数说明

| 参数名 | 输入/输出 | 描述 |
| --- | --- | --- |
| tensor | 输入 | 要设置为输出的张量持有者。 |
| output\_index | 输入 | 输出索引。 |


#### 返回值说明

无


#### 约束说明

如果参数类型不正确，抛出TypeError。
