| 1478 | } |
| 1479 | |
| 1480 | void TF_OperationGetAttrTensor(TF_Operation* oper, const char* attr_name, |
| 1481 | TF_Tensor** value, TF_Status* status) { |
| 1482 | *value = nullptr; |
| 1483 | Tensor t; |
| 1484 | status->status = tensorflow::GetNodeAttr(oper->node.attrs(), attr_name, &t); |
| 1485 | if (TF_GetCode(status) != TF_OK) return; |
| 1486 | *value = TF_TensorFromTensor(t, status); |
| 1487 | } |
| 1488 | |
| 1489 | void TF_OperationGetAttrTensorList(TF_Operation* oper, const char* attr_name, |
| 1490 | TF_Tensor** values, int max_values, |