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

Method Close

tensorflow/core/distributed_runtime/rpc/grpc_session.cc:347–361  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

345}
346
347Status GrpcSession::Close() {
348 CloseSessionRequest req;
349 {
350 mutex_lock l(mu_);
351 if (handle_.empty()) {
352 return Status::OK();
353 }
354 req.set_session_handle(handle_);
355 handle_.clear();
356 }
357 CloseSessionResponse resp;
358 CallOptions call_options;
359 call_options.SetTimeout(options_.config.operation_timeout_in_ms());
360 return master_->CloseSession(&call_options, &req, &resp);
361}
362
363Status GrpcSession::ListDevices(std::vector<DeviceAttributes>* response) {
364 ListDevicesRequest req;

Callers 1

TESTFunction · 0.45

Calls 5

set_session_handleMethod · 0.80
SetTimeoutMethod · 0.80
emptyMethod · 0.45
clearMethod · 0.45
CloseSessionMethod · 0.45

Tested by 1

TESTFunction · 0.36