blob: a8b5d72da846131dae720273149367d40ea66e9d [file] [log] [blame]
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001//
Mike Kelly3ec30772023-03-08 13:47:17 +00002// Copyright © 2017,2019-2023 Arm Ltd and Contributors. All rights reserved.
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00003// SPDX-License-Identifier: MIT
4//
5
Derek Lamberti0028d1b2019-02-20 13:57:42 +00006namespace armnnSerializer;
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00007
8file_identifier "ARMN";
9
10file_extension "armnn";
11
Mike Kellyaf484012019-02-20 16:53:11 +000012enum ActivationFunction : byte {
13 Sigmoid = 0,
14 TanH = 1,
15 Linear = 2,
16 ReLu = 3,
17 BoundedReLu = 4,
18 SoftReLu = 5,
19 LeakyReLu = 6,
20 Abs = 7,
21 Sqrt = 8,
David Monahan3b3c3812020-02-25 09:03:29 +000022 Square = 9,
Colm Donelan03fbeaf2020-02-26 15:39:23 +000023 Elu = 10,
24 HardSwish = 11
Mike Kellyaf484012019-02-20 16:53:11 +000025}
26
Narumol Prangnawarat0cfcf232019-09-09 17:16:24 +010027enum ArgMinMaxFunction : byte {
28 Min = 0,
29 Max = 1
30}
31
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +000032enum DataType : byte {
33 Float16 = 0,
34 Float32 = 1,
Derek Lambertif90c56d2020-01-10 17:14:08 +000035 QuantisedAsymm8 = 2, // deprecated
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +000036 Signed32 = 3,
Nattapat Chaimanowongcd5ac232019-03-19 12:26:36 +000037 Boolean = 4,
Derek Lambertif90c56d2020-01-10 17:14:08 +000038 QuantisedSymm16 = 5, // deprecated
39 QAsymmU8 = 6,
Francis Murtaghddb1d062020-03-10 13:51:45 +000040 QSymmS16 = 7,
Sadik Armagan1a84fe32020-03-27 15:56:57 +000041 QAsymmS8 = 8,
Mike Kelly1f140f72021-04-06 12:25:55 +010042 QSymmS8 = 9,
43 Signed64 = 10
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +000044}
45
Saoirse Stewart3166c3e2019-02-18 15:24:53 +000046enum DataLayout : byte {
47 NHWC = 0,
Matthew Sloyanb63a3112021-09-08 13:05:51 +010048 NCHW = 1,
Matthew Sloyan5d7b0a32021-10-18 13:07:49 +010049 NDHWC = 2,
50 NCDHW = 3
Saoirse Stewart3166c3e2019-02-18 15:24:53 +000051}
52
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +000053enum ReduceOperation: byte {
54 Sum = 0,
55 Max = 1,
56 Mean = 2,
Teresa Charlin4e3e8312021-08-05 12:34:37 +010057 Min = 3,
58 Prod = 4
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +000059}
60
FinnWilliamsArm6fb339a2019-06-28 15:07:10 +010061enum ResizeMethod: byte {
62 NearestNeighbor = 0,
63 Bilinear = 1,
64}
65
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +000066table TensorInfo {
67 dimensions:[uint];
68 dataType:DataType;
Sadik Armagan1a84fe32020-03-27 15:56:57 +000069 quantizationScale:float = 1.0; // @deprecated Use quantizationScales instead
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +000070 quantizationOffset:int = 0;
Sadik Armagan1a84fe32020-03-27 15:56:57 +000071 quantizationScales:[float];
72 quantizationDim:uint;
Finn Williams2605b232020-06-10 15:53:46 +010073 dimensionality:uint = 1;
Colm Donelan800b2812021-02-12 12:43:35 +000074 dimensionSpecificity:[bool];
Matthew Sloyan81beae32021-07-13 19:46:11 +010075 isConstant:bool = false;
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +000076}
77
78struct Connection {
79 sourceLayerIndex:uint;
80 outputSlotIndex:uint;
81}
82
83table ByteData {
84 data:[byte];
85}
86
87table ShortData {
88 data:[short];
89}
90
91table IntData {
92 data:[int];
93}
94
95table LongData {
96 data:[long];
97}
98
99union ConstTensorData { ByteData, ShortData, IntData, LongData }
100
101table ConstTensor {
102 info:TensorInfo;
103 data:ConstTensorData;
104}
105
106table InputSlot {
107 index:uint;
108 connection:Connection;
109}
110
111table OutputSlot {
112 index:uint;
113 tensorInfo:TensorInfo;
114}
115
116enum LayerType : uint {
117 Addition = 0,
118 Input = 1,
Sadik Armagan5f450272019-02-12 14:31:45 +0000119 Multiplication = 2,
Aron Virginas-Tarfc413c02019-02-13 15:41:52 +0000120 Output = 3,
Saoirse Stewart3166c3e2019-02-18 15:24:53 +0000121 Pooling2d = 4,
Saoirse Stewart263829c2019-02-19 15:54:14 +0000122 Reshape = 5,
Mike Kellya0766c32019-02-19 17:22:07 +0000123 Softmax = 6,
Aron Virginas-Tarc04125f2019-02-19 16:31:08 +0000124 Convolution2d = 7,
Mike Kellyaf484012019-02-20 16:53:11 +0000125 DepthwiseConvolution2d = 8,
Nattapat Chaimanowong30b00202019-02-20 17:31:34 +0000126 Activation = 9,
Sadik Armagandbb0c0c2019-02-21 09:01:41 +0000127 Permute = 10,
Conor Kennedy76277882019-02-26 08:29:54 +0000128 FullyConnected = 11,
Nattapat Chaimanowong45286992019-02-26 15:53:02 +0000129 Constant = 12,
Nattapat Chaimanowong6b4ed982019-02-26 17:24:13 +0000130 SpaceToBatchNd = 13,
Éanna Ó Catháin58885892019-02-27 16:16:39 +0000131 BatchToSpaceNd = 14,
Aron Virginas-Tar0fe32452019-02-28 13:12:47 +0000132 Division = 15,
Nattapat Chaimanowong235cea52019-02-28 16:27:30 +0000133 Minimum = 16,
Aron Virginas-Tar377351e2019-02-27 14:42:31 +0000134 Equal = 17,
Nina Drozd57728782019-02-27 10:53:27 +0000135 Maximum = 18,
Nattapat Chaimanowongebb0f9c2019-03-01 12:14:06 +0000136 Normalization = 19,
Sadik Armagan8b42a382019-03-01 14:24:49 +0000137 Pad = 20,
Finn Williamsdd2ba7e2019-03-01 11:51:52 +0000138 Rsqrt = 21,
ruoyan018e7fa232019-02-28 15:09:07 +0000139 Floor = 22,
Conor Kennedy79ffdf52019-03-01 14:24:54 +0000140 BatchNormalization = 23,
Nattapat Chaimanowong6522cdc2019-03-01 16:14:13 +0000141 Greater = 24,
Conor Kennedyda1f9752019-03-01 14:37:12 +0000142 ResizeBilinear = 25,
Nattapat Chaimanowongb3485212019-03-04 12:35:39 +0000143 Subtraction = 26,
Saoirse Stewarta1ed73a2019-03-04 13:40:12 +0000144 StridedSlice = 27,
Sadik Armaganac97c8c2019-03-04 17:44:21 +0000145 Gather = 28,
Jim Flynnac25a1b2019-02-28 10:40:49 +0000146 Mean = 29,
Narumol Prangnawarat495701f2019-03-07 17:31:34 +0000147 Merger = 30,
Jim Flynn18ce3382019-03-08 11:08:30 +0000148 L2Normalization = 31,
Nattapat Chaimanowong3e14a9d2019-03-18 12:37:06 +0000149 Splitter = 32,
Jim Flynn11af3752019-03-19 17:22:29 +0000150 DetectionPostProcess = 33,
Derek Lamberti87acb272019-03-27 16:51:31 +0000151 Lstm = 34,
Nattapat Chaimanowonge4294fd2019-03-28 09:56:53 +0000152 Quantize = 35,
Nattapat Chaimanowong1f886302019-04-05 13:37:19 +0100153 Dequantize = 36,
Sadik Armaganeff363d2019-04-05 15:25:46 +0100154 Merge = 37,
Jim Flynne242f2d2019-05-22 14:24:13 +0100155 Switch = 38,
Aron Virginas-Taraa067142019-06-11 16:01:44 +0100156 Concat = 39,
Ellen Norris-Thompson51982472019-06-19 11:46:21 +0100157 SpaceToDepth = 40,
Aron Virginas-Tarcb549302019-06-21 13:53:38 +0100158 Prelu = 41,
FinnWilliamsArm6fb339a2019-06-28 15:07:10 +0100159 TransposeConvolution2d = 42,
Matthew Jacksonb5433ee2019-07-11 15:54:20 +0100160 Resize = 43,
Jan Eilers5b01a892019-07-23 09:47:43 +0100161 Stack = 44,
FinnWilliamsArm4ffcc8f2019-09-05 14:34:20 +0100162 QuantizedLstm = 45,
Narumol Prangnawarat0cfcf232019-09-09 17:16:24 +0100163 Abs = 46,
Aron Virginas-Tar2fda80b2019-09-18 13:36:52 +0100164 ArgMinMax = 47,
Aron Virginas-Tarda9d2d32019-09-20 10:42:02 +0100165 Slice = 48,
Aron Virginas-Tar781ced92019-10-03 11:15:39 +0100166 DepthToSpace = 49,
Sadik Armagan26257852019-10-14 13:00:47 +0100167 InstanceNormalization = 50,
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +0100168 LogSoftmax = 51,
Aron Virginas-Tar85121a22019-10-23 10:41:35 +0100169 Comparison = 52,
josh minor4a3c6102020-01-06 16:40:46 -0600170 StandIn = 53,
Mike Kellyc9ea45a2020-02-28 18:11:58 +0000171 ElementwiseUnary = 54,
James Conroy8d333182020-05-13 10:27:58 +0100172 Transpose = 55,
Keith Davis300ad562020-06-04 16:34:23 +0100173 QLstm = 56,
Finn Williams2605b232020-06-10 15:53:46 +0100174 Fill = 57,
James Conroyaba90cd2020-11-06 16:28:18 +0000175 Rank = 58,
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +0000176 LogicalBinary = 59,
mathad01b392e982021-04-07 12:07:30 +0100177 Reduce = 60,
Keith Davis3ae3f972021-05-21 16:33:48 +0100178 Cast = 61,
Narumol Prangnawarata0162e12021-07-23 14:47:49 +0100179 Shape = 62,
180 UnidirectionalSequenceLstm = 63,
Simon Obute51f67772021-09-03 15:50:13 +0100181 ChannelShuffle = 64,
Matthew Sloyanb63a3112021-09-08 13:05:51 +0100182 Convolution3d = 65,
Tamas Nyirid998a1c2021-11-05 14:55:33 +0000183 Pooling3d = 66,
Teresa Charlin6966bfa2022-04-25 17:14:50 +0100184 GatherNd = 67,
Samuel Yapa04f4a12022-08-19 11:14:38 +0100185 BatchMatMul = 68,
Mike Kelly3ec30772023-03-08 13:47:17 +0000186 ElementwiseBinary = 69,
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +0000187}
188
189// Base layer table to be used as part of other layers
190table LayerBase {
191 index:uint;
192 layerName:string;
193 layerType:LayerType;
194 inputSlots:[InputSlot];
195 outputSlots:[OutputSlot];
196}
197
198table BindableLayerBase {
199 base:LayerBase;
200 layerBindingId:int;
201}
202
203// Table for each layer defined below
FinnWilliamsArm4ffcc8f2019-09-05 14:34:20 +0100204
josh minor4a3c6102020-01-06 16:40:46 -0600205/// @deprecated Use ElementwiseUnaryLayer instead
FinnWilliamsArm4ffcc8f2019-09-05 14:34:20 +0100206table AbsLayer {
207 base:LayerBase;
208}
209
Mike Kellyaf484012019-02-20 16:53:11 +0000210table ActivationLayer {
211 base:LayerBase;
212 descriptor:ActivationDescriptor;
213}
214
215table ActivationDescriptor {
Tee Jung86bc3d82019-10-01 11:25:56 +0900216 activationFunction:ActivationFunction = Sigmoid;
Mike Kellyaf484012019-02-20 16:53:11 +0000217 a:float;
218 b:float;
219}
220
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +0000221table AdditionLayer {
222 base:LayerBase;
223}
224
Narumol Prangnawarat0cfcf232019-09-09 17:16:24 +0100225table ArgMinMaxLayer {
226 base:LayerBase;
227 descriptor:ArgMinMaxDescriptor;
228}
229
230table ArgMinMaxDescriptor{
Tee Jung86bc3d82019-10-01 11:25:56 +0900231 argMinMaxFunction:ArgMinMaxFunction;
Narumol Prangnawarat0cfcf232019-09-09 17:16:24 +0100232 axis:int;
233}
234
mathad01b392e982021-04-07 12:07:30 +0100235table CastLayer {
236 base:LayerBase;
237}
238
Simon Obute51f67772021-09-03 15:50:13 +0100239table ChannelShuffleLayer {
240 base:LayerBase;
241 descriptor:ChannelShuffleDescriptor;
242}
243
244table ChannelShuffleDescriptor {
245 axis:uint = 0;
246 numGroups:uint = 0;
247}
248
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +0100249enum ComparisonOperation : byte {
250 Equal = 0,
251 Greater = 1,
252 GreaterOrEqual = 2,
253 Less = 3,
254 LessOrEqual = 4,
255 NotEqual = 5
256}
257
258table ComparisonDescriptor {
259 operation:ComparisonOperation;
260}
261
262table ComparisonLayer {
263 base:LayerBase;
264 descriptor:ComparisonDescriptor;
265}
266
Conor Kennedy76277882019-02-26 08:29:54 +0000267table ConstantLayer {
268 base:LayerBase;
269 input:ConstTensor;
270}
271
Mike Kellya0766c32019-02-19 17:22:07 +0000272table Convolution2dLayer {
273 base:LayerBase;
274 descriptor:Convolution2dDescriptor;
275 weights:ConstTensor;
276 biases:ConstTensor;
277}
278
279table Convolution2dDescriptor {
280 padLeft:uint;
281 padRight:uint;
282 padTop:uint;
283 padBottom:uint;
284 strideX:uint;
285 strideY:uint;
Matthew Benthamacad04e2019-05-13 10:02:45 +0100286 dilationX:uint = 1;
287 dilationY:uint = 1;
Mike Kellya0766c32019-02-19 17:22:07 +0000288 biasEnabled:bool = false;
289 dataLayout:DataLayout = NCHW;
290}
291
Matthew Sloyanb63a3112021-09-08 13:05:51 +0100292table Convolution3dLayer {
293 base:LayerBase;
294 descriptor:Convolution3dDescriptor;
Matthew Sloyanb63a3112021-09-08 13:05:51 +0100295}
296
297table Convolution3dDescriptor {
298 padLeft:uint;
299 padRight:uint;
300 padTop:uint;
301 padBottom:uint;
302 padFront:uint;
303 padBack:uint;
304 strideX:uint;
305 strideY:uint;
306 strideZ:uint;
307 dilationX:uint = 1;
308 dilationY:uint = 1;
309 dilationZ:uint = 1;
310 biasEnabled:bool = false;
311 dataLayout:DataLayout = NDHWC;
312}
313
Aron Virginas-Tarda9d2d32019-09-20 10:42:02 +0100314table DepthToSpaceLayer {
315 base:LayerBase;
316 descriptor:DepthToSpaceDescriptor;
317}
318
319table DepthToSpaceDescriptor {
320 blockSize:uint;
321 dataLayout:DataLayout;
322}
323
Éanna Ó Catháin58885892019-02-27 16:16:39 +0000324table DivisionLayer {
325 base:LayerBase;
326}
327
Mike Kelly3ec30772023-03-08 13:47:17 +0000328enum BinaryOperation : byte {
329 Add = 0,
330 Div = 1,
331 Maximum = 2,
332 Minimum = 3,
333 Mul = 4,
334 Sub = 5
335}
336
337table ElementwiseBinaryDescriptor {
338 operation:BinaryOperation;
339}
340
341table ElementwiseBinaryLayer {
342 base:LayerBase;
343 descriptor:ElementwiseBinaryDescriptor;
344}
345
josh minor4a3c6102020-01-06 16:40:46 -0600346enum UnaryOperation : byte {
347 Abs = 0,
348 Rsqrt = 1,
349 Sqrt = 2,
350 Exp = 3,
James Conroyaba90cd2020-11-06 16:28:18 +0000351 Neg = 4,
Teresa Charlin50de4fa2021-05-31 18:47:33 +0100352 LogicalNot = 5,
353 Log = 6,
Teresa Charlin93f0ad02023-03-23 15:28:02 +0000354 Sin = 7,
355 Ceil = 8
josh minor4a3c6102020-01-06 16:40:46 -0600356}
357
358table ElementwiseUnaryDescriptor {
359 operation:UnaryOperation;
360}
361
362table ElementwiseUnaryLayer {
363 base:LayerBase;
364 descriptor:ElementwiseUnaryDescriptor;
365}
366
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +0100367/// @deprecated Use ComparisonLayer instead
Nattapat Chaimanowong235cea52019-02-28 16:27:30 +0000368table EqualLayer {
369 base:LayerBase;
370}
371
Keith Davis300ad562020-06-04 16:34:23 +0100372table FillLayer {
373 base:LayerBase;
374 descriptor:FillDescriptor;
375}
376
377table FillDescriptor {
378 value:float;
379}
380
Finn Williamsdd2ba7e2019-03-01 11:51:52 +0000381table FloorLayer{
382 base:LayerBase;
383}
384
Sadik Armagandbb0c0c2019-02-21 09:01:41 +0000385table FullyConnectedLayer {
386 base:LayerBase;
387 descriptor:FullyConnectedDescriptor;
Matthew Sloyan81beae32021-07-13 19:46:11 +0100388 weights:ConstTensor; // ConstTensors are now passed as inputs.
Sadik Armagandbb0c0c2019-02-21 09:01:41 +0000389 biases:ConstTensor;
390}
391
392table FullyConnectedDescriptor {
393 biasEnabled:bool = false;
394 transposeWeightsMatrix:bool = false;
Sadik Armaganf0a6dec2021-03-25 07:46:55 +0000395 constantWeights:bool = true;
Sadik Armagandbb0c0c2019-02-21 09:01:41 +0000396}
397
Saoirse Stewarta1ed73a2019-03-04 13:40:12 +0000398table GatherLayer {
399 base:LayerBase;
Teresa Charlin52664732020-06-29 16:27:03 +0100400 descriptor:GatherDescriptor;
401}
402
403table GatherDescriptor {
404 axis:int = 0;
Saoirse Stewarta1ed73a2019-03-04 13:40:12 +0000405}
406
Teresa Charlin6966bfa2022-04-25 17:14:50 +0100407table GatherNdLayer {
408 base:LayerBase;
409}
410
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +0100411/// @deprecated Use ComparisonLayer instead
Conor Kennedy79ffdf52019-03-01 14:24:54 +0000412table GreaterLayer {
413 base:LayerBase;
414}
415
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +0000416table InputLayer {
417 base:BindableLayerBase;
418}
419
Aron Virginas-Tar781ced92019-10-03 11:15:39 +0100420table InstanceNormalizationLayer {
421 base:LayerBase;
422 descriptor:InstanceNormalizationDescriptor;
423}
424
425table InstanceNormalizationDescriptor {
426 gamma:float;
427 beta:float;
428 eps:float;
429 dataLayout:DataLayout;
430}
431
Sadik Armagan26257852019-10-14 13:00:47 +0100432table LogSoftmaxLayer {
433 base:LayerBase;
434 descriptor:LogSoftmaxDescriptor;
435}
436
437table LogSoftmaxDescriptor {
438 beta:float = 1;
439 axis:int = -1;
440}
441
Narumol Prangnawarat495701f2019-03-07 17:31:34 +0000442table L2NormalizationLayer {
443 base:LayerBase;
444 descriptor:L2NormalizationDescriptor;
445}
446
447table L2NormalizationDescriptor {
448 dataLayout:DataLayout = NCHW;
Ferran Balaguer0dcffec2019-06-18 16:25:06 +0100449 eps:float = 1e-12;
Narumol Prangnawarat495701f2019-03-07 17:31:34 +0000450}
451
James Conroyaba90cd2020-11-06 16:28:18 +0000452enum LogicalBinaryOperation : byte {
453 LogicalAnd = 0,
454 LogicalOr = 1
455}
456
457table LogicalBinaryDescriptor {
458 operation:LogicalBinaryOperation;
459}
460
461table LogicalBinaryLayer {
462 base:LayerBase;
463 descriptor:LogicalBinaryDescriptor;
464}
465
Aron Virginas-Tar0fe32452019-02-28 13:12:47 +0000466table MinimumLayer {
467 base:LayerBase;
468}
469
Aron Virginas-Tar377351e2019-02-27 14:42:31 +0000470table MaximumLayer {
471 base:LayerBase;
472}
473
Sadik Armagan5f450272019-02-12 14:31:45 +0000474table MultiplicationLayer {
475 base:LayerBase;
476}
477
Saoirse Stewart3166c3e2019-02-18 15:24:53 +0000478table Pooling2dLayer {
479 base:LayerBase;
480 descriptor:Pooling2dDescriptor;
481}
482
Tamas Nyirid998a1c2021-11-05 14:55:33 +0000483table Pooling3dLayer {
484 base:LayerBase;
485 descriptor:Pooling3dDescriptor;
486}
487
Saoirse Stewart3166c3e2019-02-18 15:24:53 +0000488enum PoolingAlgorithm : byte {
489 Max = 0,
490 Average = 1,
491 L2 = 2
492}
493
494enum OutputShapeRounding : byte {
495 Floor = 0,
496 Ceiling = 1
497}
498
499enum PaddingMethod : byte {
500 IgnoreValue = 0,
501 Exclude = 1
502}
503
504table Pooling2dDescriptor {
505 poolType:PoolingAlgorithm;
506 padLeft:uint;
507 padRight:uint;
508 padTop:uint;
509 padBottom:uint;
510 poolWidth:uint;
511 poolHeight:uint;
512 strideX:uint;
513 strideY:uint;
514 outputShapeRounding:OutputShapeRounding;
515 paddingMethod:PaddingMethod;
516 dataLayout:DataLayout;
517}
518
Tamas Nyirid998a1c2021-11-05 14:55:33 +0000519table Pooling3dDescriptor {
520 poolType:PoolingAlgorithm;
521 padLeft:uint;
522 padRight:uint;
523 padTop:uint;
524 padBottom:uint;
525 padFront:uint;
526 padBack:uint;
527 poolWidth:uint;
528 poolHeight:uint;
529 poolDepth:uint;
530 strideX:uint;
531 strideY:uint;
532 strideZ:uint;
533 outputShapeRounding:OutputShapeRounding;
534 paddingMethod:PaddingMethod;
535 dataLayout:DataLayout;
536}
537
Derek Lamberti87acb272019-03-27 16:51:31 +0000538table QuantizeLayer {
539 base:LayerBase;
540}
541
Aron Virginas-Tarfc413c02019-02-13 15:41:52 +0000542table SoftmaxLayer {
543 base:LayerBase;
544 descriptor:SoftmaxDescriptor;
545}
546
547table SoftmaxDescriptor {
548 beta:float;
Sadik Armaganfd0cae32021-11-08 17:18:31 +0000549 axis:int = -1;
Aron Virginas-Tarfc413c02019-02-13 15:41:52 +0000550}
551
Aron Virginas-Tarc04125f2019-02-19 16:31:08 +0000552table DepthwiseConvolution2dLayer {
553 base:LayerBase;
554 descriptor:DepthwiseConvolution2dDescriptor;
555 weights:ConstTensor;
556 biases:ConstTensor;
557}
558
559table DepthwiseConvolution2dDescriptor {
560 padLeft:uint;
561 padRight:uint;
562 padTop:uint;
563 padBottom:uint;
564 strideX:uint;
565 strideY:uint;
Matthew Benthamacad04e2019-05-13 10:02:45 +0100566 dilationX:uint = 1;
567 dilationY:uint = 1;
Aron Virginas-Tarc04125f2019-02-19 16:31:08 +0000568 biasEnabled:bool = false;
569 dataLayout:DataLayout = NCHW;
570}
571
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +0000572table OutputLayer {
573 base:BindableLayerBase;
574}
575
Saoirse Stewart263829c2019-02-19 15:54:14 +0000576table ReshapeLayer {
577 base:LayerBase;
578 descriptor:ReshapeDescriptor;
579}
580
581table ReshapeDescriptor {
Keith Davis3ae3f972021-05-21 16:33:48 +0100582 targetShape:[uint];
Saoirse Stewart263829c2019-02-19 15:54:14 +0000583}
584
Nattapat Chaimanowong30b00202019-02-20 17:31:34 +0000585table PermuteLayer {
586 base:LayerBase;
587 descriptor:PermuteDescriptor;
588}
589
590table PermuteDescriptor {
591 dimMappings:[uint];
592}
593
Keith Davis3ae3f972021-05-21 16:33:48 +0100594table ShapeLayer {
595 base:LayerBase;
596}
597
Nattapat Chaimanowong45286992019-02-26 15:53:02 +0000598table SpaceToBatchNdLayer {
599 base:LayerBase;
600 descriptor:SpaceToBatchNdDescriptor;
601}
602
603table SpaceToBatchNdDescriptor {
604 blockShape:[uint];
605 padList:[uint];
606 dataLayout:DataLayout;
607}
608
Aron Virginas-Taraa067142019-06-11 16:01:44 +0100609table SpaceToDepthLayer {
610 base:LayerBase;
611 descriptor:SpaceToDepthDescriptor;
612}
613
614table SpaceToDepthDescriptor {
615 blockSize:uint;
616 dataLayout:DataLayout;
617}
618
Conor Kennedyda1f9752019-03-01 14:37:12 +0000619table SubtractionLayer {
620 base:LayerBase;
621}
622
Nattapat Chaimanowong6b4ed982019-02-26 17:24:13 +0000623table BatchToSpaceNdLayer {
624 base:LayerBase;
625 descriptor:BatchToSpaceNdDescriptor;
626}
627
628table BatchToSpaceNdDescriptor {
629 blockShape:[uint];
630 crops:[uint];
631 dataLayout:DataLayout;
632}
633
Nina Drozd57728782019-02-27 10:53:27 +0000634enum NormalizationAlgorithmChannel : byte {
635 Across = 0,
636 Within = 1
637}
638
639enum NormalizationAlgorithmMethod : byte {
640 LocalBrightness = 0,
641 LocalContrast = 1
642}
643
644table NormalizationLayer {
645 base:LayerBase;
646 descriptor:NormalizationDescriptor;
647}
648
649table NormalizationDescriptor {
650 normChannelType:NormalizationAlgorithmChannel = Across;
651 normMethodType:NormalizationAlgorithmMethod = LocalBrightness;
652 normSize:uint;
653 alpha:float;
654 beta:float;
655 k:float;
656 dataLayout:DataLayout = NCHW;
657}
658
Sadik Armaganac97c8c2019-03-04 17:44:21 +0000659table MeanLayer {
660 base:LayerBase;
661 descriptor:MeanDescriptor;
662}
663
664table MeanDescriptor {
665 axis:[uint];
666 keepDims:bool = false;
667}
668
Nattapat Chaimanowongebb0f9c2019-03-01 12:14:06 +0000669table PadLayer {
670 base:LayerBase;
671 descriptor:PadDescriptor;
672}
673
Matthew Sloyan2e5d0b22021-10-21 14:05:31 +0100674enum PaddingMode : byte {
675 Constant = 0,
676 Reflect = 1,
677 Symmetric = 2
678}
679
Nattapat Chaimanowongebb0f9c2019-03-01 12:14:06 +0000680table PadDescriptor {
681 padList:[uint];
David Monahan34757812019-06-19 11:47:21 +0100682 padValue:float = 0;
Matthew Sloyan2e5d0b22021-10-21 14:05:31 +0100683 paddingMode:PaddingMode = Constant;
Nattapat Chaimanowongebb0f9c2019-03-01 12:14:06 +0000684}
685
josh minor4a3c6102020-01-06 16:40:46 -0600686/// @deprecated Use ElementwiseUnaryLayer instead
Sadik Armagan8b42a382019-03-01 14:24:49 +0000687table RsqrtLayer {
688 base:LayerBase;
689}
690
ruoyan018e7fa232019-02-28 15:09:07 +0000691table BatchNormalizationLayer {
692 base:LayerBase;
693 descriptor:BatchNormalizationDescriptor;
694 mean:ConstTensor;
695 variance:ConstTensor;
696 beta:ConstTensor;
697 gamma:ConstTensor;
698}
699
700table BatchNormalizationDescriptor {
701 eps:float;
702 dataLayout:DataLayout;
703}
704
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +0100705/// @deprecated Use ResizeLayer instead
Nattapat Chaimanowong6522cdc2019-03-01 16:14:13 +0000706table ResizeBilinearLayer {
707 base:LayerBase;
708 descriptor:ResizeBilinearDescriptor;
709}
710
711table ResizeBilinearDescriptor {
712 targetWidth:uint;
713 targetHeight:uint;
714 dataLayout:DataLayout;
David Monahan4a0c9b92020-05-30 09:48:39 +0100715 alignCorners:bool;
716 halfPixelCenters:bool;
Nattapat Chaimanowong6522cdc2019-03-01 16:14:13 +0000717}
718
Aron Virginas-Tar2fda80b2019-09-18 13:36:52 +0100719table SliceLayer {
720 base:LayerBase;
721 descriptor:SliceDescriptor;
722}
723
724table SliceDescriptor {
725 begin:[uint];
726 size:[uint];
727}
728
Nattapat Chaimanowongb3485212019-03-04 12:35:39 +0000729table StridedSliceLayer {
730 base:LayerBase;
731 descriptor:StridedSliceDescriptor;
732}
733
734table StridedSliceDescriptor {
735 begin:[int];
736 end:[int];
737 stride:[int];
738 beginMask:int;
739 endMask:int;
740 shrinkAxisMask:int;
741 ellipsisMask:int;
742 newAxisMask:int;
743 dataLayout:DataLayout;
744}
745
Jim Flynne242f2d2019-05-22 14:24:13 +0100746table ConcatLayer {
747 base:LayerBase;
748 descriptor:OriginsDescriptor;
749}
750
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +0100751/// @deprecated Use ConcatLayer instead
Jim Flynnac25a1b2019-02-28 10:40:49 +0000752table MergerLayer {
753 base:LayerBase;
754 descriptor:OriginsDescriptor;
755}
756
757table UintVector {
758 data:[uint];
759}
760
761table OriginsDescriptor {
762 concatAxis:uint;
763 numViews:uint;
764 numDimensions:uint;
765 viewOrigins:[UintVector];
766}
767
Jim Flynn18ce3382019-03-08 11:08:30 +0000768table ViewsDescriptor {
769 origins:OriginsDescriptor;
770 viewSizes:[UintVector];
771}
772
773table SplitterLayer {
774 base:LayerBase;
775 descriptor:ViewsDescriptor;
776}
777
Nattapat Chaimanowong3e14a9d2019-03-18 12:37:06 +0000778table DetectionPostProcessLayer {
779 base:LayerBase;
780 descriptor:DetectionPostProcessDescriptor;
781 anchors:ConstTensor;
782}
783
784table DetectionPostProcessDescriptor {
785 maxDetections:uint;
786 maxClassesPerDetection:uint;
787 detectionsPerClass:uint;
788 nmsScoreThreshold:float;
789 nmsIouThreshold:float;
790 numClasses:uint;
791 useRegularNms:bool;
792 scaleX:float;
793 scaleY:float;
794 scaleW:float;
795 scaleH:float;
796}
797
Jim Flynn11af3752019-03-19 17:22:29 +0000798table LstmInputParams {
799 inputToForgetWeights:ConstTensor;
800 inputToCellWeights:ConstTensor;
801 inputToOutputWeights:ConstTensor;
802 recurrentToForgetWeights:ConstTensor;
803 recurrentToCellWeights:ConstTensor;
804 recurrentToOutputWeights:ConstTensor;
805 forgetGateBias:ConstTensor;
806 cellBias:ConstTensor;
807 outputGateBias:ConstTensor;
808
809 inputToInputWeights:ConstTensor;
810 recurrentToInputWeights:ConstTensor;
811 cellToInputWeights:ConstTensor;
812 inputGateBias:ConstTensor;
813
814 projectionWeights:ConstTensor;
815 projectionBias:ConstTensor;
816
817 cellToForgetWeights:ConstTensor;
818 cellToOutputWeights:ConstTensor;
Jan Eilersf8c62972019-07-17 11:07:49 +0100819
820 inputLayerNormWeights:ConstTensor;
821 forgetLayerNormWeights:ConstTensor;
822 cellLayerNormWeights:ConstTensor;
823 outputLayerNormWeights:ConstTensor;
Jim Flynn11af3752019-03-19 17:22:29 +0000824}
825
James Conroy8d333182020-05-13 10:27:58 +0100826table LstmDescriptor {
827 activationFunc:uint;
828 clippingThresCell:float;
829 clippingThresProj:float;
830 cifgEnabled:bool = true;
831 peepholeEnabled:bool = false;
832 projectionEnabled:bool = false;
833 layerNormEnabled:bool = false;
834}
835
836table LstmLayer {
837 base:LayerBase;
838 descriptor:LstmDescriptor;
839 inputParams:LstmInputParams;
840}
841
842table QLstmInputParams {
843 // Mandatory
844 inputToForgetWeights:ConstTensor;
845 inputToCellWeights:ConstTensor;
846 inputToOutputWeights:ConstTensor;
847
848 recurrentToForgetWeights:ConstTensor;
849 recurrentToCellWeights:ConstTensor;
850 recurrentToOutputWeights:ConstTensor;
851
852 forgetGateBias:ConstTensor;
853 cellBias:ConstTensor;
854 outputGateBias:ConstTensor;
855
856 // CIFG
857 inputToInputWeights:ConstTensor;
858 recurrentToInputWeights:ConstTensor;
859 inputGateBias:ConstTensor;
860
861 // Projection
862 projectionWeights:ConstTensor;
863 projectionBias:ConstTensor;
864
865 // Peephole
866 cellToInputWeights:ConstTensor;
867 cellToForgetWeights:ConstTensor;
868 cellToOutputWeights:ConstTensor;
869
870 // Layer norm
871 inputLayerNormWeights:ConstTensor;
872 forgetLayerNormWeights:ConstTensor;
873 cellLayerNormWeights:ConstTensor;
874 outputLayerNormWeights:ConstTensor;
875}
876
877table QLstmDescriptor {
878 cifgEnabled:bool = true;
879 peepholeEnabled:bool = false;
880 projectionEnabled:bool = false;
881 layerNormEnabled:bool = false;
882
883 cellClip:float;
884 projectionClip:float;
885
886 inputIntermediateScale:float;
887 forgetIntermediateScale:float;
888 cellIntermediateScale:float;
889 outputIntermediateScale:float;
890
891 hiddenStateZeroPoint:int;
892 hiddenStateScale:float;
893}
894
895table QLstmLayer {
896 base:LayerBase;
897 descriptor:QLstmDescriptor;
898 inputParams:QLstmInputParams;
899}
900
Jan Eilers5b01a892019-07-23 09:47:43 +0100901table QuantizedLstmInputParams {
902 inputToInputWeights:ConstTensor;
903 inputToForgetWeights:ConstTensor;
904 inputToCellWeights:ConstTensor;
905 inputToOutputWeights:ConstTensor;
906
907 recurrentToInputWeights:ConstTensor;
908 recurrentToForgetWeights:ConstTensor;
909 recurrentToCellWeights:ConstTensor;
910 recurrentToOutputWeights:ConstTensor;
911
912 inputGateBias:ConstTensor;
913 forgetGateBias:ConstTensor;
914 cellBias:ConstTensor;
915 outputGateBias:ConstTensor;
916}
917
Jan Eilers5b01a892019-07-23 09:47:43 +0100918table QuantizedLstmLayer {
919 base:LayerBase;
920 inputParams:QuantizedLstmInputParams;
921}
922
Nattapat Chaimanowonge4294fd2019-03-28 09:56:53 +0000923table DequantizeLayer {
924 base:LayerBase;
925}
926
Nattapat Chaimanowong1f886302019-04-05 13:37:19 +0100927table MergeLayer {
928 base:LayerBase;
929}
930
Sadik Armaganeff363d2019-04-05 15:25:46 +0100931table SwitchLayer {
932 base:LayerBase;
933}
934
Ellen Norris-Thompson51982472019-06-19 11:46:21 +0100935table PreluLayer {
936 base:LayerBase;
937}
938
Aron Virginas-Tarcb549302019-06-21 13:53:38 +0100939table TransposeConvolution2dLayer {
940 base:LayerBase;
941 descriptor:TransposeConvolution2dDescriptor;
942 weights:ConstTensor;
943 biases:ConstTensor;
944}
945
946table TransposeConvolution2dDescriptor {
947 padLeft:uint;
948 padRight:uint;
949 padTop:uint;
950 padBottom:uint;
951 strideX:uint;
952 strideY:uint;
953 biasEnabled:bool = false;
954 dataLayout:DataLayout = NCHW;
955}
956
Mike Kellyc9ea45a2020-02-28 18:11:58 +0000957table TransposeLayer {
958 base:LayerBase;
959 descriptor:TransposeDescriptor;
960}
961
962table TransposeDescriptor {
963 dimMappings:[uint];
964}
965
FinnWilliamsArm6fb339a2019-06-28 15:07:10 +0100966table ResizeLayer {
967 base:LayerBase;
968 descriptor:ResizeDescriptor;
969}
970
971table ResizeDescriptor {
972 targetHeight:uint;
973 targetWidth:uint;
974 method:ResizeMethod = NearestNeighbor;
975 dataLayout:DataLayout;
David Monahan4a0c9b92020-05-30 09:48:39 +0100976 alignCorners:bool;
977 halfPixelCenters:bool;
FinnWilliamsArm6fb339a2019-06-28 15:07:10 +0100978}
979
Matthew Jacksonb5433ee2019-07-11 15:54:20 +0100980table StackLayer {
981 base:LayerBase;
982 descriptor:StackDescriptor;
983}
984
985table StackDescriptor {
986 axis:uint;
987 numInputs:uint;
988 inputShape:[uint];
989}
990
Aron Virginas-Tar85121a22019-10-23 10:41:35 +0100991table StandInDescriptor {
992 numInputs:uint;
993 numOutputs:uint;
994}
995
996table StandInLayer {
997 base:LayerBase;
998 descriptor:StandInDescriptor;
999}
1000
Finn Williams2605b232020-06-10 15:53:46 +01001001table RankLayer {
1002 base:LayerBase;
1003}
1004
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +00001005table ReduceLayer {
1006 base:LayerBase;
1007 descriptor:ReduceDescriptor;
1008}
1009
1010table ReduceDescriptor {
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +00001011 keepDims:bool = false;
1012 axis:[uint];
1013 reduceOperation:ReduceOperation = Sum;
1014}
1015
Narumol Prangnawarata0162e12021-07-23 14:47:49 +01001016table UnidirectionalSequenceLstmDescriptor {
1017 activationFunc:uint;
1018 clippingThresCell:float;
1019 clippingThresProj:float;
1020 cifgEnabled:bool = true;
1021 peepholeEnabled:bool = false;
1022 projectionEnabled:bool = false;
1023 layerNormEnabled:bool = false;
1024 timeMajor:bool = false;
1025}
1026
1027table UnidirectionalSequenceLstmLayer {
1028 base:LayerBase;
1029 descriptor:UnidirectionalSequenceLstmDescriptor;
1030 inputParams:LstmInputParams;
1031}
1032
Samuel Yapa04f4a12022-08-19 11:14:38 +01001033table BatchMatMulDescriptor {
1034 transposeX:bool = false;
1035 transposeY:bool = false;
1036 adjointX:bool = false;
1037 adjointY:bool = false;
1038 dataLayoutX:DataLayout = NCHW;
1039 dataLayoutY:DataLayout = NCHW;
1040}
1041
1042table BatchMatMulLayer {
1043 base:LayerBase;
1044 descriptor:BatchMatMulDescriptor;
1045}
1046
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001047union Layer {
Mike Kellyaf484012019-02-20 16:53:11 +00001048 ActivationLayer,
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001049 AdditionLayer,
Nattapat Chaimanowong6b4ed982019-02-26 17:24:13 +00001050 BatchToSpaceNdLayer,
ruoyan018e7fa232019-02-28 15:09:07 +00001051 BatchNormalizationLayer,
Conor Kennedy76277882019-02-26 08:29:54 +00001052 ConstantLayer,
Mike Kellya0766c32019-02-19 17:22:07 +00001053 Convolution2dLayer,
Aron Virginas-Tarc04125f2019-02-19 16:31:08 +00001054 DepthwiseConvolution2dLayer,
Sadik Armagandbb0c0c2019-02-21 09:01:41 +00001055 FullyConnectedLayer,
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001056 InputLayer,
Sadik Armagan5f450272019-02-12 14:31:45 +00001057 MultiplicationLayer,
Aron Virginas-Tarfc413c02019-02-13 15:41:52 +00001058 OutputLayer,
Nattapat Chaimanowong30b00202019-02-20 17:31:34 +00001059 PermuteLayer,
Saoirse Stewart3166c3e2019-02-18 15:24:53 +00001060 Pooling2dLayer,
Saoirse Stewart263829c2019-02-19 15:54:14 +00001061 ReshapeLayer,
Nattapat Chaimanowong45286992019-02-26 15:53:02 +00001062 SoftmaxLayer,
Éanna Ó Catháin58885892019-02-27 16:16:39 +00001063 SpaceToBatchNdLayer,
Aron Virginas-Tar0fe32452019-02-28 13:12:47 +00001064 DivisionLayer,
Nattapat Chaimanowong235cea52019-02-28 16:27:30 +00001065 MinimumLayer,
Aron Virginas-Tar377351e2019-02-27 14:42:31 +00001066 EqualLayer,
Nina Drozd57728782019-02-27 10:53:27 +00001067 MaximumLayer,
Nattapat Chaimanowongebb0f9c2019-03-01 12:14:06 +00001068 NormalizationLayer,
Sadik Armagan8b42a382019-03-01 14:24:49 +00001069 PadLayer,
Finn Williamsdd2ba7e2019-03-01 11:51:52 +00001070 RsqrtLayer,
Conor Kennedy79ffdf52019-03-01 14:24:54 +00001071 FloorLayer,
Nattapat Chaimanowong6522cdc2019-03-01 16:14:13 +00001072 GreaterLayer,
Conor Kennedyda1f9752019-03-01 14:37:12 +00001073 ResizeBilinearLayer,
Nattapat Chaimanowongb3485212019-03-04 12:35:39 +00001074 SubtractionLayer,
Saoirse Stewarta1ed73a2019-03-04 13:40:12 +00001075 StridedSliceLayer,
Sadik Armaganac97c8c2019-03-04 17:44:21 +00001076 GatherLayer,
Jim Flynnac25a1b2019-02-28 10:40:49 +00001077 MeanLayer,
Narumol Prangnawarat495701f2019-03-07 17:31:34 +00001078 MergerLayer,
Jim Flynn18ce3382019-03-08 11:08:30 +00001079 L2NormalizationLayer,
Nattapat Chaimanowong3e14a9d2019-03-18 12:37:06 +00001080 SplitterLayer,
Jim Flynn11af3752019-03-19 17:22:29 +00001081 DetectionPostProcessLayer,
Derek Lamberti87acb272019-03-27 16:51:31 +00001082 LstmLayer,
Jan Eilers5b01a892019-07-23 09:47:43 +01001083 QuantizedLstmLayer,
Nattapat Chaimanowonge4294fd2019-03-28 09:56:53 +00001084 QuantizeLayer,
Nattapat Chaimanowong1f886302019-04-05 13:37:19 +01001085 DequantizeLayer,
Sadik Armaganeff363d2019-04-05 15:25:46 +01001086 MergeLayer,
Jim Flynne242f2d2019-05-22 14:24:13 +01001087 SwitchLayer,
Aron Virginas-Taraa067142019-06-11 16:01:44 +01001088 ConcatLayer,
Ellen Norris-Thompson51982472019-06-19 11:46:21 +01001089 SpaceToDepthLayer,
Aron Virginas-Tarcb549302019-06-21 13:53:38 +01001090 PreluLayer,
FinnWilliamsArm6fb339a2019-06-28 15:07:10 +01001091 TransposeConvolution2dLayer,
Matthew Jacksonb5433ee2019-07-11 15:54:20 +01001092 ResizeLayer,
FinnWilliamsArm4ffcc8f2019-09-05 14:34:20 +01001093 StackLayer,
Narumol Prangnawarat0cfcf232019-09-09 17:16:24 +01001094 AbsLayer,
Aron Virginas-Tar2fda80b2019-09-18 13:36:52 +01001095 ArgMinMaxLayer,
Aron Virginas-Tarda9d2d32019-09-20 10:42:02 +01001096 SliceLayer,
Aron Virginas-Tar781ced92019-10-03 11:15:39 +01001097 DepthToSpaceLayer,
Sadik Armagan26257852019-10-14 13:00:47 +01001098 InstanceNormalizationLayer,
Aron Virginas-Tare80ebd12019-10-17 16:11:54 +01001099 LogSoftmaxLayer,
Aron Virginas-Tar85121a22019-10-23 10:41:35 +01001100 ComparisonLayer,
josh minor4a3c6102020-01-06 16:40:46 -06001101 StandInLayer,
Mike Kellyc9ea45a2020-02-28 18:11:58 +00001102 ElementwiseUnaryLayer,
James Conroy8d333182020-05-13 10:27:58 +01001103 TransposeLayer,
Keith Davis300ad562020-06-04 16:34:23 +01001104 QLstmLayer,
Finn Williams2605b232020-06-10 15:53:46 +01001105 FillLayer,
James Conroyaba90cd2020-11-06 16:28:18 +00001106 RankLayer,
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +00001107 LogicalBinaryLayer,
mathad01b392e982021-04-07 12:07:30 +01001108 ReduceLayer,
Keith Davis3ae3f972021-05-21 16:33:48 +01001109 CastLayer,
Narumol Prangnawarata0162e12021-07-23 14:47:49 +01001110 ShapeLayer,
1111 UnidirectionalSequenceLstmLayer,
Simon Obute51f67772021-09-03 15:50:13 +01001112 ChannelShuffleLayer,
Matthew Sloyanb63a3112021-09-08 13:05:51 +01001113 Convolution3dLayer,
Tamas Nyirid998a1c2021-11-05 14:55:33 +00001114 Pooling3dLayer,
Teresa Charlin6966bfa2022-04-25 17:14:50 +01001115 GatherNdLayer,
Samuel Yapa04f4a12022-08-19 11:14:38 +01001116 BatchMatMulLayer,
Mike Kelly3ec30772023-03-08 13:47:17 +00001117 ElementwiseBinaryLayer,
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001118}
1119
Saoirse Stewart49dbe0e2019-02-05 17:27:06 +00001120table AnyLayer {
1121 layer:Layer;
1122}
1123
Tee Jungaa920c52019-11-05 10:48:25 +00001124table FeatureCompatibilityVersions {
1125 bindingIdsScheme:uint = 0;
Jan Eilers53ef7952021-06-02 12:01:25 +01001126 weightsLayoutScheme:uint = 0;
Matthew Sloyan81beae32021-07-13 19:46:11 +01001127 constantTensorsAsInputs:uint = 0;
Tee Jungaa920c52019-11-05 10:48:25 +00001128}
1129
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001130// Root type for serialized data is the graph of the network
1131table SerializedGraph {
Saoirse Stewart49dbe0e2019-02-05 17:27:06 +00001132 layers:[AnyLayer];
Tee Jungaa920c52019-11-05 10:48:25 +00001133 inputIds:[int];
1134 outputIds:[int];
1135 featureVersions:FeatureCompatibilityVersions;
Nattapat Chaimanowong969eea32019-01-30 13:33:11 +00001136}
1137
Sadik Armagan0c3ea5b2021-02-03 09:29:30 +00001138root_type SerializedGraph;