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

Method ListDeviceAttributes

tensorflow/core/common_runtime/device_mgr.cc:67–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

65}
66
67void DeviceMgr::ListDeviceAttributes(
68 std::vector<DeviceAttributes>* devices) const {
69 devices->reserve(devices_.size());
70 for (const auto& dev : devices_) {
71 devices->emplace_back(dev->attributes());
72 }
73}
74
75std::vector<Device*> DeviceMgr::ListDevices() const {
76 std::vector<Device*> devices(devices_.size());

Callers 7

GetStatusAsyncMethod · 0.80
GetStatusAsyncMethod · 0.80
GetStatusAsyncMethod · 0.80
CreateContextMethod · 0.80
TFE_ContextListDevicesFunction · 0.80

Calls 3

reserveMethod · 0.45
sizeMethod · 0.45
emplace_backMethod · 0.45

Tested by 3

GetStatusAsyncMethod · 0.64
GetStatusAsyncMethod · 0.64
GetStatusAsyncMethod · 0.64