MCPcopy Create free account
hub / github.com/ARM-software/armnn / SerializePooling2dLayer

Method SerializePooling2dLayer

src/armnnSerializer/Serializer.cpp:1113–1140  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1111}
1112
1113void SerializerStrategy::SerializePooling2dLayer(const armnn::IConnectableLayer* layer,
1114 const armnn::Pooling2dDescriptor& pooling2dDescriptor,
1115 const char* name)
1116{
1117 IgnoreUnused(name);
1118
1119 auto fbPooling2dBaseLayer = CreateLayerBase(layer, serializer::LayerType::LayerType_Pooling2d);
1120 auto fbPooling2dDescriptor = serializer::CreatePooling2dDescriptor(
1121 m_flatBufferBuilder,
1122 GetFlatBufferPoolingAlgorithm(pooling2dDescriptor.m_PoolType),
1123 pooling2dDescriptor.m_PadLeft,
1124 pooling2dDescriptor.m_PadRight,
1125 pooling2dDescriptor.m_PadTop,
1126 pooling2dDescriptor.m_PadBottom,
1127 pooling2dDescriptor.m_PoolWidth,
1128 pooling2dDescriptor.m_PoolHeight,
1129 pooling2dDescriptor.m_StrideX,
1130 pooling2dDescriptor.m_StrideY,
1131 GetFlatBufferOutputShapeRounding(pooling2dDescriptor.m_OutputShapeRounding),
1132 GetFlatBufferPaddingMethod(pooling2dDescriptor.m_PaddingMethod),
1133 GetFlatBufferDataLayout(pooling2dDescriptor.m_DataLayout));
1134
1135 auto fbPooling2dLayer = serializer::CreatePooling2dLayer(m_flatBufferBuilder,
1136 fbPooling2dBaseLayer,
1137 fbPooling2dDescriptor);
1138
1139 CreateAnyLayer(fbPooling2dLayer.o, serializer::Layer::Layer_Pooling2dLayer);
1140}
1141
1142void SerializerStrategy::SerializePooling3dLayer(const armnn::IConnectableLayer* layer,
1143 const armnn::Pooling3dDescriptor& pooling3dDescriptor,

Callers

nothing calls this directly

Calls 5

GetFlatBufferDataLayoutFunction · 0.85
IgnoreUnusedFunction · 0.50

Tested by

no test coverage detected