| 204 | } |
| 205 | |
| 206 | StatusOr<DLContext> DLContextForDevice(const Device& device) { |
| 207 | DLContext context; |
| 208 | TF_ASSIGN_OR_RETURN(context.device_type, DLDeviceTypeForDevice(device)); |
| 209 | context.device_id = device.local_device_state()->device_ordinal(); |
| 210 | return context; |
| 211 | } |
| 212 | |
| 213 | StatusOr<std::shared_ptr<Device>> DeviceForDLContext( |
| 214 | const PyLocalClient& client, const DLContext& context) { |
no test coverage detected