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

Function BatchSizesMatch

tensorflow/contrib/session_bundle/signature.cc:38–46  ·  view source on GitHub ↗

Returns OK if the input and output batch sizes match.

Source from the content-addressed store, hash-verified

36
37// Returns OK if the input and output batch sizes match.
38Status BatchSizesMatch(const Tensor& input, const Tensor& output) {
39 // Ensure the number of outputs match the number of inputs.
40 if (input.dim_size(0) != output.dim_size(0)) {
41 return errors::Internal(strings::StrCat(
42 "Input batch size did not match output batch size: ", input.dim_size(0),
43 " vs. ", output.dim_size(0)));
44 }
45 return Status::OK();
46}
47} // namespace
48
49Status GetSignatures(const tensorflow::MetaGraphDef& meta_graph_def,

Callers 2

RunClassificationFunction · 0.85
RunRegressionFunction · 0.85

Calls 3

InternalFunction · 0.85
StrCatFunction · 0.50
dim_sizeMethod · 0.45

Tested by

no test coverage detected