MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / RecordRunCallable

Method RecordRunCallable

tensorflow/python/client/session_ref.cc:325–347  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

323 }
324
325 Status RecordRunCallable(Session* session, Session::CallableHandle handle,
326 const std::vector<Tensor>& feed_tensors,
327 std::vector<Tensor>* fetch_tensors,
328 RunMetadata* run_metadata) {
329 ReplayOp op;
330 RunCallableRequest* req = op.mutable_run_callable();
331 req->set_session_handle(SessionToHandle(session));
332 req->set_handle(handle);
333 for (auto& tensor : feed_tensors) {
334 tensor.AsProtoField(req->add_feed());
335 }
336 RUN_WITH_TIMESTAMP(RunCallable, handle, feed_tensors, fetch_tensors,
337 run_metadata);
338
339 RunCallableResponse* resp = op.mutable_run_callable_response();
340 if (run_metadata) {
341 *resp->mutable_metadata() = *run_metadata;
342 }
343 for (const Tensor& tensor : *fetch_tensors) {
344 tensor.AsProtoTensorContent(resp->add_fetch());
345 }
346 return Flush(op);
347 }
348
349 Status RecordReleaseCallable(Session* session,
350 Session::CallableHandle handle) {

Callers

nothing calls this directly

Calls 8

SessionToHandleFunction · 0.85
set_session_handleMethod · 0.80
AsProtoFieldMethod · 0.80
AsProtoTensorContentMethod · 0.80
set_handleMethod · 0.45
add_feedMethod · 0.45
mutable_metadataMethod · 0.45
add_fetchMethod · 0.45

Tested by

no test coverage detected