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

Function TFE_ExecuteOpInNewThread

tensorflow/c/c_api_experimental.cc:548–562  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

546};
547
548TFE_ExecuteOpNotification* TFE_ExecuteOpInNewThread(TFE_Op* op,
549 TFE_TensorHandle** retvals,
550 int* num_retvals,
551 TF_Status* status) {
552 TFE_ExecuteOpNotification* n = new TFE_ExecuteOpNotification;
553
554 n->thread.reset(op->operation.EagerContext()->TFEnv()->StartThread(
555 tensorflow::ThreadOptions(), "ExecuteOpThread",
556 [op, retvals, num_retvals, n]() {
557 TFE_Execute(op, retvals, num_retvals, n->status.get());
558 n->n.Notify();
559 }));
560
561 return n;
562}
563
564void TFE_ExecuteOpNotificationWaitAndDelete(
565 TFE_ExecuteOpNotification* notification, TF_Status* status) {

Callers 1

TESTFunction · 0.85

Calls 8

ThreadOptionsClass · 0.85
TFE_ExecuteFunction · 0.85
TFEnvMethod · 0.80
resetMethod · 0.45
StartThreadMethod · 0.45
EagerContextMethod · 0.45
getMethod · 0.45
NotifyMethod · 0.45

Tested by 1

TESTFunction · 0.68