| 359 | } |
| 360 | |
| 361 | std::string TensorInfoAsString(const TensorInfo& info, |
| 362 | const std::string& name, |
| 363 | const onnx::TensorProto::DataType& type) |
| 364 | { |
| 365 | const TensorShape shape = info.GetShape(); |
| 366 | std::stringstream ss; |
| 367 | ss << "tensor '" << name << "' contains " |
| 368 | << onnx::TensorProto::DataType_Name(type) |
| 369 | << " and has shape ["; |
| 370 | |
| 371 | for (uint32_t i = 0; i < shape.GetNumDimensions() - 1; ++i) |
| 372 | { |
| 373 | ss << shape[i] << ", "; |
| 374 | } |
| 375 | ss << shape[shape.GetNumDimensions() - 1] << "]"; |
| 376 | return ss.str(); |
| 377 | } |
| 378 | |
| 379 | void CalcPadding(uint32_t inputSize, |
| 380 | uint32_t filterSize, |
no test coverage detected