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

Function SetTransfer

tensorflow/compiler/tf2xla/xla_compiler.cc:1350–1360  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1348namespace {
1349
1350void SetTransfer(const string& key, absl::Span<const DataType> types,
1351 absl::Span<const TensorShape> shapes,
1352 tf2xla::HostTransferMetadata* transfer) {
1353 transfer->set_key(key);
1354 CHECK(types.size() == shapes.size());
1355 for (int i = 0; i < types.size(); ++i) {
1356 tf2xla::TensorMetadata* metadata = transfer->add_metadata();
1357 metadata->set_type(types[i]);
1358 shapes[i].AsProto(metadata->mutable_shape());
1359 }
1360}
1361
1362} // namespace
1363

Callers 2

Calls 4

add_metadataMethod · 0.80
sizeMethod · 0.45
AsProtoMethod · 0.45
mutable_shapeMethod · 0.45

Tested by

no test coverage detected