| 462 | } |
| 463 | |
| 464 | bool GraphExecutor::GetTensorData(Tensor* tensor, void* output_data, int data_size) |
| 465 | { |
| 466 | int tensor_size = tensor->GetTotalSize(); |
| 467 | |
| 468 | if(tensor_size != data_size) |
| 469 | return false; |
| 470 | |
| 471 | void* tensor_addr = GetTensorBuffer(tensor); |
| 472 | |
| 473 | if(tensor_addr == nullptr) |
| 474 | return false; |
| 475 | |
| 476 | std::memcpy(output_data, tensor_addr, data_size); |
| 477 | |
| 478 | return true; |
| 479 | } |
| 480 | |
| 481 | static int MapExecStatus(int internal) |
| 482 | { |
nothing calls this directly
no test coverage detected