Jan Eilers | 31a7c89 | 2021-01-29 14:18:13 +0000 | [diff] [blame] | 1 | /// Copyright (c) 2021 ARM Limited and Contributors. All rights reserved. |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 2 | /// |
| 3 | /// SPDX-License-Identifier: MIT |
| 4 | /// |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 5 | |
| 6 | namespace armnn |
| 7 | { |
| 8 | /** |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 9 | @page serializer Serializer |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 10 | @tableofcontents |
| 11 | |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 12 | The `armnnSerializer` is a library for serializing an Arm NN network to a stream. |
| 13 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 14 | @section serializersupport Supported Layers |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 15 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 16 | This reference guide provides a list of layers which can be serialized by the Arm NN SDK. |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 17 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 18 | @subsection serializersupportflully Fully supported |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 19 | |
| 20 | The Arm NN SDK Serializer currently supports the following layers: |
| 21 | |
| 22 | - Activation |
| 23 | - Addition |
| 24 | - ArgMinMax |
| 25 | - BatchToSpaceNd |
| 26 | - BatchNormalization |
mathad01 | b392e98 | 2021-04-07 12:07:30 +0100 | [diff] [blame] | 27 | - Cast |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 28 | - Comparison |
| 29 | - Concat |
| 30 | - Constant |
| 31 | - Convolution2d |
| 32 | - DepthToSpace |
| 33 | - DepthwiseConvolution2d |
| 34 | - Dequantize |
| 35 | - DetectionPostProcess |
| 36 | - Division |
| 37 | - ElementwiseUnary |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 38 | - Fill |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 39 | - Floor |
| 40 | - FullyConnected |
| 41 | - Gather |
| 42 | - Input |
| 43 | - InstanceNormalization |
| 44 | - L2Normalization |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 45 | - Logical |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 46 | - LogSoftmax |
| 47 | - Lstm |
| 48 | - Maximum |
| 49 | - Mean |
| 50 | - Merge |
| 51 | - Minimum |
| 52 | - Multiplication |
| 53 | - Normalization |
| 54 | - Output |
| 55 | - Pad |
| 56 | - Permute |
| 57 | - Pooling2d |
| 58 | - Prelu |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 59 | - QLstm |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 60 | - Quantize |
| 61 | - QuantizedLstm |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 62 | - Rank |
Jan Eilers | 1121c6b | 2021-02-19 09:38:03 +0000 | [diff] [blame] | 63 | - Reduce |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 64 | - Reshape |
| 65 | - Resize |
| 66 | - Slice |
| 67 | - Softmax |
| 68 | - SpaceToBatchNd |
| 69 | - SpaceToDepth |
| 70 | - Splitter |
| 71 | - Stack |
| 72 | - StandIn |
| 73 | - StridedSlice |
| 74 | - Subtraction |
| 75 | - Switch |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 76 | - Transpose |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 77 | - TransposeConvolution2d |
| 78 | |
| 79 | More machine learning layers will be supported in future releases. |
| 80 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 81 | @subsection serializersupportdeprecated Deprecated layers |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 82 | |
| 83 | Some layers have been deprecated and replaced by others layers. In order to maintain backward compatibility, serializations of these deprecated layers will deserialize to the layers that have replaced them, as follows: |
| 84 | |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 85 | - Abs will deserialize as ElementwiseUnary |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 86 | - Equal will deserialize as Comparison |
| 87 | - Greater will deserialize as Comparison |
| 88 | - Merger will deserialize as Concat |
| 89 | - ResizeBilinear will deserialize as Resize |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 90 | - Rsqrt will deserialize as ElementwiseUnary |
| 91 | <br/><br/><br/><br/> |
| 92 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 93 | @page deserializer Deserializer |
| 94 | @tableofcontents |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 95 | |
| 96 | The `armnnDeserializer` is a library for loading neural networks defined by Arm NN FlatBuffers files |
| 97 | into the Arm NN runtime. |
| 98 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 99 | @section deserializersupport Supported Layers |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 100 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 101 | This reference guide provides a list of layers which can be deserialized by the Arm NN SDK. |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 102 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 103 | @subsection deserializersupportfully Fully supported |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 104 | |
| 105 | The Arm NN SDK Deserialize parser currently supports the following layers: |
| 106 | |
| 107 | - Abs |
| 108 | - Activation |
| 109 | - Addition |
| 110 | - ArgMinMax |
| 111 | - BatchToSpaceNd |
| 112 | - BatchNormalization |
mathad01 | b392e98 | 2021-04-07 12:07:30 +0100 | [diff] [blame] | 113 | - Cast |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 114 | - Concat |
| 115 | - Comparison |
| 116 | - Constant |
| 117 | - Convolution2d |
| 118 | - DepthToSpace |
| 119 | - DepthwiseConvolution2d |
| 120 | - Dequantize |
| 121 | - DetectionPostProcess |
| 122 | - Division |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 123 | - ElementwiseUnary |
| 124 | - Fill |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 125 | - Floor |
| 126 | - FullyConnected |
| 127 | - Gather |
| 128 | - Input |
| 129 | - InstanceNormalization |
| 130 | - L2Normalization |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 131 | - Logical |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 132 | - LogSoftmax |
| 133 | - Lstm |
| 134 | - Maximum |
| 135 | - Mean |
| 136 | - Merge |
| 137 | - Minimum |
| 138 | - Multiplication |
| 139 | - Normalization |
| 140 | - Output |
| 141 | - Pad |
| 142 | - Permute |
| 143 | - Pooling2d |
| 144 | - Prelu |
| 145 | - Quantize |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 146 | - QLstm |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 147 | - QuantizedLstm |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 148 | - Rank |
Jan Eilers | 1121c6b | 2021-02-19 09:38:03 +0000 | [diff] [blame] | 149 | - Reduce |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 150 | - Reshape |
James Ward | 590f3f7 | 2020-12-02 10:20:48 +0000 | [diff] [blame] | 151 | - Resize |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 152 | - ResizeBilinear |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 153 | - Slice |
| 154 | - Softmax |
| 155 | - SpaceToBatchNd |
| 156 | - SpaceToDepth |
| 157 | - Splitter |
| 158 | - Stack |
| 159 | - StandIn |
| 160 | - StridedSlice |
| 161 | - Subtraction |
| 162 | - Switch |
Jan Eilers | 1121c6b | 2021-02-19 09:38:03 +0000 | [diff] [blame] | 163 | - Transpose |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 164 | - TransposeConvolution2d |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 165 | |
| 166 | More machine learning layers will be supported in future releases. |
| 167 | |
Jan Eilers | 1ed388f | 2021-01-28 14:45:09 +0000 | [diff] [blame] | 168 | @subsection deserializersupportdeprecated Deprecated layers |
Ryan OShea | f3a4323 | 2020-02-12 16:15:27 +0000 | [diff] [blame] | 169 | |
| 170 | Some layers have been deprecated and replaced by others layers. In order to maintain backward compatibility, serializations of these deprecated layers will deserialize to the layers that have replaced them, as follows: |
| 171 | |
| 172 | - Equal will deserialize as Comparison |
| 173 | - Merger will deserialize as Concat |
| 174 | - Greater will deserialize as Comparison |
| 175 | - ResizeBilinear will deserialize as Resize |
| 176 | |
| 177 | **/ |
| 178 | } |