ArmNN
 21.05
StringifyLayerParameters< BatchToSpaceNdDescriptor > Struct Template Reference

#include <SerializeLayerParameters.hpp>

Static Public Member Functions

static void Serialize (ParameterStringifyFunction &fn, const BatchToSpaceNdDescriptor &desc)
 

Detailed Description

template<>
struct armnn::StringifyLayerParameters< BatchToSpaceNdDescriptor >

Definition at line 103 of file SerializeLayerParameters.hpp.

Member Function Documentation

◆ Serialize()

void Serialize ( ParameterStringifyFunction fn,
const BatchToSpaceNdDescriptor desc 
)
static

Definition at line 267 of file SerializeLayerParameters.cpp.

References armnn::GetDataLayoutName(), BatchToSpaceNdDescriptor::m_BlockShape, BatchToSpaceNdDescriptor::m_Crops, and BatchToSpaceNdDescriptor::m_DataLayout.

269 {
270  {
271  std::stringstream ss;
272  int count = 0;
273  for (auto&& var : desc.m_BlockShape)
274  {
275  if (count > 0)
276  {
277  ss << ",";
278  }
279  ss << var;
280  ++count;
281  }
282  fn("BlockShape", ss.str());
283  }
284 
285  {
286  std::stringstream ss;
287  int count = 0;
288  for (auto&& var : desc.m_Crops)
289  {
290  if (count > 0)
291  {
292  ss << ",";
293  }
294  ss << "[" << var.first << "," << var.second << "]";
295  ++count;
296  }
297  fn("Crops", ss.str());
298  }
299 
300  fn("DataLayout", GetDataLayoutName(desc.m_DataLayout));
301 }
constexpr const char * GetDataLayoutName(DataLayout dataLayout)
Definition: TypesUtils.hpp:214

The documentation for this struct was generated from the following files: