| 246 | } |
| 247 | |
| 248 | void TfDriver::Invoke() { |
| 249 | if (!IsValid()) return; |
| 250 | auto status = session_->Run({input_tensors_.begin(), input_tensors_.end()}, |
| 251 | output_names_, {}, &output_tensors_); |
| 252 | if (!status.ok()) { |
| 253 | Invalidate(absl::StrCat("TensorFlow failed to run graph:", |
| 254 | status.error_message())); |
| 255 | } |
| 256 | } |
| 257 | |
| 258 | } // namespace testing |
| 259 | } // namespace tflite |