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

Function VectorToTuple

tensorflow/python/framework/python_op_gen.cc:65–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

63}
64
65string VectorToTuple(const std::vector<string>& l) {
66 if (l.size() == 1) return strings::StrCat("(", l.front(), ",)");
67 string ret = "(";
68 for (int i = 0; i < l.size(); ++i) {
69 if (i > 0) {
70 strings::StrAppend(&ret, ", ");
71 }
72 strings::StrAppend(&ret, l[i]);
73 }
74 strings::StrAppend(&ret, ")");
75 return ret;
76}
77
78void Unflatten(const string& prefix, const std::vector<string>& output_sizes,
79 const string& var, string* result) {

Callers 2

CodeMethod · 0.85
AddEagerInferredAttrsMethod · 0.85

Calls 4

StrCatFunction · 0.50
StrAppendFunction · 0.50
sizeMethod · 0.45
frontMethod · 0.45

Tested by

no test coverage detected