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

Method PrintOutputs

tensorflow/core/util/stat_summarizer.cc:227–251  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225
226
227void StatSummarizer::PrintOutputs() const {
228 std::priority_queue<
229 std::pair<int64, const std::pair<const std::string, Detail>*>>
230 timings;
231 for (const auto& entry : stats_calculator_->GetDetails()) {
232 timings.emplace(-entry.second.start_us.avg(), &entry);
233 }
234
235 LOG(INFO) << "============ Node output tensor sizes in run order ========";
236 while (!timings.empty()) {
237 auto entry = timings.top();
238 timings.pop();
239 std::stringstream stream;
240 const auto detail_outputs = outputs_.at(entry.second->first);
241 stream << entry.second->first << "\t" << detail_outputs.size();
242 for (const auto& tensor : detail_outputs) {
243 stream << "\t" << DataTypeString(tensor.dtype());
244 stream << "\t" << tensor.shape().dim_size();
245 for (const auto& d : tensor.shape().dim()) {
246 stream << "\t" << d.size();
247 }
248 }
249 LOG(INFO) << stream.str();
250 }
251}
252
253} // namespace tensorflow

Callers 1

MainFunction · 0.80

Calls 11

avgMethod · 0.80
DataTypeStringFunction · 0.50
emplaceMethod · 0.45
emptyMethod · 0.45
popMethod · 0.45
atMethod · 0.45
sizeMethod · 0.45
dtypeMethod · 0.45
dim_sizeMethod · 0.45
shapeMethod · 0.45
dimMethod · 0.45

Tested by

no test coverage detected