1 | /* Copyright 2018 The TensorFlow Authors. All Rights Reserved. |
2 | |
3 | Licensed under the Apache License, Version 2.0 (the "License"); |
4 | you may not use this file except in compliance with the License. |
5 | You may obtain a copy of the License at |
6 | |
7 | http://www.apache.org/licenses/LICENSE-2.0 |
8 | |
9 | Unless required by applicable law or agreed to in writing, software |
10 | distributed under the License is distributed on an "AS IS" BASIS, |
11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | See the License for the specific language governing permissions and |
13 | limitations under the License. |
14 | ==============================================================================*/ |
15 | // automatically generated by the FlatBuffers compiler, do not modify |
16 | |
17 | |
18 | #ifndef FLATBUFFERS_GENERATED_SCHEMA_TFLITE_H_ |
19 | #define FLATBUFFERS_GENERATED_SCHEMA_TFLITE_H_ |
20 | |
21 | #include "flatbuffers/flatbuffers.h" |
22 | |
23 | namespace tflite { |
24 | |
25 | struct CustomQuantization; |
26 | struct CustomQuantizationT; |
27 | |
28 | struct QuantizationParameters; |
29 | struct QuantizationParametersT; |
30 | |
31 | struct Int32Vector; |
32 | struct Int32VectorT; |
33 | |
34 | struct Uint16Vector; |
35 | struct Uint16VectorT; |
36 | |
37 | struct Uint8Vector; |
38 | struct Uint8VectorT; |
39 | |
40 | struct DimensionMetadata; |
41 | struct DimensionMetadataT; |
42 | |
43 | struct SparsityParameters; |
44 | struct SparsityParametersT; |
45 | |
46 | struct Tensor; |
47 | struct TensorT; |
48 | |
49 | struct Conv2DOptions; |
50 | struct Conv2DOptionsT; |
51 | |
52 | struct Pool2DOptions; |
53 | struct Pool2DOptionsT; |
54 | |
55 | struct DepthwiseConv2DOptions; |
56 | struct DepthwiseConv2DOptionsT; |
57 | |
58 | struct ConcatEmbeddingsOptions; |
59 | struct ConcatEmbeddingsOptionsT; |
60 | |
61 | struct LSHProjectionOptions; |
62 | struct LSHProjectionOptionsT; |
63 | |
64 | struct SVDFOptions; |
65 | struct SVDFOptionsT; |
66 | |
67 | struct RNNOptions; |
68 | struct RNNOptionsT; |
69 | |
70 | struct SequenceRNNOptions; |
71 | struct SequenceRNNOptionsT; |
72 | |
73 | struct BidirectionalSequenceRNNOptions; |
74 | struct BidirectionalSequenceRNNOptionsT; |
75 | |
76 | struct FullyConnectedOptions; |
77 | struct FullyConnectedOptionsT; |
78 | |
79 | struct SoftmaxOptions; |
80 | struct SoftmaxOptionsT; |
81 | |
82 | struct ConcatenationOptions; |
83 | struct ConcatenationOptionsT; |
84 | |
85 | struct AddOptions; |
86 | struct AddOptionsT; |
87 | |
88 | struct MulOptions; |
89 | struct MulOptionsT; |
90 | |
91 | struct L2NormOptions; |
92 | struct L2NormOptionsT; |
93 | |
94 | struct LocalResponseNormalizationOptions; |
95 | struct LocalResponseNormalizationOptionsT; |
96 | |
97 | struct LSTMOptions; |
98 | struct LSTMOptionsT; |
99 | |
100 | struct UnidirectionalSequenceLSTMOptions; |
101 | struct UnidirectionalSequenceLSTMOptionsT; |
102 | |
103 | struct BidirectionalSequenceLSTMOptions; |
104 | struct BidirectionalSequenceLSTMOptionsT; |
105 | |
106 | struct ResizeBilinearOptions; |
107 | struct ResizeBilinearOptionsT; |
108 | |
109 | struct ResizeNearestNeighborOptions; |
110 | struct ResizeNearestNeighborOptionsT; |
111 | |
112 | struct CallOptions; |
113 | struct CallOptionsT; |
114 | |
115 | struct PadOptions; |
116 | struct PadOptionsT; |
117 | |
118 | struct PadV2Options; |
119 | struct PadV2OptionsT; |
120 | |
121 | struct ReshapeOptions; |
122 | struct ReshapeOptionsT; |
123 | |
124 | struct SpaceToBatchNDOptions; |
125 | struct SpaceToBatchNDOptionsT; |
126 | |
127 | struct BatchToSpaceNDOptions; |
128 | struct BatchToSpaceNDOptionsT; |
129 | |
130 | struct SkipGramOptions; |
131 | struct SkipGramOptionsT; |
132 | |
133 | struct SpaceToDepthOptions; |
134 | struct SpaceToDepthOptionsT; |
135 | |
136 | struct DepthToSpaceOptions; |
137 | struct DepthToSpaceOptionsT; |
138 | |
139 | struct SubOptions; |
140 | struct SubOptionsT; |
141 | |
142 | struct DivOptions; |
143 | struct DivOptionsT; |
144 | |
145 | struct TopKV2Options; |
146 | struct TopKV2OptionsT; |
147 | |
148 | struct EmbeddingLookupSparseOptions; |
149 | struct EmbeddingLookupSparseOptionsT; |
150 | |
151 | struct GatherOptions; |
152 | struct GatherOptionsT; |
153 | |
154 | struct TransposeOptions; |
155 | struct TransposeOptionsT; |
156 | |
157 | struct ExpOptions; |
158 | struct ExpOptionsT; |
159 | |
160 | struct CosOptions; |
161 | struct CosOptionsT; |
162 | |
163 | struct ReducerOptions; |
164 | struct ReducerOptionsT; |
165 | |
166 | struct SqueezeOptions; |
167 | struct SqueezeOptionsT; |
168 | |
169 | struct SplitOptions; |
170 | struct SplitOptionsT; |
171 | |
172 | struct SplitVOptions; |
173 | struct SplitVOptionsT; |
174 | |
175 | struct StridedSliceOptions; |
176 | struct StridedSliceOptionsT; |
177 | |
178 | struct LogSoftmaxOptions; |
179 | struct LogSoftmaxOptionsT; |
180 | |
181 | struct CastOptions; |
182 | struct CastOptionsT; |
183 | |
184 | struct DequantizeOptions; |
185 | struct DequantizeOptionsT; |
186 | |
187 | struct MaximumMinimumOptions; |
188 | struct MaximumMinimumOptionsT; |
189 | |
190 | struct TileOptions; |
191 | struct TileOptionsT; |
192 | |
193 | struct ArgMaxOptions; |
194 | struct ArgMaxOptionsT; |
195 | |
196 | struct ArgMinOptions; |
197 | struct ArgMinOptionsT; |
198 | |
199 | struct GreaterOptions; |
200 | struct GreaterOptionsT; |
201 | |
202 | struct GreaterEqualOptions; |
203 | struct GreaterEqualOptionsT; |
204 | |
205 | struct LessOptions; |
206 | struct LessOptionsT; |
207 | |
208 | struct LessEqualOptions; |
209 | struct LessEqualOptionsT; |
210 | |
211 | struct NegOptions; |
212 | struct NegOptionsT; |
213 | |
214 | struct SelectOptions; |
215 | struct SelectOptionsT; |
216 | |
217 | struct SliceOptions; |
218 | struct SliceOptionsT; |
219 | |
220 | struct TransposeConvOptions; |
221 | struct TransposeConvOptionsT; |
222 | |
223 | struct ExpandDimsOptions; |
224 | struct ExpandDimsOptionsT; |
225 | |
226 | struct SparseToDenseOptions; |
227 | struct SparseToDenseOptionsT; |
228 | |
229 | struct EqualOptions; |
230 | struct EqualOptionsT; |
231 | |
232 | struct NotEqualOptions; |
233 | struct NotEqualOptionsT; |
234 | |
235 | struct ShapeOptions; |
236 | struct ShapeOptionsT; |
237 | |
238 | struct RankOptions; |
239 | struct RankOptionsT; |
240 | |
241 | struct PowOptions; |
242 | struct PowOptionsT; |
243 | |
244 | struct FakeQuantOptions; |
245 | struct FakeQuantOptionsT; |
246 | |
247 | struct PackOptions; |
248 | struct PackOptionsT; |
249 | |
250 | struct LogicalOrOptions; |
251 | struct LogicalOrOptionsT; |
252 | |
253 | struct OneHotOptions; |
254 | struct OneHotOptionsT; |
255 | |
256 | struct AbsOptions; |
257 | struct AbsOptionsT; |
258 | |
259 | struct HardSwishOptions; |
260 | struct HardSwishOptionsT; |
261 | |
262 | struct LogicalAndOptions; |
263 | struct LogicalAndOptionsT; |
264 | |
265 | struct LogicalNotOptions; |
266 | struct LogicalNotOptionsT; |
267 | |
268 | struct UnpackOptions; |
269 | struct UnpackOptionsT; |
270 | |
271 | struct FloorDivOptions; |
272 | struct FloorDivOptionsT; |
273 | |
274 | struct SquareOptions; |
275 | struct SquareOptionsT; |
276 | |
277 | struct ZerosLikeOptions; |
278 | struct ZerosLikeOptionsT; |
279 | |
280 | struct FillOptions; |
281 | struct FillOptionsT; |
282 | |
283 | struct FloorModOptions; |
284 | struct FloorModOptionsT; |
285 | |
286 | struct RangeOptions; |
287 | struct RangeOptionsT; |
288 | |
289 | struct LeakyReluOptions; |
290 | struct LeakyReluOptionsT; |
291 | |
292 | struct SquaredDifferenceOptions; |
293 | struct SquaredDifferenceOptionsT; |
294 | |
295 | struct MirrorPadOptions; |
296 | struct MirrorPadOptionsT; |
297 | |
298 | struct UniqueOptions; |
299 | struct UniqueOptionsT; |
300 | |
301 | struct ReverseV2Options; |
302 | struct ReverseV2OptionsT; |
303 | |
304 | struct AddNOptions; |
305 | struct AddNOptionsT; |
306 | |
307 | struct GatherNdOptions; |
308 | struct GatherNdOptionsT; |
309 | |
310 | struct WhereOptions; |
311 | struct WhereOptionsT; |
312 | |
313 | struct ReverseSequenceOptions; |
314 | struct ReverseSequenceOptionsT; |
315 | |
316 | struct MatrixDiagOptions; |
317 | struct MatrixDiagOptionsT; |
318 | |
319 | struct QuantizeOptions; |
320 | struct QuantizeOptionsT; |
321 | |
322 | struct MatrixSetDiagOptions; |
323 | struct MatrixSetDiagOptionsT; |
324 | |
325 | struct IfOptions; |
326 | struct IfOptionsT; |
327 | |
328 | struct WhileOptions; |
329 | struct WhileOptionsT; |
330 | |
331 | struct NonMaxSuppressionV4Options; |
332 | struct NonMaxSuppressionV4OptionsT; |
333 | |
334 | struct NonMaxSuppressionV5Options; |
335 | struct NonMaxSuppressionV5OptionsT; |
336 | |
337 | struct ScatterNdOptions; |
338 | struct ScatterNdOptionsT; |
339 | |
340 | struct SelectV2Options; |
341 | struct SelectV2OptionsT; |
342 | |
343 | struct DensifyOptions; |
344 | struct DensifyOptionsT; |
345 | |
346 | struct SegmentSumOptions; |
347 | struct SegmentSumOptionsT; |
348 | |
349 | struct BatchMatMulOptions; |
350 | struct BatchMatMulOptionsT; |
351 | |
352 | struct OperatorCode; |
353 | struct OperatorCodeT; |
354 | |
355 | struct Operator; |
356 | struct OperatorT; |
357 | |
358 | struct SubGraph; |
359 | struct SubGraphT; |
360 | |
361 | struct Buffer; |
362 | struct BufferT; |
363 | |
364 | struct Metadata; |
365 | struct MetadataT; |
366 | |
367 | struct Model; |
368 | struct ModelT; |
369 | |
370 | enum TensorType { |
371 | TensorType_FLOAT32 = 0, |
372 | TensorType_FLOAT16 = 1, |
373 | TensorType_INT32 = 2, |
374 | TensorType_UINT8 = 3, |
375 | TensorType_INT64 = 4, |
376 | TensorType_STRING = 5, |
377 | TensorType_BOOL = 6, |
378 | TensorType_INT16 = 7, |
379 | TensorType_COMPLEX64 = 8, |
380 | TensorType_INT8 = 9, |
381 | TensorType_FLOAT64 = 10, |
382 | TensorType_MIN = TensorType_FLOAT32, |
383 | TensorType_MAX = TensorType_FLOAT64 |
384 | }; |
385 | |
386 | inline const TensorType (&EnumValuesTensorType())[11] { |
387 | static const TensorType values[] = { |
388 | TensorType_FLOAT32, |
389 | TensorType_FLOAT16, |
390 | TensorType_INT32, |
391 | TensorType_UINT8, |
392 | TensorType_INT64, |
393 | TensorType_STRING, |
394 | TensorType_BOOL, |
395 | TensorType_INT16, |
396 | TensorType_COMPLEX64, |
397 | TensorType_INT8, |
398 | TensorType_FLOAT64 |
399 | }; |
400 | return values; |
401 | } |
402 | |
403 | inline const char * const *EnumNamesTensorType() { |
404 | static const char * const names[12] = { |
405 | "FLOAT32" , |
406 | "FLOAT16" , |
407 | "INT32" , |
408 | "UINT8" , |
409 | "INT64" , |
410 | "STRING" , |
411 | "BOOL" , |
412 | "INT16" , |
413 | "COMPLEX64" , |
414 | "INT8" , |
415 | "FLOAT64" , |
416 | nullptr |
417 | }; |
418 | return names; |
419 | } |
420 | |
421 | inline const char *EnumNameTensorType(TensorType e) { |
422 | if (flatbuffers::IsOutRange(e, TensorType_FLOAT32, TensorType_FLOAT64)) return "" ; |
423 | const size_t index = static_cast<size_t>(e); |
424 | return EnumNamesTensorType()[index]; |
425 | } |
426 | |
427 | enum QuantizationDetails { |
428 | QuantizationDetails_NONE = 0, |
429 | QuantizationDetails_CustomQuantization = 1, |
430 | QuantizationDetails_MIN = QuantizationDetails_NONE, |
431 | QuantizationDetails_MAX = QuantizationDetails_CustomQuantization |
432 | }; |
433 | |
434 | inline const QuantizationDetails (&EnumValuesQuantizationDetails())[2] { |
435 | static const QuantizationDetails values[] = { |
436 | QuantizationDetails_NONE, |
437 | QuantizationDetails_CustomQuantization |
438 | }; |
439 | return values; |
440 | } |
441 | |
442 | inline const char * const *EnumNamesQuantizationDetails() { |
443 | static const char * const names[3] = { |
444 | "NONE" , |
445 | "CustomQuantization" , |
446 | nullptr |
447 | }; |
448 | return names; |
449 | } |
450 | |
451 | inline const char *EnumNameQuantizationDetails(QuantizationDetails e) { |
452 | if (flatbuffers::IsOutRange(e, QuantizationDetails_NONE, QuantizationDetails_CustomQuantization)) return "" ; |
453 | const size_t index = static_cast<size_t>(e); |
454 | return EnumNamesQuantizationDetails()[index]; |
455 | } |
456 | |
457 | template<typename T> struct QuantizationDetailsTraits { |
458 | static const QuantizationDetails enum_value = QuantizationDetails_NONE; |
459 | }; |
460 | |
461 | template<> struct QuantizationDetailsTraits<tflite::CustomQuantization> { |
462 | static const QuantizationDetails enum_value = QuantizationDetails_CustomQuantization; |
463 | }; |
464 | |
465 | struct QuantizationDetailsUnion { |
466 | QuantizationDetails type; |
467 | void *value; |
468 | |
469 | QuantizationDetailsUnion() : type(QuantizationDetails_NONE), value(nullptr) {} |
470 | QuantizationDetailsUnion(QuantizationDetailsUnion&& u) FLATBUFFERS_NOEXCEPT : |
471 | type(QuantizationDetails_NONE), value(nullptr) |
472 | { std::swap(type, u.type); std::swap(value, u.value); } |
473 | QuantizationDetailsUnion(const QuantizationDetailsUnion &) FLATBUFFERS_NOEXCEPT; |
474 | QuantizationDetailsUnion &operator=(const QuantizationDetailsUnion &u) FLATBUFFERS_NOEXCEPT |
475 | { QuantizationDetailsUnion t(u); std::swap(type, t.type); std::swap(value, t.value); return *this; } |
476 | QuantizationDetailsUnion &operator=(QuantizationDetailsUnion &&u) FLATBUFFERS_NOEXCEPT |
477 | { std::swap(type, u.type); std::swap(value, u.value); return *this; } |
478 | ~QuantizationDetailsUnion() { Reset(); } |
479 | |
480 | void Reset(); |
481 | |
482 | #ifndef FLATBUFFERS_CPP98_STL |
483 | template <typename T> |
484 | void Set(T&& val) { |
485 | using RT = typename std::remove_reference<T>::type; |
486 | Reset(); |
487 | type = QuantizationDetailsTraits<typename RT::TableType>::enum_value; |
488 | if (type != QuantizationDetails_NONE) { |
489 | value = new RT(std::forward<T>(val)); |
490 | } |
491 | } |
492 | #endif // FLATBUFFERS_CPP98_STL |
493 | |
494 | static void *UnPack(const void *obj, QuantizationDetails type, const flatbuffers::resolver_function_t *resolver); |
495 | flatbuffers::Offset<void> Pack(flatbuffers::FlatBufferBuilder &_fbb, const flatbuffers::rehasher_function_t *_rehasher = nullptr) const; |
496 | |
497 | tflite::CustomQuantizationT *AsCustomQuantization() { |
498 | return type == QuantizationDetails_CustomQuantization ? |
499 | reinterpret_cast<tflite::CustomQuantizationT *>(value) : nullptr; |
500 | } |
501 | const tflite::CustomQuantizationT *AsCustomQuantization() const { |
502 | return type == QuantizationDetails_CustomQuantization ? |
503 | reinterpret_cast<const tflite::CustomQuantizationT *>(value) : nullptr; |
504 | } |
505 | }; |
506 | |
507 | bool VerifyQuantizationDetails(flatbuffers::Verifier &verifier, const void *obj, QuantizationDetails type); |
508 | bool VerifyQuantizationDetailsVector(flatbuffers::Verifier &verifier, const flatbuffers::Vector<flatbuffers::Offset<void>> *values, const flatbuffers::Vector<uint8_t> *types); |
509 | |
510 | enum DimensionType { |
511 | DimensionType_DENSE = 0, |
512 | DimensionType_SPARSE_CSR = 1, |
513 | DimensionType_MIN = DimensionType_DENSE, |
514 | DimensionType_MAX = DimensionType_SPARSE_CSR |
515 | }; |
516 | |
517 | inline const DimensionType (&EnumValuesDimensionType())[2] { |
518 | static const DimensionType values[] = { |
519 | DimensionType_DENSE, |
520 | DimensionType_SPARSE_CSR |
521 | }; |
522 | return values; |
523 | } |
524 | |
525 | inline const char * const *EnumNamesDimensionType() { |
526 | static const char * const names[3] = { |
527 | "DENSE" , |
528 | "SPARSE_CSR" , |
529 | nullptr |
530 | }; |
531 | return names; |
532 | } |
533 | |
534 | inline const char *EnumNameDimensionType(DimensionType e) { |
535 | if (flatbuffers::IsOutRange(e, DimensionType_DENSE, DimensionType_SPARSE_CSR)) return "" ; |
536 | const size_t index = static_cast<size_t>(e); |
537 | return EnumNamesDimensionType()[index]; |
538 | } |
539 | |
540 | enum SparseIndexVector { |
541 | SparseIndexVector_NONE = 0, |
542 | SparseIndexVector_Int32Vector = 1, |
543 | SparseIndexVector_Uint16Vector = 2, |
544 | SparseIndexVector_Uint8Vector = 3, |
545 | SparseIndexVector_MIN = SparseIndexVector_NONE, |
546 | SparseIndexVector_MAX = SparseIndexVector_Uint8Vector |
547 | }; |
548 | |
549 | inline const SparseIndexVector (&EnumValuesSparseIndexVector())[4] { |
550 | static const SparseIndexVector values[] = { |
551 | SparseIndexVector_NONE, |
552 | SparseIndexVector_Int32Vector, |
553 | SparseIndexVector_Uint16Vector, |
554 | SparseIndexVector_Uint8Vector |
555 | }; |
556 | return values; |
557 | } |
558 | |
559 | inline const char * const *EnumNamesSparseIndexVector() { |
560 | static const char * const names[5] = { |
561 | "NONE" , |
562 | "Int32Vector" , |
563 | "Uint16Vector" , |
564 | "Uint8Vector" , |
565 | nullptr |
566 | }; |
567 | return names; |
568 | } |
569 | |
570 | inline const char *EnumNameSparseIndexVector(SparseIndexVector e) { |
571 | if (flatbuffers::IsOutRange(e, SparseIndexVector_NONE, SparseIndexVector_Uint8Vector)) return "" ; |
572 | const size_t index = static_cast<size_t>(e); |
573 | return EnumNamesSparseIndexVector()[index]; |
574 | } |
575 | |
576 | template<typename T> struct SparseIndexVectorTraits { |
577 | static const SparseIndexVector enum_value = SparseIndexVector_NONE; |
578 | }; |
579 | |
580 | template<> struct SparseIndexVectorTraits<tflite::Int32Vector> { |
581 | static const SparseIndexVector enum_value = SparseIndexVector_Int32Vector; |
582 | }; |
583 | |
584 | template<> struct SparseIndexVectorTraits<tflite::Uint16Vector> { |
585 | static const SparseIndexVector enum_value = SparseIndexVector_Uint16Vector; |
586 | }; |
587 | |
588 | template<> struct SparseIndexVectorTraits<tflite::Uint8Vector> { |
589 | static const SparseIndexVector enum_value = SparseIndexVector_Uint8Vector; |
590 | }; |
591 | |
592 | struct SparseIndexVectorUnion { |
593 | SparseIndexVector type; |
594 | void *value; |
595 | |
596 | SparseIndexVectorUnion() : type(SparseIndexVector_NONE), value(nullptr) {} |
597 | SparseIndexVectorUnion(SparseIndexVectorUnion&& u) FLATBUFFERS_NOEXCEPT : |
598 | type(SparseIndexVector_NONE), value(nullptr) |
599 | { std::swap(type, u.type); std::swap(value, u.value); } |
600 | SparseIndexVectorUnion(const SparseIndexVectorUnion &) FLATBUFFERS_NOEXCEPT; |
601 | SparseIndexVectorUnion &operator=(const SparseIndexVectorUnion &u) FLATBUFFERS_NOEXCEPT |
602 | { SparseIndexVectorUnion t(u); std::swap(type, t.type); std::swap(value, t.value); return *this; } |
603 | SparseIndexVectorUnion &operator=(SparseIndexVectorUnion &&u) FLATBUFFERS_NOEXCEPT |
604 | { std::swap(type, u.type); std::swap(value, u.value); return *this; } |
605 | ~SparseIndexVectorUnion() { Reset(); } |
606 | |
607 | void Reset(); |
608 | |
609 | #ifndef FLATBUFFERS_CPP98_STL |
610 | template <typename T> |
611 | void Set(T&& val) { |
612 | using RT = typename std::remove_reference<T>::type; |
613 | Reset(); |
614 | type = SparseIndexVectorTraits<typename RT::TableType>::enum_value; |
615 | if (type != SparseIndexVector_NONE) { |
616 | value = new RT(std::forward<T>(val)); |
617 | } |
618 | } |
619 | #endif // FLATBUFFERS_CPP98_STL |
620 | |
621 | static void *UnPack(const void *obj, SparseIndexVector type, const flatbuffers::resolver_function_t *resolver); |
622 | flatbuffers::Offset<void> Pack(flatbuffers::FlatBufferBuilder &_fbb, const flatbuffers::rehasher_function_t *_rehasher = nullptr) const; |
623 | |
624 | tflite::Int32VectorT *AsInt32Vector() { |
625 | return type == SparseIndexVector_Int32Vector ? |
626 | reinterpret_cast<tflite::Int32VectorT *>(value) : nullptr; |
627 | } |
628 | const tflite::Int32VectorT *AsInt32Vector() const { |
629 | return type == SparseIndexVector_Int32Vector ? |
630 | reinterpret_cast<const tflite::Int32VectorT *>(value) : nullptr; |
631 | } |
632 | tflite::Uint16VectorT *AsUint16Vector() { |
633 | return type == SparseIndexVector_Uint16Vector ? |
634 | reinterpret_cast<tflite::Uint16VectorT *>(value) : nullptr; |
635 | } |
636 | const tflite::Uint16VectorT *AsUint16Vector() const { |
637 | return type == SparseIndexVector_Uint16Vector ? |
638 | reinterpret_cast<const tflite::Uint16VectorT *>(value) : nullptr; |
639 | } |
640 | tflite::Uint8VectorT *AsUint8Vector() { |
641 | return type == SparseIndexVector_Uint8Vector ? |
642 | reinterpret_cast<tflite::Uint8VectorT *>(value) : nullptr; |
643 | } |
644 | const tflite::Uint8VectorT *AsUint8Vector() const { |
645 | return type == SparseIndexVector_Uint8Vector ? |
646 | reinterpret_cast<const tflite::Uint8VectorT *>(value) : nullptr; |
647 | } |
648 | }; |
649 | |
650 | bool VerifySparseIndexVector(flatbuffers::Verifier &verifier, const void *obj, SparseIndexVector type); |
651 | bool VerifySparseIndexVectorVector(flatbuffers::Verifier &verifier, const flatbuffers::Vector<flatbuffers::Offset<void>> *values, const flatbuffers::Vector<uint8_t> *types); |
652 | |
653 | enum BuiltinOperator { |
654 | BuiltinOperator_ADD = 0, |
655 | BuiltinOperator_AVERAGE_POOL_2D = 1, |
656 | BuiltinOperator_CONCATENATION = 2, |
657 | BuiltinOperator_CONV_2D = 3, |
658 | BuiltinOperator_DEPTHWISE_CONV_2D = 4, |
659 | BuiltinOperator_DEPTH_TO_SPACE = 5, |
660 | BuiltinOperator_DEQUANTIZE = 6, |
661 | BuiltinOperator_EMBEDDING_LOOKUP = 7, |
662 | BuiltinOperator_FLOOR = 8, |
663 | BuiltinOperator_FULLY_CONNECTED = 9, |
664 | BuiltinOperator_HASHTABLE_LOOKUP = 10, |
665 | BuiltinOperator_L2_NORMALIZATION = 11, |
666 | BuiltinOperator_L2_POOL_2D = 12, |
667 | BuiltinOperator_LOCAL_RESPONSE_NORMALIZATION = 13, |
668 | BuiltinOperator_LOGISTIC = 14, |
669 | BuiltinOperator_LSH_PROJECTION = 15, |
670 | BuiltinOperator_LSTM = 16, |
671 | BuiltinOperator_MAX_POOL_2D = 17, |
672 | BuiltinOperator_MUL = 18, |
673 | BuiltinOperator_RELU = 19, |
674 | BuiltinOperator_RELU_N1_TO_1 = 20, |
675 | BuiltinOperator_RELU6 = 21, |
676 | BuiltinOperator_RESHAPE = 22, |
677 | BuiltinOperator_RESIZE_BILINEAR = 23, |
678 | BuiltinOperator_RNN = 24, |
679 | BuiltinOperator_SOFTMAX = 25, |
680 | BuiltinOperator_SPACE_TO_DEPTH = 26, |
681 | BuiltinOperator_SVDF = 27, |
682 | BuiltinOperator_TANH = 28, |
683 | BuiltinOperator_CONCAT_EMBEDDINGS = 29, |
684 | BuiltinOperator_SKIP_GRAM = 30, |
685 | BuiltinOperator_CALL = 31, |
686 | BuiltinOperator_CUSTOM = 32, |
687 | BuiltinOperator_EMBEDDING_LOOKUP_SPARSE = 33, |
688 | BuiltinOperator_PAD = 34, |
689 | BuiltinOperator_UNIDIRECTIONAL_SEQUENCE_RNN = 35, |
690 | BuiltinOperator_GATHER = 36, |
691 | BuiltinOperator_BATCH_TO_SPACE_ND = 37, |
692 | BuiltinOperator_SPACE_TO_BATCH_ND = 38, |
693 | BuiltinOperator_TRANSPOSE = 39, |
694 | BuiltinOperator_MEAN = 40, |
695 | BuiltinOperator_SUB = 41, |
696 | BuiltinOperator_DIV = 42, |
697 | BuiltinOperator_SQUEEZE = 43, |
698 | BuiltinOperator_UNIDIRECTIONAL_SEQUENCE_LSTM = 44, |
699 | BuiltinOperator_STRIDED_SLICE = 45, |
700 | BuiltinOperator_BIDIRECTIONAL_SEQUENCE_RNN = 46, |
701 | BuiltinOperator_EXP = 47, |
702 | BuiltinOperator_TOPK_V2 = 48, |
703 | BuiltinOperator_SPLIT = 49, |
704 | BuiltinOperator_LOG_SOFTMAX = 50, |
705 | BuiltinOperator_DELEGATE = 51, |
706 | BuiltinOperator_BIDIRECTIONAL_SEQUENCE_LSTM = 52, |
707 | BuiltinOperator_CAST = 53, |
708 | BuiltinOperator_PRELU = 54, |
709 | BuiltinOperator_MAXIMUM = 55, |
710 | BuiltinOperator_ARG_MAX = 56, |
711 | BuiltinOperator_MINIMUM = 57, |
712 | BuiltinOperator_LESS = 58, |
713 | BuiltinOperator_NEG = 59, |
714 | BuiltinOperator_PADV2 = 60, |
715 | BuiltinOperator_GREATER = 61, |
716 | BuiltinOperator_GREATER_EQUAL = 62, |
717 | BuiltinOperator_LESS_EQUAL = 63, |
718 | BuiltinOperator_SELECT = 64, |
719 | BuiltinOperator_SLICE = 65, |
720 | BuiltinOperator_SIN = 66, |
721 | BuiltinOperator_TRANSPOSE_CONV = 67, |
722 | BuiltinOperator_SPARSE_TO_DENSE = 68, |
723 | BuiltinOperator_TILE = 69, |
724 | BuiltinOperator_EXPAND_DIMS = 70, |
725 | BuiltinOperator_EQUAL = 71, |
726 | BuiltinOperator_NOT_EQUAL = 72, |
727 | BuiltinOperator_LOG = 73, |
728 | BuiltinOperator_SUM = 74, |
729 | BuiltinOperator_SQRT = 75, |
730 | BuiltinOperator_RSQRT = 76, |
731 | BuiltinOperator_SHAPE = 77, |
732 | BuiltinOperator_POW = 78, |
733 | BuiltinOperator_ARG_MIN = 79, |
734 | BuiltinOperator_FAKE_QUANT = 80, |
735 | BuiltinOperator_REDUCE_PROD = 81, |
736 | BuiltinOperator_REDUCE_MAX = 82, |
737 | BuiltinOperator_PACK = 83, |
738 | BuiltinOperator_LOGICAL_OR = 84, |
739 | BuiltinOperator_ONE_HOT = 85, |
740 | BuiltinOperator_LOGICAL_AND = 86, |
741 | BuiltinOperator_LOGICAL_NOT = 87, |
742 | BuiltinOperator_UNPACK = 88, |
743 | BuiltinOperator_REDUCE_MIN = 89, |
744 | BuiltinOperator_FLOOR_DIV = 90, |
745 | BuiltinOperator_REDUCE_ANY = 91, |
746 | BuiltinOperator_SQUARE = 92, |
747 | BuiltinOperator_ZEROS_LIKE = 93, |
748 | BuiltinOperator_FILL = 94, |
749 | BuiltinOperator_FLOOR_MOD = 95, |
750 | BuiltinOperator_RANGE = 96, |
751 | BuiltinOperator_RESIZE_NEAREST_NEIGHBOR = 97, |
752 | BuiltinOperator_LEAKY_RELU = 98, |
753 | BuiltinOperator_SQUARED_DIFFERENCE = 99, |
754 | BuiltinOperator_MIRROR_PAD = 100, |
755 | BuiltinOperator_ABS = 101, |
756 | BuiltinOperator_SPLIT_V = 102, |
757 | BuiltinOperator_UNIQUE = 103, |
758 | BuiltinOperator_CEIL = 104, |
759 | BuiltinOperator_REVERSE_V2 = 105, |
760 | BuiltinOperator_ADD_N = 106, |
761 | BuiltinOperator_GATHER_ND = 107, |
762 | BuiltinOperator_COS = 108, |
763 | BuiltinOperator_WHERE = 109, |
764 | BuiltinOperator_RANK = 110, |
765 | BuiltinOperator_ELU = 111, |
766 | BuiltinOperator_REVERSE_SEQUENCE = 112, |
767 | BuiltinOperator_MATRIX_DIAG = 113, |
768 | BuiltinOperator_QUANTIZE = 114, |
769 | BuiltinOperator_MATRIX_SET_DIAG = 115, |
770 | BuiltinOperator_ROUND = 116, |
771 | BuiltinOperator_HARD_SWISH = 117, |
772 | BuiltinOperator_IF = 118, |
773 | BuiltinOperator_WHILE = 119, |
774 | BuiltinOperator_NON_MAX_SUPPRESSION_V4 = 120, |
775 | BuiltinOperator_NON_MAX_SUPPRESSION_V5 = 121, |
776 | BuiltinOperator_SCATTER_ND = 122, |
777 | BuiltinOperator_SELECT_V2 = 123, |
778 | BuiltinOperator_DENSIFY = 124, |
779 | BuiltinOperator_SEGMENT_SUM = 125, |
780 | BuiltinOperator_BATCH_MATMUL = 126, |
781 | BuiltinOperator_MIN = BuiltinOperator_ADD, |
782 | BuiltinOperator_MAX = BuiltinOperator_BATCH_MATMUL |
783 | }; |
784 | |
785 | inline const BuiltinOperator (&EnumValuesBuiltinOperator())[127] { |
786 | static const BuiltinOperator values[] = { |
787 | BuiltinOperator_ADD, |
788 | BuiltinOperator_AVERAGE_POOL_2D, |
789 | BuiltinOperator_CONCATENATION, |
790 | BuiltinOperator_CONV_2D, |
791 | BuiltinOperator_DEPTHWISE_CONV_2D, |
792 | BuiltinOperator_DEPTH_TO_SPACE, |
793 | BuiltinOperator_DEQUANTIZE, |
794 | BuiltinOperator_EMBEDDING_LOOKUP, |
795 | BuiltinOperator_FLOOR, |
796 | BuiltinOperator_FULLY_CONNECTED, |
797 | BuiltinOperator_HASHTABLE_LOOKUP, |
798 | BuiltinOperator_L2_NORMALIZATION, |
799 | BuiltinOperator_L2_POOL_2D, |
800 | BuiltinOperator_LOCAL_RESPONSE_NORMALIZATION, |
801 | BuiltinOperator_LOGISTIC, |
802 | BuiltinOperator_LSH_PROJECTION, |
803 | BuiltinOperator_LSTM, |
804 | BuiltinOperator_MAX_POOL_2D, |
805 | BuiltinOperator_MUL, |
806 | BuiltinOperator_RELU, |
807 | BuiltinOperator_RELU_N1_TO_1, |
808 | BuiltinOperator_RELU6, |
809 | BuiltinOperator_RESHAPE, |
810 | BuiltinOperator_RESIZE_BILINEAR, |
811 | BuiltinOperator_RNN, |
812 | BuiltinOperator_SOFTMAX, |
813 | BuiltinOperator_SPACE_TO_DEPTH, |
814 | BuiltinOperator_SVDF, |
815 | BuiltinOperator_TANH, |
816 | BuiltinOperator_CONCAT_EMBEDDINGS, |
817 | BuiltinOperator_SKIP_GRAM, |
818 | BuiltinOperator_CALL, |
819 | BuiltinOperator_CUSTOM, |
820 | BuiltinOperator_EMBEDDING_LOOKUP_SPARSE, |
821 | BuiltinOperator_PAD, |
822 | BuiltinOperator_UNIDIRECTIONAL_SEQUENCE_RNN, |
823 | BuiltinOperator_GATHER, |
824 | BuiltinOperator_BATCH_TO_SPACE_ND, |
825 | BuiltinOperator_SPACE_TO_BATCH_ND, |
826 | BuiltinOperator_TRANSPOSE, |
827 | BuiltinOperator_MEAN, |
828 | BuiltinOperator_SUB, |
829 | BuiltinOperator_DIV, |
830 | BuiltinOperator_SQUEEZE, |
831 | BuiltinOperator_UNIDIRECTIONAL_SEQUENCE_LSTM, |
832 | BuiltinOperator_STRIDED_SLICE, |
833 | BuiltinOperator_BIDIRECTIONAL_SEQUENCE_RNN, |
834 | BuiltinOperator_EXP, |
835 | BuiltinOperator_TOPK_V2, |
836 | BuiltinOperator_SPLIT, |
837 | BuiltinOperator_LOG_SOFTMAX, |
838 | BuiltinOperator_DELEGATE, |
839 | BuiltinOperator_BIDIRECTIONAL_SEQUENCE_LSTM, |
840 | BuiltinOperator_CAST, |
841 | BuiltinOperator_PRELU, |
842 | BuiltinOperator_MAXIMUM, |
843 | BuiltinOperator_ARG_MAX, |
844 | BuiltinOperator_MINIMUM, |
845 | BuiltinOperator_LESS, |
846 | BuiltinOperator_NEG, |
847 | BuiltinOperator_PADV2, |
848 | BuiltinOperator_GREATER, |
849 | BuiltinOperator_GREATER_EQUAL, |
850 | BuiltinOperator_LESS_EQUAL, |
851 | BuiltinOperator_SELECT, |
852 | BuiltinOperator_SLICE, |
853 | BuiltinOperator_SIN, |
854 | BuiltinOperator_TRANSPOSE_CONV, |
855 | BuiltinOperator_SPARSE_TO_DENSE, |
856 | BuiltinOperator_TILE, |
857 | BuiltinOperator_EXPAND_DIMS, |
858 | BuiltinOperator_EQUAL, |
859 | BuiltinOperator_NOT_EQUAL, |
860 | BuiltinOperator_LOG, |
861 | BuiltinOperator_SUM, |
862 | BuiltinOperator_SQRT, |
863 | BuiltinOperator_RSQRT, |
864 | BuiltinOperator_SHAPE, |
865 | BuiltinOperator_POW, |
866 | BuiltinOperator_ARG_MIN, |
867 | BuiltinOperator_FAKE_QUANT, |
868 | BuiltinOperator_REDUCE_PROD, |
869 | BuiltinOperator_REDUCE_MAX, |
870 | BuiltinOperator_PACK, |
871 | BuiltinOperator_LOGICAL_OR, |
872 | BuiltinOperator_ONE_HOT, |
873 | BuiltinOperator_LOGICAL_AND, |
874 | BuiltinOperator_LOGICAL_NOT, |
875 | BuiltinOperator_UNPACK, |
876 | BuiltinOperator_REDUCE_MIN, |
877 | BuiltinOperator_FLOOR_DIV, |
878 | BuiltinOperator_REDUCE_ANY, |
879 | BuiltinOperator_SQUARE, |
880 | BuiltinOperator_ZEROS_LIKE, |
881 | BuiltinOperator_FILL, |
882 | BuiltinOperator_FLOOR_MOD, |
883 | BuiltinOperator_RANGE, |
884 | BuiltinOperator_RESIZE_NEAREST_NEIGHBOR, |
885 | BuiltinOperator_LEAKY_RELU, |
886 | BuiltinOperator_SQUARED_DIFFERENCE, |
887 | BuiltinOperator_MIRROR_PAD, |
888 | BuiltinOperator_ABS, |
889 | BuiltinOperator_SPLIT_V, |
890 | BuiltinOperator_UNIQUE, |
891 | BuiltinOperator_CEIL, |
892 | BuiltinOperator_REVERSE_V2, |
893 | BuiltinOperator_ADD_N, |
894 | BuiltinOperator_GATHER_ND, |
895 | BuiltinOperator_COS, |
896 | BuiltinOperator_WHERE, |
897 | BuiltinOperator_RANK, |
898 | BuiltinOperator_ELU, |
899 | BuiltinOperator_REVERSE_SEQUENCE, |
900 | BuiltinOperator_MATRIX_DIAG, |
901 | BuiltinOperator_QUANTIZE, |
902 | BuiltinOperator_MATRIX_SET_DIAG, |
903 | BuiltinOperator_ROUND, |
904 | BuiltinOperator_HARD_SWISH, |
905 | BuiltinOperator_IF, |
906 | BuiltinOperator_WHILE, |
907 | BuiltinOperator_NON_MAX_SUPPRESSION_V4, |
908 | BuiltinOperator_NON_MAX_SUPPRESSION_V5, |
909 | BuiltinOperator_SCATTER_ND, |
910 | BuiltinOperator_SELECT_V2, |
911 | BuiltinOperator_DENSIFY, |
912 | BuiltinOperator_SEGMENT_SUM, |
913 | BuiltinOperator_BATCH_MATMUL |
914 | }; |
915 | return values; |
916 | } |
917 | |
918 | inline const char * const *EnumNamesBuiltinOperator() { |
919 | static const char * const names[128] = { |
920 | "ADD" , |
921 | "AVERAGE_POOL_2D" , |
922 | "CONCATENATION" , |
923 | "CONV_2D" , |
924 | "DEPTHWISE_CONV_2D" , |
925 | "DEPTH_TO_SPACE" , |
926 | "DEQUANTIZE" , |
927 | "EMBEDDING_LOOKUP" , |
928 | "FLOOR" , |
929 | "FULLY_CONNECTED" , |
930 | "HASHTABLE_LOOKUP" , |
931 | "L2_NORMALIZATION" , |
932 | "L2_POOL_2D" , |
933 | "LOCAL_RESPONSE_NORMALIZATION" , |
934 | "LOGISTIC" , |
935 | "LSH_PROJECTION" , |
936 | "LSTM" , |
937 | "MAX_POOL_2D" , |
938 | "MUL" , |
939 | "RELU" , |
940 | "RELU_N1_TO_1" , |
941 | "RELU6" , |
942 | "RESHAPE" , |
943 | "RESIZE_BILINEAR" , |
944 | "RNN" , |
945 | "SOFTMAX" , |
946 | "SPACE_TO_DEPTH" , |
947 | "SVDF" , |
948 | "TANH" , |
949 | "CONCAT_EMBEDDINGS" , |
950 | "SKIP_GRAM" , |
951 | "CALL" , |
952 | "CUSTOM" , |
953 | "EMBEDDING_LOOKUP_SPARSE" , |
954 | "PAD" , |
955 | "UNIDIRECTIONAL_SEQUENCE_RNN" , |
956 | "GATHER" , |
957 | "BATCH_TO_SPACE_ND" , |
958 | "SPACE_TO_BATCH_ND" , |
959 | "TRANSPOSE" , |
960 | "MEAN" , |
961 | "SUB" , |
962 | "DIV" , |
963 | "SQUEEZE" , |
964 | "UNIDIRECTIONAL_SEQUENCE_LSTM" , |
965 | "STRIDED_SLICE" , |
966 | "BIDIRECTIONAL_SEQUENCE_RNN" , |
967 | "EXP" , |
968 | "TOPK_V2" , |
969 | "SPLIT" , |
970 | "LOG_SOFTMAX" , |
971 | "DELEGATE" , |
972 | "BIDIRECTIONAL_SEQUENCE_LSTM" , |
973 | "CAST" , |
974 | "PRELU" , |
975 | "MAXIMUM" , |
976 | "ARG_MAX" , |
977 | "MINIMUM" , |
978 | "LESS" , |
979 | "NEG" , |
980 | "PADV2" , |
981 | "GREATER" , |
982 | "GREATER_EQUAL" , |
983 | "LESS_EQUAL" , |
984 | "SELECT" , |
985 | "SLICE" , |
986 | "SIN" , |
987 | "TRANSPOSE_CONV" , |
988 | "SPARSE_TO_DENSE" , |
989 | "TILE" , |
990 | "EXPAND_DIMS" , |
991 | "EQUAL" , |
992 | "NOT_EQUAL" , |
993 | "LOG" , |
994 | "SUM" , |
995 | "SQRT" , |
996 | "RSQRT" , |
997 | "SHAPE" , |
998 | "POW" , |
999 | "ARG_MIN" , |
1000 | "FAKE_QUANT" , |
1001 | "REDUCE_PROD" , |
1002 | "REDUCE_MAX" , |
1003 | "PACK" , |
1004 | "LOGICAL_OR" , |
1005 | "ONE_HOT" , |
1006 | "LOGICAL_AND" , |
1007 | "LOGICAL_NOT" , |
1008 | "UNPACK" , |
1009 | "REDUCE_MIN" , |
1010 | "FLOOR_DIV" , |
1011 | "REDUCE_ANY" , |
1012 | "SQUARE" , |
1013 | "ZEROS_LIKE" , |
1014 | "FILL" , |
1015 | "FLOOR_MOD" , |
1016 | "RANGE" , |
1017 | "RESIZE_NEAREST_NEIGHBOR" , |
1018 | "LEAKY_RELU" , |
1019 | "SQUARED_DIFFERENCE" , |
1020 | "MIRROR_PAD" , |
1021 | "ABS" , |
1022 | "SPLIT_V" , |
1023 | "UNIQUE" , |
1024 | "CEIL" , |
1025 | "REVERSE_V2" , |
1026 | "ADD_N" , |
1027 | "GATHER_ND" , |
1028 | "COS" , |
1029 | "WHERE" , |
1030 | "RANK" , |
1031 | "ELU" , |
1032 | "REVERSE_SEQUENCE" , |
1033 | "MATRIX_DIAG" , |
1034 | "QUANTIZE" , |
1035 | "MATRIX_SET_DIAG" , |
1036 | "ROUND" , |
1037 | "HARD_SWISH" , |
1038 | "IF" , |
1039 | "WHILE" , |
1040 | "NON_MAX_SUPPRESSION_V4" , |
1041 | "NON_MAX_SUPPRESSION_V5" , |
1042 | "SCATTER_ND" , |
1043 | "SELECT_V2" , |
1044 | "DENSIFY" , |
1045 | "SEGMENT_SUM" , |
1046 | "BATCH_MATMUL" , |
1047 | nullptr |
1048 | }; |
1049 | return names; |
1050 | } |
1051 | |
1052 | inline const char *EnumNameBuiltinOperator(BuiltinOperator e) { |
1053 | if (flatbuffers::IsOutRange(e, BuiltinOperator_ADD, BuiltinOperator_BATCH_MATMUL)) return "" ; |
1054 | const size_t index = static_cast<size_t>(e); |
1055 | return EnumNamesBuiltinOperator()[index]; |
1056 | } |
1057 | |
1058 | enum BuiltinOptions { |
1059 | BuiltinOptions_NONE = 0, |
1060 | BuiltinOptions_Conv2DOptions = 1, |
1061 | BuiltinOptions_DepthwiseConv2DOptions = 2, |
1062 | BuiltinOptions_ConcatEmbeddingsOptions = 3, |
1063 | BuiltinOptions_LSHProjectionOptions = 4, |
1064 | BuiltinOptions_Pool2DOptions = 5, |
1065 | BuiltinOptions_SVDFOptions = 6, |
1066 | BuiltinOptions_RNNOptions = 7, |
1067 | BuiltinOptions_FullyConnectedOptions = 8, |
1068 | BuiltinOptions_SoftmaxOptions = 9, |
1069 | BuiltinOptions_ConcatenationOptions = 10, |
1070 | BuiltinOptions_AddOptions = 11, |
1071 | BuiltinOptions_L2NormOptions = 12, |
1072 | BuiltinOptions_LocalResponseNormalizationOptions = 13, |
1073 | BuiltinOptions_LSTMOptions = 14, |
1074 | BuiltinOptions_ResizeBilinearOptions = 15, |
1075 | BuiltinOptions_CallOptions = 16, |
1076 | BuiltinOptions_ReshapeOptions = 17, |
1077 | BuiltinOptions_SkipGramOptions = 18, |
1078 | BuiltinOptions_SpaceToDepthOptions = 19, |
1079 | BuiltinOptions_EmbeddingLookupSparseOptions = 20, |
1080 | BuiltinOptions_MulOptions = 21, |
1081 | BuiltinOptions_PadOptions = 22, |
1082 | BuiltinOptions_GatherOptions = 23, |
1083 | BuiltinOptions_BatchToSpaceNDOptions = 24, |
1084 | BuiltinOptions_SpaceToBatchNDOptions = 25, |
1085 | BuiltinOptions_TransposeOptions = 26, |
1086 | BuiltinOptions_ReducerOptions = 27, |
1087 | BuiltinOptions_SubOptions = 28, |
1088 | BuiltinOptions_DivOptions = 29, |
1089 | BuiltinOptions_SqueezeOptions = 30, |
1090 | BuiltinOptions_SequenceRNNOptions = 31, |
1091 | BuiltinOptions_StridedSliceOptions = 32, |
1092 | BuiltinOptions_ExpOptions = 33, |
1093 | BuiltinOptions_TopKV2Options = 34, |
1094 | BuiltinOptions_SplitOptions = 35, |
1095 | BuiltinOptions_LogSoftmaxOptions = 36, |
1096 | BuiltinOptions_CastOptions = 37, |
1097 | BuiltinOptions_DequantizeOptions = 38, |
1098 | BuiltinOptions_MaximumMinimumOptions = 39, |
1099 | BuiltinOptions_ArgMaxOptions = 40, |
1100 | BuiltinOptions_LessOptions = 41, |
1101 | BuiltinOptions_NegOptions = 42, |
1102 | BuiltinOptions_PadV2Options = 43, |
1103 | BuiltinOptions_GreaterOptions = 44, |
1104 | BuiltinOptions_GreaterEqualOptions = 45, |
1105 | BuiltinOptions_LessEqualOptions = 46, |
1106 | BuiltinOptions_SelectOptions = 47, |
1107 | BuiltinOptions_SliceOptions = 48, |
1108 | BuiltinOptions_TransposeConvOptions = 49, |
1109 | BuiltinOptions_SparseToDenseOptions = 50, |
1110 | BuiltinOptions_TileOptions = 51, |
1111 | BuiltinOptions_ExpandDimsOptions = 52, |
1112 | BuiltinOptions_EqualOptions = 53, |
1113 | BuiltinOptions_NotEqualOptions = 54, |
1114 | BuiltinOptions_ShapeOptions = 55, |
1115 | BuiltinOptions_PowOptions = 56, |
1116 | BuiltinOptions_ArgMinOptions = 57, |
1117 | BuiltinOptions_FakeQuantOptions = 58, |
1118 | BuiltinOptions_PackOptions = 59, |
1119 | BuiltinOptions_LogicalOrOptions = 60, |
1120 | BuiltinOptions_OneHotOptions = 61, |
1121 | BuiltinOptions_LogicalAndOptions = 62, |
1122 | BuiltinOptions_LogicalNotOptions = 63, |
1123 | BuiltinOptions_UnpackOptions = 64, |
1124 | BuiltinOptions_FloorDivOptions = 65, |
1125 | BuiltinOptions_SquareOptions = 66, |
1126 | BuiltinOptions_ZerosLikeOptions = 67, |
1127 | BuiltinOptions_FillOptions = 68, |
1128 | BuiltinOptions_BidirectionalSequenceLSTMOptions = 69, |
1129 | BuiltinOptions_BidirectionalSequenceRNNOptions = 70, |
1130 | BuiltinOptions_UnidirectionalSequenceLSTMOptions = 71, |
1131 | BuiltinOptions_FloorModOptions = 72, |
1132 | BuiltinOptions_RangeOptions = 73, |
1133 | BuiltinOptions_ResizeNearestNeighborOptions = 74, |
1134 | BuiltinOptions_LeakyReluOptions = 75, |
1135 | BuiltinOptions_SquaredDifferenceOptions = 76, |
1136 | BuiltinOptions_MirrorPadOptions = 77, |
1137 | BuiltinOptions_AbsOptions = 78, |
1138 | BuiltinOptions_SplitVOptions = 79, |
1139 | BuiltinOptions_UniqueOptions = 80, |
1140 | BuiltinOptions_ReverseV2Options = 81, |
1141 | BuiltinOptions_AddNOptions = 82, |
1142 | BuiltinOptions_GatherNdOptions = 83, |
1143 | BuiltinOptions_CosOptions = 84, |
1144 | BuiltinOptions_WhereOptions = 85, |
1145 | BuiltinOptions_RankOptions = 86, |
1146 | BuiltinOptions_ReverseSequenceOptions = 87, |
1147 | BuiltinOptions_MatrixDiagOptions = 88, |
1148 | BuiltinOptions_QuantizeOptions = 89, |
1149 | BuiltinOptions_MatrixSetDiagOptions = 90, |
1150 | BuiltinOptions_HardSwishOptions = 91, |
1151 | BuiltinOptions_IfOptions = 92, |
1152 | BuiltinOptions_WhileOptions = 93, |
1153 | BuiltinOptions_DepthToSpaceOptions = 94, |
1154 | BuiltinOptions_NonMaxSuppressionV4Options = 95, |
1155 | BuiltinOptions_NonMaxSuppressionV5Options = 96, |
1156 | BuiltinOptions_ScatterNdOptions = 97, |
1157 | BuiltinOptions_SelectV2Options = 98, |
1158 | BuiltinOptions_DensifyOptions = 99, |
1159 | BuiltinOptions_SegmentSumOptions = 100, |
1160 | BuiltinOptions_BatchMatMulOptions = 101, |
1161 | BuiltinOptions_MIN = BuiltinOptions_NONE, |
1162 | BuiltinOptions_MAX = BuiltinOptions_BatchMatMulOptions |
1163 | }; |
1164 | |
1165 | inline const BuiltinOptions (&EnumValuesBuiltinOptions())[102] { |
1166 | static const BuiltinOptions values[] = { |
1167 | BuiltinOptions_NONE, |
1168 | BuiltinOptions_Conv2DOptions, |
1169 | BuiltinOptions_DepthwiseConv2DOptions, |
1170 | BuiltinOptions_ConcatEmbeddingsOptions, |
1171 | BuiltinOptions_LSHProjectionOptions, |
1172 | BuiltinOptions_Pool2DOptions, |
1173 | BuiltinOptions_SVDFOptions, |
1174 | BuiltinOptions_RNNOptions, |
1175 | BuiltinOptions_FullyConnectedOptions, |
1176 | BuiltinOptions_SoftmaxOptions, |
1177 | BuiltinOptions_ConcatenationOptions, |
1178 | BuiltinOptions_AddOptions, |
1179 | BuiltinOptions_L2NormOptions, |
1180 | BuiltinOptions_LocalResponseNormalizationOptions, |
1181 | BuiltinOptions_LSTMOptions, |
1182 | BuiltinOptions_ResizeBilinearOptions, |
1183 | BuiltinOptions_CallOptions, |
1184 | BuiltinOptions_ReshapeOptions, |
1185 | BuiltinOptions_SkipGramOptions, |
1186 | BuiltinOptions_SpaceToDepthOptions, |
1187 | BuiltinOptions_EmbeddingLookupSparseOptions, |
1188 | BuiltinOptions_MulOptions, |
1189 | BuiltinOptions_PadOptions, |
1190 | BuiltinOptions_GatherOptions, |
1191 | BuiltinOptions_BatchToSpaceNDOptions, |
1192 | BuiltinOptions_SpaceToBatchNDOptions, |
1193 | BuiltinOptions_TransposeOptions, |
1194 | BuiltinOptions_ReducerOptions, |
1195 | BuiltinOptions_SubOptions, |
1196 | BuiltinOptions_DivOptions, |
1197 | BuiltinOptions_SqueezeOptions, |
1198 | BuiltinOptions_SequenceRNNOptions, |
1199 | BuiltinOptions_StridedSliceOptions, |
1200 | BuiltinOptions_ExpOptions, |
1201 | BuiltinOptions_TopKV2Options, |
1202 | BuiltinOptions_SplitOptions, |
1203 | BuiltinOptions_LogSoftmaxOptions, |
1204 | BuiltinOptions_CastOptions, |
1205 | BuiltinOptions_DequantizeOptions, |
1206 | BuiltinOptions_MaximumMinimumOptions, |
1207 | BuiltinOptions_ArgMaxOptions, |
1208 | BuiltinOptions_LessOptions, |
1209 | BuiltinOptions_NegOptions, |
1210 | BuiltinOptions_PadV2Options, |
1211 | BuiltinOptions_GreaterOptions, |
1212 | BuiltinOptions_GreaterEqualOptions, |
1213 | BuiltinOptions_LessEqualOptions, |
1214 | BuiltinOptions_SelectOptions, |
1215 | BuiltinOptions_SliceOptions, |
1216 | BuiltinOptions_TransposeConvOptions, |
1217 | BuiltinOptions_SparseToDenseOptions, |
1218 | BuiltinOptions_TileOptions, |
1219 | BuiltinOptions_ExpandDimsOptions, |
1220 | BuiltinOptions_EqualOptions, |
1221 | BuiltinOptions_NotEqualOptions, |
1222 | BuiltinOptions_ShapeOptions, |
1223 | BuiltinOptions_PowOptions, |
1224 | BuiltinOptions_ArgMinOptions, |
1225 | BuiltinOptions_FakeQuantOptions, |
1226 | BuiltinOptions_PackOptions, |
1227 | BuiltinOptions_LogicalOrOptions, |
1228 | BuiltinOptions_OneHotOptions, |
1229 | BuiltinOptions_LogicalAndOptions, |
1230 | BuiltinOptions_LogicalNotOptions, |
1231 | BuiltinOptions_UnpackOptions, |
1232 | BuiltinOptions_FloorDivOptions, |
1233 | BuiltinOptions_SquareOptions, |
1234 | BuiltinOptions_ZerosLikeOptions, |
1235 | BuiltinOptions_FillOptions, |
1236 | BuiltinOptions_BidirectionalSequenceLSTMOptions, |
1237 | BuiltinOptions_BidirectionalSequenceRNNOptions, |
1238 | BuiltinOptions_UnidirectionalSequenceLSTMOptions, |
1239 | BuiltinOptions_FloorModOptions, |
1240 | BuiltinOptions_RangeOptions, |
1241 | BuiltinOptions_ResizeNearestNeighborOptions, |
1242 | BuiltinOptions_LeakyReluOptions, |
1243 | BuiltinOptions_SquaredDifferenceOptions, |
1244 | BuiltinOptions_MirrorPadOptions, |
1245 | BuiltinOptions_AbsOptions, |
1246 | BuiltinOptions_SplitVOptions, |
1247 | BuiltinOptions_UniqueOptions, |
1248 | BuiltinOptions_ReverseV2Options, |
1249 | BuiltinOptions_AddNOptions, |
1250 | BuiltinOptions_GatherNdOptions, |
1251 | BuiltinOptions_CosOptions, |
1252 | BuiltinOptions_WhereOptions, |
1253 | BuiltinOptions_RankOptions, |
1254 | BuiltinOptions_ReverseSequenceOptions, |
1255 | BuiltinOptions_MatrixDiagOptions, |
1256 | BuiltinOptions_QuantizeOptions, |
1257 | BuiltinOptions_MatrixSetDiagOptions, |
1258 | BuiltinOptions_HardSwishOptions, |
1259 | BuiltinOptions_IfOptions, |
1260 | BuiltinOptions_WhileOptions, |
1261 | BuiltinOptions_DepthToSpaceOptions, |
1262 | BuiltinOptions_NonMaxSuppressionV4Options, |
1263 | BuiltinOptions_NonMaxSuppressionV5Options, |
1264 | BuiltinOptions_ScatterNdOptions, |
1265 | BuiltinOptions_SelectV2Options, |
1266 | BuiltinOptions_DensifyOptions, |
1267 | BuiltinOptions_SegmentSumOptions, |
1268 | BuiltinOptions_BatchMatMulOptions |
1269 | }; |
1270 | return values; |
1271 | } |
1272 | |
1273 | inline const char * const *EnumNamesBuiltinOptions() { |
1274 | static const char * const names[103] = { |
1275 | "NONE" , |
1276 | "Conv2DOptions" , |
1277 | "DepthwiseConv2DOptions" , |
1278 | "ConcatEmbeddingsOptions" , |
1279 | "LSHProjectionOptions" , |
1280 | "Pool2DOptions" , |
1281 | "SVDFOptions" , |
1282 | "RNNOptions" , |
1283 | "FullyConnectedOptions" , |
1284 | "SoftmaxOptions" , |
1285 | "ConcatenationOptions" , |
1286 | "AddOptions" , |
1287 | "L2NormOptions" , |
1288 | "LocalResponseNormalizationOptions" , |
1289 | "LSTMOptions" , |
1290 | "ResizeBilinearOptions" , |
1291 | "CallOptions" , |
1292 | "ReshapeOptions" , |
1293 | "SkipGramOptions" , |
1294 | "SpaceToDepthOptions" , |
1295 | "EmbeddingLookupSparseOptions" , |
1296 | "MulOptions" , |
1297 | "PadOptions" , |
1298 | "GatherOptions" , |
1299 | "BatchToSpaceNDOptions" , |
1300 | "SpaceToBatchNDOptions" , |
1301 | "TransposeOptions" , |
1302 | "ReducerOptions" , |
1303 | "SubOptions" , |
1304 | "DivOptions" , |
1305 | "SqueezeOptions" , |
1306 | "SequenceRNNOptions" , |
1307 | "StridedSliceOptions" , |
1308 | "ExpOptions" , |
1309 | "TopKV2Options" , |
1310 | "SplitOptions" , |
1311 | "LogSoftmaxOptions" , |
1312 | "CastOptions" , |
1313 | "DequantizeOptions" , |
1314 | "MaximumMinimumOptions" , |
1315 | "ArgMaxOptions" , |
1316 | "LessOptions" , |
1317 | "NegOptions" , |
1318 | "PadV2Options" , |
1319 | "GreaterOptions" , |
1320 | "GreaterEqualOptions" , |
1321 | "LessEqualOptions" , |
1322 | "SelectOptions" , |
1323 | "SliceOptions" , |
1324 | "TransposeConvOptions" , |
1325 | "SparseToDenseOptions" , |
1326 | "TileOptions" , |
1327 | "ExpandDimsOptions" , |
1328 | "EqualOptions" , |
1329 | "NotEqualOptions" , |
1330 | "ShapeOptions" , |
1331 | "PowOptions" , |
1332 | "ArgMinOptions" , |
1333 | "FakeQuantOptions" , |
1334 | "PackOptions" , |
1335 | "LogicalOrOptions" , |
1336 | "OneHotOptions" , |
1337 | "LogicalAndOptions" , |
1338 | "LogicalNotOptions" , |
1339 | "UnpackOptions" , |
1340 | "FloorDivOptions" , |
1341 | "SquareOptions" , |
1342 | "ZerosLikeOptions" , |
1343 | "FillOptions" , |
1344 | "BidirectionalSequenceLSTMOptions" , |
1345 | "BidirectionalSequenceRNNOptions" , |
1346 | "UnidirectionalSequenceLSTMOptions" , |
1347 | "FloorModOptions" , |
1348 | "RangeOptions" , |
1349 | "ResizeNearestNeighborOptions" , |
1350 | "LeakyReluOptions" , |
1351 | "SquaredDifferenceOptions" , |
1352 | "MirrorPadOptions" , |
1353 | "AbsOptions" , |
1354 | "SplitVOptions" , |
1355 | "UniqueOptions" , |
1356 | "ReverseV2Options" , |
1357 | "AddNOptions" , |
1358 | "GatherNdOptions" , |
1359 | "CosOptions" , |
1360 | "WhereOptions" , |
1361 | "RankOptions" , |
1362 | "ReverseSequenceOptions" , |
1363 | "MatrixDiagOptions" , |
1364 | "QuantizeOptions" , |
1365 | "MatrixSetDiagOptions" , |
1366 | "HardSwishOptions" , |
1367 | "IfOptions" , |
1368 | "WhileOptions" , |
1369 | "DepthToSpaceOptions" , |
1370 | "NonMaxSuppressionV4Options" , |
1371 | "NonMaxSuppressionV5Options" , |
1372 | "ScatterNdOptions" , |
1373 | "SelectV2Options" , |
1374 | "DensifyOptions" , |
1375 | "SegmentSumOptions" , |
1376 | "BatchMatMulOptions" , |
1377 | nullptr |
1378 | }; |
1379 | return names; |
1380 | } |
1381 | |
1382 | inline const char *EnumNameBuiltinOptions(BuiltinOptions e) { |
1383 | if (flatbuffers::IsOutRange(e, BuiltinOptions_NONE, BuiltinOptions_BatchMatMulOptions)) return "" ; |
1384 | const size_t index = static_cast<size_t>(e); |
1385 | return EnumNamesBuiltinOptions()[index]; |
1386 | } |
1387 | |
1388 | template<typename T> struct BuiltinOptionsTraits { |
1389 | static const BuiltinOptions enum_value = BuiltinOptions_NONE; |
1390 | }; |
1391 | |
1392 | template<> struct BuiltinOptionsTraits<tflite::Conv2DOptions> { |
1393 | static const BuiltinOptions enum_value = BuiltinOptions_Conv2DOptions; |
1394 | }; |
1395 | |
1396 | template<> struct BuiltinOptionsTraits<tflite::DepthwiseConv2DOptions> { |
1397 | static const BuiltinOptions enum_value = BuiltinOptions_DepthwiseConv2DOptions; |
1398 | }; |
1399 | |
1400 | template<> struct BuiltinOptionsTraits<tflite::ConcatEmbeddingsOptions> { |
1401 | static const BuiltinOptions enum_value = BuiltinOptions_ConcatEmbeddingsOptions; |
1402 | }; |
1403 | |
1404 | template<> struct BuiltinOptionsTraits<tflite::LSHProjectionOptions> { |
1405 | static const BuiltinOptions enum_value = BuiltinOptions_LSHProjectionOptions; |
1406 | }; |
1407 | |
1408 | template<> struct BuiltinOptionsTraits<tflite::Pool2DOptions> { |
1409 | static const BuiltinOptions enum_value = BuiltinOptions_Pool2DOptions; |
1410 | }; |
1411 | |
1412 | template<> struct BuiltinOptionsTraits<tflite::SVDFOptions> { |
1413 | static const BuiltinOptions enum_value = BuiltinOptions_SVDFOptions; |
1414 | }; |
1415 | |
1416 | template<> struct BuiltinOptionsTraits<tflite::RNNOptions> { |
1417 | static const BuiltinOptions enum_value = BuiltinOptions_RNNOptions; |
1418 | }; |
1419 | |
1420 | template<> struct BuiltinOptionsTraits<tflite::FullyConnectedOptions> { |
1421 | static const BuiltinOptions enum_value = BuiltinOptions_FullyConnectedOptions; |
1422 | }; |
1423 | |
1424 | template<> struct BuiltinOptionsTraits<tflite::SoftmaxOptions> { |
1425 | static const BuiltinOptions enum_value = BuiltinOptions_SoftmaxOptions; |
1426 | }; |
1427 | |
1428 | template<> struct BuiltinOptionsTraits<tflite::ConcatenationOptions> { |
1429 | static const BuiltinOptions enum_value = BuiltinOptions_ConcatenationOptions; |
1430 | }; |
1431 | |
1432 | template<> struct BuiltinOptionsTraits<tflite::AddOptions> { |
1433 | static const BuiltinOptions enum_value = BuiltinOptions_AddOptions; |
1434 | }; |
1435 | |
1436 | template<> struct BuiltinOptionsTraits<tflite::L2NormOptions> { |
1437 | static const BuiltinOptions enum_value = BuiltinOptions_L2NormOptions; |
1438 | }; |
1439 | |
1440 | template<> struct BuiltinOptionsTraits<tflite::LocalResponseNormalizationOptions> { |
1441 | static const BuiltinOptions enum_value = BuiltinOptions_LocalResponseNormalizationOptions; |
1442 | }; |
1443 | |
1444 | template<> struct BuiltinOptionsTraits<tflite::LSTMOptions> { |
1445 | static const BuiltinOptions enum_value = BuiltinOptions_LSTMOptions; |
1446 | }; |
1447 | |
1448 | template<> struct BuiltinOptionsTraits<tflite::ResizeBilinearOptions> { |
1449 | static const BuiltinOptions enum_value = BuiltinOptions_ResizeBilinearOptions; |
1450 | }; |
1451 | |
1452 | template<> struct BuiltinOptionsTraits<tflite::CallOptions> { |
1453 | static const BuiltinOptions enum_value = BuiltinOptions_CallOptions; |
1454 | }; |
1455 | |
1456 | template<> struct BuiltinOptionsTraits<tflite::ReshapeOptions> { |
1457 | static const BuiltinOptions enum_value = BuiltinOptions_ReshapeOptions; |
1458 | }; |
1459 | |
1460 | template<> struct BuiltinOptionsTraits<tflite::SkipGramOptions> { |
1461 | static const BuiltinOptions enum_value = BuiltinOptions_SkipGramOptions; |
1462 | }; |
1463 | |
1464 | template<> struct BuiltinOptionsTraits<tflite::SpaceToDepthOptions> { |
1465 | static const BuiltinOptions enum_value = BuiltinOptions_SpaceToDepthOptions; |
1466 | }; |
1467 | |
1468 | template<> struct BuiltinOptionsTraits<tflite::EmbeddingLookupSparseOptions> { |
1469 | static const BuiltinOptions enum_value = BuiltinOptions_EmbeddingLookupSparseOptions; |
1470 | }; |
1471 | |
1472 | template<> struct BuiltinOptionsTraits<tflite::MulOptions> { |
1473 | static const BuiltinOptions enum_value = BuiltinOptions_MulOptions; |
1474 | }; |
1475 | |
1476 | template<> struct BuiltinOptionsTraits<tflite::PadOptions> { |
1477 | static const BuiltinOptions enum_value = BuiltinOptions_PadOptions; |
1478 | }; |
1479 | |
1480 | template<> struct BuiltinOptionsTraits<tflite::GatherOptions> { |
1481 | static const BuiltinOptions enum_value = BuiltinOptions_GatherOptions; |
1482 | }; |
1483 | |
1484 | template<> struct BuiltinOptionsTraits<tflite::BatchToSpaceNDOptions> { |
1485 | static const BuiltinOptions enum_value = BuiltinOptions_BatchToSpaceNDOptions; |
1486 | }; |
1487 | |
1488 | template<> struct BuiltinOptionsTraits<tflite::SpaceToBatchNDOptions> { |
1489 | static const BuiltinOptions enum_value = BuiltinOptions_SpaceToBatchNDOptions; |
1490 | }; |
1491 | |
1492 | template<> struct BuiltinOptionsTraits<tflite::TransposeOptions> { |
1493 | static const BuiltinOptions enum_value = BuiltinOptions_TransposeOptions; |
1494 | }; |
1495 | |
1496 | template<> struct BuiltinOptionsTraits<tflite::ReducerOptions> { |
1497 | static const BuiltinOptions enum_value = BuiltinOptions_ReducerOptions; |
1498 | }; |
1499 | |
1500 | template<> struct BuiltinOptionsTraits<tflite::SubOptions> { |
1501 | static const BuiltinOptions enum_value = BuiltinOptions_SubOptions; |
1502 | }; |
1503 | |
1504 | template<> struct BuiltinOptionsTraits<tflite::DivOptions> { |
1505 | static const BuiltinOptions enum_value = BuiltinOptions_DivOptions; |
1506 | }; |
1507 | |
1508 | template<> struct BuiltinOptionsTraits<tflite::SqueezeOptions> { |
1509 | static const BuiltinOptions enum_value = BuiltinOptions_SqueezeOptions; |
1510 | }; |
1511 | |
1512 | template<> struct BuiltinOptionsTraits<tflite::SequenceRNNOptions> { |
1513 | static const BuiltinOptions enum_value = BuiltinOptions_SequenceRNNOptions; |
1514 | }; |
1515 | |
1516 | template<> struct BuiltinOptionsTraits<tflite::StridedSliceOptions> { |
1517 | static const BuiltinOptions enum_value = BuiltinOptions_StridedSliceOptions; |
1518 | }; |
1519 | |
1520 | template<> struct BuiltinOptionsTraits<tflite::ExpOptions> { |
1521 | static const BuiltinOptions enum_value = BuiltinOptions_ExpOptions; |
1522 | }; |
1523 | |
1524 | template<> struct BuiltinOptionsTraits<tflite::TopKV2Options> { |
1525 | static const BuiltinOptions enum_value = BuiltinOptions_TopKV2Options; |
1526 | }; |
1527 | |
1528 | template<> struct BuiltinOptionsTraits<tflite::SplitOptions> { |
1529 | static const BuiltinOptions enum_value = BuiltinOptions_SplitOptions; |
1530 | }; |
1531 | |
1532 | template<> struct BuiltinOptionsTraits<tflite::LogSoftmaxOptions> { |
1533 | static const BuiltinOptions enum_value = BuiltinOptions_LogSoftmaxOptions; |
1534 | }; |
1535 | |
1536 | template<> struct BuiltinOptionsTraits<tflite::CastOptions> { |
1537 | static const BuiltinOptions enum_value = BuiltinOptions_CastOptions; |
1538 | }; |
1539 | |
1540 | template<> struct BuiltinOptionsTraits<tflite::DequantizeOptions> { |
1541 | static const BuiltinOptions enum_value = BuiltinOptions_DequantizeOptions; |
1542 | }; |
1543 | |
1544 | template<> struct BuiltinOptionsTraits<tflite::MaximumMinimumOptions> { |
1545 | static const BuiltinOptions enum_value = BuiltinOptions_MaximumMinimumOptions; |
1546 | }; |
1547 | |
1548 | template<> struct BuiltinOptionsTraits<tflite::ArgMaxOptions> { |
1549 | static const BuiltinOptions enum_value = BuiltinOptions_ArgMaxOptions; |
1550 | }; |
1551 | |
1552 | template<> struct BuiltinOptionsTraits<tflite::LessOptions> { |
1553 | static const BuiltinOptions enum_value = BuiltinOptions_LessOptions; |
1554 | }; |
1555 | |
1556 | template<> struct BuiltinOptionsTraits<tflite::NegOptions> { |
1557 | static const BuiltinOptions enum_value = BuiltinOptions_NegOptions; |
1558 | }; |
1559 | |
1560 | template<> struct BuiltinOptionsTraits<tflite::PadV2Options> { |
1561 | static const BuiltinOptions enum_value = BuiltinOptions_PadV2Options; |
1562 | }; |
1563 | |
1564 | template<> struct BuiltinOptionsTraits<tflite::GreaterOptions> { |
1565 | static const BuiltinOptions enum_value = BuiltinOptions_GreaterOptions; |
1566 | }; |
1567 | |
1568 | template<> struct BuiltinOptionsTraits<tflite::GreaterEqualOptions> { |
1569 | static const BuiltinOptions enum_value = BuiltinOptions_GreaterEqualOptions; |
1570 | }; |
1571 | |
1572 | template<> struct BuiltinOptionsTraits<tflite::LessEqualOptions> { |
1573 | static const BuiltinOptions enum_value = BuiltinOptions_LessEqualOptions; |
1574 | }; |
1575 | |
1576 | template<> struct BuiltinOptionsTraits<tflite::SelectOptions> { |
1577 | static const BuiltinOptions enum_value = BuiltinOptions_SelectOptions; |
1578 | }; |
1579 | |
1580 | template<> struct BuiltinOptionsTraits<tflite::SliceOptions> { |
1581 | static const BuiltinOptions enum_value = BuiltinOptions_SliceOptions; |
1582 | }; |
1583 | |
1584 | template<> struct BuiltinOptionsTraits<tflite::TransposeConvOptions> { |
1585 | static const BuiltinOptions enum_value = BuiltinOptions_TransposeConvOptions; |
1586 | }; |
1587 | |
1588 | template<> struct BuiltinOptionsTraits<tflite::SparseToDenseOptions> { |
1589 | static const BuiltinOptions enum_value = BuiltinOptions_SparseToDenseOptions; |
1590 | }; |
1591 | |
1592 | template<> struct BuiltinOptionsTraits<tflite::TileOptions> { |
1593 | static const BuiltinOptions enum_value = BuiltinOptions_TileOptions; |
1594 | }; |
1595 | |
1596 | template<> struct BuiltinOptionsTraits<tflite::ExpandDimsOptions> { |
1597 | static const BuiltinOptions enum_value = BuiltinOptions_ExpandDimsOptions; |
1598 | }; |
1599 | |
1600 | template<> struct BuiltinOptionsTraits<tflite::EqualOptions> { |
1601 | static const BuiltinOptions enum_value = BuiltinOptions_EqualOptions; |
1602 | }; |
1603 | |
1604 | template<> struct BuiltinOptionsTraits<tflite::NotEqualOptions> { |
1605 | static const BuiltinOptions enum_value = BuiltinOptions_NotEqualOptions; |
1606 | }; |
1607 | |
1608 | template<> struct BuiltinOptionsTraits<tflite::ShapeOptions> { |
1609 | static const BuiltinOptions enum_value = BuiltinOptions_ShapeOptions; |
1610 | }; |
1611 | |
1612 | template<> struct BuiltinOptionsTraits<tflite::PowOptions> { |
1613 | static const BuiltinOptions enum_value = BuiltinOptions_PowOptions; |
1614 | }; |
1615 | |
1616 | template<> struct BuiltinOptionsTraits<tflite::ArgMinOptions> { |
1617 | static const BuiltinOptions enum_value = BuiltinOptions_ArgMinOptions; |
1618 | }; |
1619 | |
1620 | template<> struct BuiltinOptionsTraits<tflite::FakeQuantOptions> { |
1621 | static const BuiltinOptions enum_value = BuiltinOptions_FakeQuantOptions; |
1622 | }; |
1623 | |
1624 | template<> struct BuiltinOptionsTraits<tflite::PackOptions> { |
1625 | static const BuiltinOptions enum_value = BuiltinOptions_PackOptions; |
1626 | }; |
1627 | |
1628 | template<> struct BuiltinOptionsTraits<tflite::LogicalOrOptions> { |
1629 | static const BuiltinOptions enum_value = BuiltinOptions_LogicalOrOptions; |
1630 | }; |
1631 | |
1632 | template<> struct BuiltinOptionsTraits<tflite::OneHotOptions> { |
1633 | static const BuiltinOptions enum_value = BuiltinOptions_OneHotOptions; |
1634 | }; |
1635 | |
1636 | template<> struct BuiltinOptionsTraits<tflite::LogicalAndOptions> { |
1637 | static const BuiltinOptions enum_value = BuiltinOptions_LogicalAndOptions; |
1638 | }; |
1639 | |
1640 | template<> struct BuiltinOptionsTraits<tflite::LogicalNotOptions> { |
1641 | static const BuiltinOptions enum_value = BuiltinOptions_LogicalNotOptions; |
1642 | }; |
1643 | |
1644 | template<> struct BuiltinOptionsTraits<tflite::UnpackOptions> { |
1645 | static const BuiltinOptions enum_value = BuiltinOptions_UnpackOptions; |
1646 | }; |
1647 | |
1648 | template<> struct BuiltinOptionsTraits<tflite::FloorDivOptions> { |
1649 | static const BuiltinOptions enum_value = BuiltinOptions_FloorDivOptions; |
1650 | }; |
1651 | |
1652 | template<> struct BuiltinOptionsTraits<tflite::SquareOptions> { |
1653 | static const BuiltinOptions enum_value = BuiltinOptions_SquareOptions; |
1654 | }; |
1655 | |
1656 | template<> struct BuiltinOptionsTraits<tflite::ZerosLikeOptions> { |
1657 | static const BuiltinOptions enum_value = BuiltinOptions_ZerosLikeOptions; |
1658 | }; |
1659 | |
1660 | template<> struct BuiltinOptionsTraits<tflite::FillOptions> { |
1661 | static const BuiltinOptions enum_value = BuiltinOptions_FillOptions; |
1662 | }; |
1663 | |
1664 | template<> struct BuiltinOptionsTraits<tflite::BidirectionalSequenceLSTMOptions> { |
1665 | static const BuiltinOptions enum_value = BuiltinOptions_BidirectionalSequenceLSTMOptions; |
1666 | }; |
1667 | |
1668 | template<> struct BuiltinOptionsTraits<tflite::BidirectionalSequenceRNNOptions> { |
1669 | static const BuiltinOptions enum_value = BuiltinOptions_BidirectionalSequenceRNNOptions; |
1670 | }; |
1671 | |
1672 | template<> struct BuiltinOptionsTraits<tflite::UnidirectionalSequenceLSTMOptions> { |
1673 | static const BuiltinOptions enum_value = BuiltinOptions_UnidirectionalSequenceLSTMOptions; |
1674 | }; |
1675 | |
1676 | template<> struct BuiltinOptionsTraits<tflite::FloorModOptions> { |
1677 | static const BuiltinOptions enum_value = BuiltinOptions_FloorModOptions; |
1678 | }; |
1679 | |
1680 | template<> struct BuiltinOptionsTraits<tflite::RangeOptions> { |
1681 | static const BuiltinOptions enum_value = BuiltinOptions_RangeOptions; |
1682 | }; |
1683 | |
1684 | template<> struct BuiltinOptionsTraits<tflite::ResizeNearestNeighborOptions> { |
1685 | static const BuiltinOptions enum_value = BuiltinOptions_ResizeNearestNeighborOptions; |
1686 | }; |
1687 | |
1688 | template<> struct BuiltinOptionsTraits<tflite::LeakyReluOptions> { |
1689 | static const BuiltinOptions enum_value = BuiltinOptions_LeakyReluOptions; |
1690 | }; |
1691 | |
1692 | template<> struct BuiltinOptionsTraits<tflite::SquaredDifferenceOptions> { |
1693 | static const BuiltinOptions enum_value = BuiltinOptions_SquaredDifferenceOptions; |
1694 | }; |
1695 | |
1696 | template<> struct BuiltinOptionsTraits<tflite::MirrorPadOptions> { |
1697 | static const BuiltinOptions enum_value = BuiltinOptions_MirrorPadOptions; |
1698 | }; |
1699 | |
1700 | template<> struct BuiltinOptionsTraits<tflite::AbsOptions> { |
1701 | static const BuiltinOptions enum_value = BuiltinOptions_AbsOptions; |
1702 | }; |
1703 | |
1704 | template<> struct BuiltinOptionsTraits<tflite::SplitVOptions> { |
1705 | static const BuiltinOptions enum_value = BuiltinOptions_SplitVOptions; |
1706 | }; |
1707 | |
1708 | template<> struct BuiltinOptionsTraits<tflite::UniqueOptions> { |
1709 | static const BuiltinOptions enum_value = BuiltinOptions_UniqueOptions; |
1710 | }; |
1711 | |
1712 | template<> struct BuiltinOptionsTraits<tflite::ReverseV2Options> { |
1713 | static const BuiltinOptions enum_value = BuiltinOptions_ReverseV2Options; |
1714 | }; |
1715 | |
1716 | template<> struct BuiltinOptionsTraits<tflite::AddNOptions> { |
1717 | static const BuiltinOptions enum_value = BuiltinOptions_AddNOptions; |
1718 | }; |
1719 | |
1720 | template<> struct BuiltinOptionsTraits<tflite::GatherNdOptions> { |
1721 | static const BuiltinOptions enum_value = BuiltinOptions_GatherNdOptions; |
1722 | }; |
1723 | |
1724 | template<> struct BuiltinOptionsTraits<tflite::CosOptions> { |
1725 | static const BuiltinOptions enum_value = BuiltinOptions_CosOptions; |
1726 | }; |
1727 | |
1728 | template<> struct BuiltinOptionsTraits<tflite::WhereOptions> { |
1729 | static const BuiltinOptions enum_value = BuiltinOptions_WhereOptions; |
1730 | }; |
1731 | |
1732 | template<> struct BuiltinOptionsTraits<tflite::RankOptions> { |
1733 | static const BuiltinOptions enum_value = BuiltinOptions_RankOptions; |
1734 | }; |
1735 | |
1736 | template<> struct BuiltinOptionsTraits<tflite::ReverseSequenceOptions> { |
1737 | static const BuiltinOptions enum_value = BuiltinOptions_ReverseSequenceOptions; |
1738 | }; |
1739 | |
1740 | template<> struct BuiltinOptionsTraits<tflite::MatrixDiagOptions> { |
1741 | static const BuiltinOptions enum_value = BuiltinOptions_MatrixDiagOptions; |
1742 | }; |
1743 | |
1744 | template<> struct BuiltinOptionsTraits<tflite::QuantizeOptions> { |
1745 | static const BuiltinOptions enum_value = BuiltinOptions_QuantizeOptions; |
1746 | }; |
1747 | |
1748 | template<> struct BuiltinOptionsTraits<tflite::MatrixSetDiagOptions> { |
1749 | static const BuiltinOptions enum_value = BuiltinOptions_MatrixSetDiagOptions; |
1750 | }; |
1751 | |
1752 | template<> struct BuiltinOptionsTraits<tflite::HardSwishOptions> { |
1753 | static const BuiltinOptions enum_value = BuiltinOptions_HardSwishOptions; |
1754 | }; |
1755 | |
1756 | template<> struct BuiltinOptionsTraits<tflite::IfOptions> { |
1757 | static const BuiltinOptions enum_value = BuiltinOptions_IfOptions; |
1758 | }; |
1759 | |
1760 | template<> struct BuiltinOptionsTraits<tflite::WhileOptions> { |
1761 | static const BuiltinOptions enum_value = BuiltinOptions_WhileOptions; |
1762 | }; |
1763 | |
1764 | template<> struct BuiltinOptionsTraits<tflite::DepthToSpaceOptions> { |
1765 | static const BuiltinOptions enum_value = BuiltinOptions_DepthToSpaceOptions; |
1766 | }; |
1767 | |
1768 | template<> struct BuiltinOptionsTraits<tflite::NonMaxSuppressionV4Options> { |
1769 | static const BuiltinOptions enum_value = BuiltinOptions_NonMaxSuppressionV4Options; |
1770 | }; |
1771 | |
1772 | template<> struct BuiltinOptionsTraits<tflite::NonMaxSuppressionV5Options> { |
1773 | static const BuiltinOptions enum_value = BuiltinOptions_NonMaxSuppressionV5Options; |
1774 | }; |
1775 | |
1776 | template<> struct BuiltinOptionsTraits<tflite::ScatterNdOptions> { |
1777 | static const BuiltinOptions enum_value = BuiltinOptions_ScatterNdOptions; |
1778 | }; |
1779 | |
1780 | template<> struct BuiltinOptionsTraits<tflite::SelectV2Options> { |
1781 | static const BuiltinOptions enum_value = BuiltinOptions_SelectV2Options; |
1782 | }; |
1783 | |
1784 | template<> struct BuiltinOptionsTraits<tflite::DensifyOptions> { |
1785 | static const BuiltinOptions enum_value = BuiltinOptions_DensifyOptions; |
1786 | }; |
1787 | |
1788 | template<> struct BuiltinOptionsTraits<tflite::SegmentSumOptions> { |
1789 | static const BuiltinOptions enum_value = BuiltinOptions_SegmentSumOptions; |
1790 | }; |
1791 | |
1792 | template<> struct BuiltinOptionsTraits<tflite::BatchMatMulOptions> { |
1793 | static const BuiltinOptions enum_value = BuiltinOptions_BatchMatMulOptions; |
1794 | }; |
1795 | |
1796 | struct BuiltinOptionsUnion { |
1797 | BuiltinOptions type; |
1798 | void *value; |
1799 | |
1800 | BuiltinOptionsUnion() : type(BuiltinOptions_NONE), value(nullptr) {} |
1801 | BuiltinOptionsUnion(BuiltinOptionsUnion&& u) FLATBUFFERS_NOEXCEPT : |
1802 | type(BuiltinOptions_NONE), value(nullptr) |
1803 | { std::swap(type, u.type); std::swap(value, u.value); } |
1804 | BuiltinOptionsUnion(const BuiltinOptionsUnion &) FLATBUFFERS_NOEXCEPT; |
1805 | BuiltinOptionsUnion &operator=(const BuiltinOptionsUnion &u) FLATBUFFERS_NOEXCEPT |
1806 | { BuiltinOptionsUnion t(u); std::swap(type, t.type); std::swap(value, t.value); return *this; } |
1807 | BuiltinOptionsUnion &operator=(BuiltinOptionsUnion &&u) FLATBUFFERS_NOEXCEPT |
1808 | { std::swap(type, u.type); std::swap(value, u.value); return *this; } |
1809 | ~BuiltinOptionsUnion() { Reset(); } |
1810 | |
1811 | void Reset(); |
1812 | |
1813 | #ifndef FLATBUFFERS_CPP98_STL |
1814 | template <typename T> |
1815 | void Set(T&& val) { |
1816 | using RT = typename std::remove_reference<T>::type; |
1817 | Reset(); |
1818 | type = BuiltinOptionsTraits<typename RT::TableType>::enum_value; |
1819 | if (type != BuiltinOptions_NONE) { |
1820 | value = new RT(std::forward<T>(val)); |
1821 | } |
1822 | } |
1823 | #endif // FLATBUFFERS_CPP98_STL |
1824 | |
1825 | static void *UnPack(const void *obj, BuiltinOptions type, const flatbuffers::resolver_function_t *resolver); |
1826 | flatbuffers::Offset<void> Pack(flatbuffers::FlatBufferBuilder &_fbb, const flatbuffers::rehasher_function_t *_rehasher = nullptr) const; |
1827 | |
1828 | tflite::Conv2DOptionsT *AsConv2DOptions() { |
1829 | return type == BuiltinOptions_Conv2DOptions ? |
1830 | reinterpret_cast<tflite::Conv2DOptionsT *>(value) : nullptr; |
1831 | } |
1832 | const tflite::Conv2DOptionsT *AsConv2DOptions() const { |
1833 | return type == BuiltinOptions_Conv2DOptions ? |
1834 | reinterpret_cast<const tflite::Conv2DOptionsT *>(value) : nullptr; |
1835 | } |
1836 | tflite::DepthwiseConv2DOptionsT *AsDepthwiseConv2DOptions() { |
1837 | return type == BuiltinOptions_DepthwiseConv2DOptions ? |
1838 | reinterpret_cast<tflite::DepthwiseConv2DOptionsT *>(value) : nullptr; |
1839 | } |
1840 | const tflite::DepthwiseConv2DOptionsT *AsDepthwiseConv2DOptions() const { |
1841 | return type == BuiltinOptions_DepthwiseConv2DOptions ? |
1842 | reinterpret_cast<const tflite::DepthwiseConv2DOptionsT *>(value) : nullptr; |
1843 | } |
1844 | tflite::ConcatEmbeddingsOptionsT *AsConcatEmbeddingsOptions() { |
1845 | return type == BuiltinOptions_ConcatEmbeddingsOptions ? |
1846 | reinterpret_cast<tflite::ConcatEmbeddingsOptionsT *>(value) : nullptr; |
1847 | } |
1848 | const tflite::ConcatEmbeddingsOptionsT *AsConcatEmbeddingsOptions() const { |
1849 | return type == BuiltinOptions_ConcatEmbeddingsOptions ? |
1850 | reinterpret_cast<const tflite::ConcatEmbeddingsOptionsT *>(value) : nullptr; |
1851 | } |
1852 | tflite::LSHProjectionOptionsT *AsLSHProjectionOptions() { |
1853 | return type == BuiltinOptions_LSHProjectionOptions ? |
1854 | reinterpret_cast<tflite::LSHProjectionOptionsT *>(value) : nullptr; |
1855 | } |
1856 | const tflite::LSHProjectionOptionsT *AsLSHProjectionOptions() const { |
1857 | return type == BuiltinOptions_LSHProjectionOptions ? |
1858 | reinterpret_cast<const tflite::LSHProjectionOptionsT *>(value) : nullptr; |
1859 | } |
1860 | tflite::Pool2DOptionsT *AsPool2DOptions() { |
1861 | return type == BuiltinOptions_Pool2DOptions ? |
1862 | reinterpret_cast<tflite::Pool2DOptionsT *>(value) : nullptr; |
1863 | } |
1864 | const tflite::Pool2DOptionsT *AsPool2DOptions() const { |
1865 | return type == BuiltinOptions_Pool2DOptions ? |
1866 | reinterpret_cast<const tflite::Pool2DOptionsT *>(value) : nullptr; |
1867 | } |
1868 | tflite::SVDFOptionsT *AsSVDFOptions() { |
1869 | return type == BuiltinOptions_SVDFOptions ? |
1870 | reinterpret_cast<tflite::SVDFOptionsT *>(value) : nullptr; |
1871 | } |
1872 | const tflite::SVDFOptionsT *AsSVDFOptions() const { |
1873 | return type == BuiltinOptions_SVDFOptions ? |
1874 | reinterpret_cast<const tflite::SVDFOptionsT *>(value) : nullptr; |
1875 | } |
1876 | tflite::RNNOptionsT *AsRNNOptions() { |
1877 | return type == BuiltinOptions_RNNOptions ? |
1878 | reinterpret_cast<tflite::RNNOptionsT *>(value) : nullptr; |
1879 | } |
1880 | const tflite::RNNOptionsT *AsRNNOptions() const { |
1881 | return type == BuiltinOptions_RNNOptions ? |
1882 | reinterpret_cast<const tflite::RNNOptionsT *>(value) : nullptr; |
1883 | } |
1884 | tflite::FullyConnectedOptionsT *AsFullyConnectedOptions() { |
1885 | return type == BuiltinOptions_FullyConnectedOptions ? |
1886 | reinterpret_cast<tflite::FullyConnectedOptionsT *>(value) : nullptr; |
1887 | } |
1888 | const tflite::FullyConnectedOptionsT *AsFullyConnectedOptions() const { |
1889 | return type == BuiltinOptions_FullyConnectedOptions ? |
1890 | reinterpret_cast<const tflite::FullyConnectedOptionsT *>(value) : nullptr; |
1891 | } |
1892 | tflite::SoftmaxOptionsT *AsSoftmaxOptions() { |
1893 | return type == BuiltinOptions_SoftmaxOptions ? |
1894 | reinterpret_cast<tflite::SoftmaxOptionsT *>(value) : nullptr; |
1895 | } |
1896 | const tflite::SoftmaxOptionsT *AsSoftmaxOptions() const { |
1897 | return type == BuiltinOptions_SoftmaxOptions ? |
1898 | reinterpret_cast<const tflite::SoftmaxOptionsT *>(value) : nullptr; |
1899 | } |
1900 | tflite::ConcatenationOptionsT *AsConcatenationOptions() { |
1901 | return type == BuiltinOptions_ConcatenationOptions ? |
1902 | reinterpret_cast<tflite::ConcatenationOptionsT *>(value) : nullptr; |
1903 | } |
1904 | const tflite::ConcatenationOptionsT *AsConcatenationOptions() const { |
1905 | return type == BuiltinOptions_ConcatenationOptions ? |
1906 | reinterpret_cast<const tflite::ConcatenationOptionsT *>(value) : nullptr; |
1907 | } |
1908 | tflite::AddOptionsT *AsAddOptions() { |
1909 | return type == BuiltinOptions_AddOptions ? |
1910 | reinterpret_cast<tflite::AddOptionsT *>(value) : nullptr; |
1911 | } |
1912 | const tflite::AddOptionsT *AsAddOptions() const { |
1913 | return type == BuiltinOptions_AddOptions ? |
1914 | reinterpret_cast<const tflite::AddOptionsT *>(value) : nullptr; |
1915 | } |
1916 | tflite::L2NormOptionsT *AsL2NormOptions() { |
1917 | return type == BuiltinOptions_L2NormOptions ? |
1918 | reinterpret_cast<tflite::L2NormOptionsT *>(value) : nullptr; |
1919 | } |
1920 | const tflite::L2NormOptionsT *AsL2NormOptions() const { |
1921 | return type == BuiltinOptions_L2NormOptions ? |
1922 | reinterpret_cast<const tflite::L2NormOptionsT *>(value) : nullptr; |
1923 | } |
1924 | tflite::LocalResponseNormalizationOptionsT *AsLocalResponseNormalizationOptions() { |
1925 | return type == BuiltinOptions_LocalResponseNormalizationOptions ? |
1926 | reinterpret_cast<tflite::LocalResponseNormalizationOptionsT *>(value) : nullptr; |
1927 | } |
1928 | const tflite::LocalResponseNormalizationOptionsT *AsLocalResponseNormalizationOptions() const { |
1929 | return type == BuiltinOptions_LocalResponseNormalizationOptions ? |
1930 | reinterpret_cast<const tflite::LocalResponseNormalizationOptionsT *>(value) : nullptr; |
1931 | } |
1932 | tflite::LSTMOptionsT *AsLSTMOptions() { |
1933 | return type == BuiltinOptions_LSTMOptions ? |
1934 | reinterpret_cast<tflite::LSTMOptionsT *>(value) : nullptr; |
1935 | } |
1936 | const tflite::LSTMOptionsT *AsLSTMOptions() const { |
1937 | return type == BuiltinOptions_LSTMOptions ? |
1938 | reinterpret_cast<const tflite::LSTMOptionsT *>(value) : nullptr; |
1939 | } |
1940 | tflite::ResizeBilinearOptionsT *AsResizeBilinearOptions() { |
1941 | return type == BuiltinOptions_ResizeBilinearOptions ? |
1942 | reinterpret_cast<tflite::ResizeBilinearOptionsT *>(value) : nullptr; |
1943 | } |
1944 | const tflite::ResizeBilinearOptionsT *AsResizeBilinearOptions() const { |
1945 | return type == BuiltinOptions_ResizeBilinearOptions ? |
1946 | reinterpret_cast<const tflite::ResizeBilinearOptionsT *>(value) : nullptr; |
1947 | } |
1948 | tflite::CallOptionsT *AsCallOptions() { |
1949 | return type == BuiltinOptions_CallOptions ? |
1950 | reinterpret_cast<tflite::CallOptionsT *>(value) : nullptr; |
1951 | } |
1952 | const tflite::CallOptionsT *AsCallOptions() const { |
1953 | return type == BuiltinOptions_CallOptions ? |
1954 | reinterpret_cast<const tflite::CallOptionsT *>(value) : nullptr; |
1955 | } |
1956 | tflite::ReshapeOptionsT *AsReshapeOptions() { |
1957 | return type == BuiltinOptions_ReshapeOptions ? |
1958 | reinterpret_cast<tflite::ReshapeOptionsT *>(value) : nullptr; |
1959 | } |
1960 | const tflite::ReshapeOptionsT *AsReshapeOptions() const { |
1961 | return type == BuiltinOptions_ReshapeOptions ? |
1962 | reinterpret_cast<const tflite::ReshapeOptionsT *>(value) : nullptr; |
1963 | } |
1964 | tflite::SkipGramOptionsT *AsSkipGramOptions() { |
1965 | return type == BuiltinOptions_SkipGramOptions ? |
1966 | reinterpret_cast<tflite::SkipGramOptionsT *>(value) : nullptr; |
1967 | } |
1968 | const tflite::SkipGramOptionsT *AsSkipGramOptions() const { |
1969 | return type == BuiltinOptions_SkipGramOptions ? |
1970 | reinterpret_cast<const tflite::SkipGramOptionsT *>(value) : nullptr; |
1971 | } |
1972 | tflite::SpaceToDepthOptionsT *AsSpaceToDepthOptions() { |
1973 | return type == BuiltinOptions_SpaceToDepthOptions ? |
1974 | reinterpret_cast<tflite::SpaceToDepthOptionsT *>(value) : nullptr; |
1975 | } |
1976 | const tflite::SpaceToDepthOptionsT *AsSpaceToDepthOptions() const { |
1977 | return type == BuiltinOptions_SpaceToDepthOptions ? |
1978 | reinterpret_cast<const tflite::SpaceToDepthOptionsT *>(value) : nullptr; |
1979 | } |
1980 | tflite::EmbeddingLookupSparseOptionsT *AsEmbeddingLookupSparseOptions() { |
1981 | return type == BuiltinOptions_EmbeddingLookupSparseOptions ? |
1982 | reinterpret_cast<tflite::EmbeddingLookupSparseOptionsT *>(value) : nullptr; |
1983 | } |
1984 | const tflite::EmbeddingLookupSparseOptionsT *AsEmbeddingLookupSparseOptions() const { |
1985 | return type == BuiltinOptions_EmbeddingLookupSparseOptions ? |
1986 | reinterpret_cast<const tflite::EmbeddingLookupSparseOptionsT *>(value) : nullptr; |
1987 | } |
1988 | tflite::MulOptionsT *AsMulOptions() { |
1989 | return type == BuiltinOptions_MulOptions ? |
1990 | reinterpret_cast<tflite::MulOptionsT *>(value) : nullptr; |
1991 | } |
1992 | const tflite::MulOptionsT *AsMulOptions() const { |
1993 | return type == BuiltinOptions_MulOptions ? |
1994 | reinterpret_cast<const tflite::MulOptionsT *>(value) : nullptr; |
1995 | } |
1996 | tflite::PadOptionsT *AsPadOptions() { |
1997 | return type == BuiltinOptions_PadOptions ? |
1998 | reinterpret_cast<tflite::PadOptionsT *>(value) : nullptr; |
1999 | } |
2000 | const tflite::PadOptionsT *AsPadOptions() const { |
2001 | return type == BuiltinOptions_PadOptions ? |
2002 | reinterpret_cast<const tflite::PadOptionsT *>(value) : nullptr; |
2003 | } |
2004 | tflite::GatherOptionsT *AsGatherOptions() { |
2005 | return type == BuiltinOptions_GatherOptions ? |
2006 | reinterpret_cast<tflite::GatherOptionsT *>(value) : nullptr; |
2007 | } |
2008 | const tflite::GatherOptionsT *AsGatherOptions() const { |
2009 | return type == BuiltinOptions_GatherOptions ? |
2010 | reinterpret_cast<const tflite::GatherOptionsT *>(value) : nullptr; |
2011 | } |
2012 | tflite::BatchToSpaceNDOptionsT *AsBatchToSpaceNDOptions() { |
2013 | return type == BuiltinOptions_BatchToSpaceNDOptions ? |
2014 | reinterpret_cast<tflite::BatchToSpaceNDOptionsT *>(value) : nullptr; |
2015 | } |
2016 | const tflite::BatchToSpaceNDOptionsT *AsBatchToSpaceNDOptions() const { |
2017 | return type == BuiltinOptions_BatchToSpaceNDOptions ? |
2018 | reinterpret_cast<const tflite::BatchToSpaceNDOptionsT *>(value) : nullptr; |
2019 | } |
2020 | tflite::SpaceToBatchNDOptionsT *AsSpaceToBatchNDOptions() { |
2021 | return type == BuiltinOptions_SpaceToBatchNDOptions ? |
2022 | reinterpret_cast<tflite::SpaceToBatchNDOptionsT *>(value) : nullptr; |
2023 | } |
2024 | const tflite::SpaceToBatchNDOptionsT *AsSpaceToBatchNDOptions() const { |
2025 | return type == BuiltinOptions_SpaceToBatchNDOptions ? |
2026 | reinterpret_cast<const tflite::SpaceToBatchNDOptionsT *>(value) : nullptr; |
2027 | } |
2028 | tflite::TransposeOptionsT *AsTransposeOptions() { |
2029 | return type == BuiltinOptions_TransposeOptions ? |
2030 | reinterpret_cast<tflite::TransposeOptionsT *>(value) : nullptr; |
2031 | } |
2032 | const tflite::TransposeOptionsT *AsTransposeOptions() const { |
2033 | return type == BuiltinOptions_TransposeOptions ? |
2034 | reinterpret_cast<const tflite::TransposeOptionsT *>(value) : nullptr; |
2035 | } |
2036 | tflite::ReducerOptionsT *AsReducerOptions() { |
2037 | return type == BuiltinOptions_ReducerOptions ? |
2038 | reinterpret_cast<tflite::ReducerOptionsT *>(value) : nullptr; |
2039 | } |
2040 | const tflite::ReducerOptionsT *AsReducerOptions() const { |
2041 | return type == BuiltinOptions_ReducerOptions ? |
2042 | reinterpret_cast<const tflite::ReducerOptionsT *>(value) : nullptr; |
2043 | } |
2044 | tflite::SubOptionsT *AsSubOptions() { |
2045 | return type == BuiltinOptions_SubOptions ? |
2046 | reinterpret_cast<tflite::SubOptionsT *>(value) : nullptr; |
2047 | } |
2048 | const tflite::SubOptionsT *AsSubOptions() const { |
2049 | return type == BuiltinOptions_SubOptions ? |
2050 | reinterpret_cast<const tflite::SubOptionsT *>(value) : nullptr; |
2051 | } |
2052 | tflite::DivOptionsT *AsDivOptions() { |
2053 | return type == BuiltinOptions_DivOptions ? |
2054 | reinterpret_cast<tflite::DivOptionsT *>(value) : nullptr; |
2055 | } |
2056 | const tflite::DivOptionsT *AsDivOptions() const { |
2057 | return type == BuiltinOptions_DivOptions ? |
2058 | reinterpret_cast<const tflite::DivOptionsT *>(value) : nullptr; |
2059 | } |
2060 | tflite::SqueezeOptionsT *AsSqueezeOptions() { |
2061 | return type == BuiltinOptions_SqueezeOptions ? |
2062 | reinterpret_cast<tflite::SqueezeOptionsT *>(value) : nullptr; |
2063 | } |
2064 | const tflite::SqueezeOptionsT *AsSqueezeOptions() const { |
2065 | return type == BuiltinOptions_SqueezeOptions ? |
2066 | reinterpret_cast<const tflite::SqueezeOptionsT *>(value) : nullptr; |
2067 | } |
2068 | tflite::SequenceRNNOptionsT *AsSequenceRNNOptions() { |
2069 | return type == BuiltinOptions_SequenceRNNOptions ? |
2070 | reinterpret_cast<tflite::SequenceRNNOptionsT *>(value) : nullptr; |
2071 | } |
2072 | const tflite::SequenceRNNOptionsT *AsSequenceRNNOptions() const { |
2073 | return type == BuiltinOptions_SequenceRNNOptions ? |
2074 | reinterpret_cast<const tflite::SequenceRNNOptionsT *>(value) : nullptr; |
2075 | } |
2076 | tflite::StridedSliceOptionsT *AsStridedSliceOptions() { |
2077 | return type == BuiltinOptions_StridedSliceOptions ? |
2078 | reinterpret_cast<tflite::StridedSliceOptionsT *>(value) : nullptr; |
2079 | } |
2080 | const tflite::StridedSliceOptionsT *AsStridedSliceOptions() const { |
2081 | return type == BuiltinOptions_StridedSliceOptions ? |
2082 | reinterpret_cast<const tflite::StridedSliceOptionsT *>(value) : nullptr; |
2083 | } |
2084 | tflite::ExpOptionsT *AsExpOptions() { |
2085 | return type == BuiltinOptions_ExpOptions ? |
2086 | reinterpret_cast<tflite::ExpOptionsT *>(value) : nullptr; |
2087 | } |
2088 | const tflite::ExpOptionsT *AsExpOptions() const { |
2089 | return type == BuiltinOptions_ExpOptions ? |
2090 | reinterpret_cast<const tflite::ExpOptionsT *>(value) : nullptr; |
2091 | } |
2092 | tflite::TopKV2OptionsT *AsTopKV2Options() { |
2093 | return type == BuiltinOptions_TopKV2Options ? |
2094 | reinterpret_cast<tflite::TopKV2OptionsT *>(value) : nullptr; |
2095 | } |
2096 | const tflite::TopKV2OptionsT *AsTopKV2Options() const { |
2097 | return type == BuiltinOptions_TopKV2Options ? |
2098 | reinterpret_cast<const tflite::TopKV2OptionsT *>(value) : nullptr; |
2099 | } |
2100 | tflite::SplitOptionsT *AsSplitOptions() { |
2101 | return type == BuiltinOptions_SplitOptions ? |
2102 | reinterpret_cast<tflite::SplitOptionsT *>(value) : nullptr; |
2103 | } |
2104 | const tflite::SplitOptionsT *AsSplitOptions() const { |
2105 | return type == BuiltinOptions_SplitOptions ? |
2106 | reinterpret_cast<const tflite::SplitOptionsT *>(value) : nullptr; |
2107 | } |
2108 | tflite::LogSoftmaxOptionsT *AsLogSoftmaxOptions() { |
2109 | return type == BuiltinOptions_LogSoftmaxOptions ? |
2110 | reinterpret_cast<tflite::LogSoftmaxOptionsT *>(value) : nullptr; |
2111 | } |
2112 | const tflite::LogSoftmaxOptionsT *AsLogSoftmaxOptions() const { |
2113 | return type == BuiltinOptions_LogSoftmaxOptions ? |
2114 | reinterpret_cast<const tflite::LogSoftmaxOptionsT *>(value) : nullptr; |
2115 | } |
2116 | tflite::CastOptionsT *AsCastOptions() { |
2117 | return type == BuiltinOptions_CastOptions ? |
2118 | reinterpret_cast<tflite::CastOptionsT *>(value) : nullptr; |
2119 | } |
2120 | const tflite::CastOptionsT *AsCastOptions() const { |
2121 | return type == BuiltinOptions_CastOptions ? |
2122 | reinterpret_cast<const tflite::CastOptionsT *>(value) : nullptr; |
2123 | } |
2124 | tflite::DequantizeOptionsT *AsDequantizeOptions() { |
2125 | return type == BuiltinOptions_DequantizeOptions ? |
2126 | reinterpret_cast<tflite::DequantizeOptionsT *>(value) : nullptr; |
2127 | } |
2128 | const tflite::DequantizeOptionsT *AsDequantizeOptions() const { |
2129 | return type == BuiltinOptions_DequantizeOptions ? |
2130 | reinterpret_cast<const tflite::DequantizeOptionsT *>(value) : nullptr; |
2131 | } |
2132 | tflite::MaximumMinimumOptionsT *AsMaximumMinimumOptions() { |
2133 | return type == BuiltinOptions_MaximumMinimumOptions ? |
2134 | reinterpret_cast<tflite::MaximumMinimumOptionsT *>(value) : nullptr; |
2135 | } |
2136 | const tflite::MaximumMinimumOptionsT *AsMaximumMinimumOptions() const { |
2137 | return type == BuiltinOptions_MaximumMinimumOptions ? |
2138 | reinterpret_cast<const tflite::MaximumMinimumOptionsT *>(value) : nullptr; |
2139 | } |
2140 | tflite::ArgMaxOptionsT *AsArgMaxOptions() { |
2141 | return type == BuiltinOptions_ArgMaxOptions ? |
2142 | reinterpret_cast<tflite::ArgMaxOptionsT *>(value) : nullptr; |
2143 | } |
2144 | const tflite::ArgMaxOptionsT *AsArgMaxOptions() const { |
2145 | return type == BuiltinOptions_ArgMaxOptions ? |
2146 | reinterpret_cast<const tflite::ArgMaxOptionsT *>(value) : nullptr; |
2147 | } |
2148 | tflite::LessOptionsT *AsLessOptions() { |
2149 | return type == BuiltinOptions_LessOptions ? |
2150 | reinterpret_cast<tflite::LessOptionsT *>(value) : nullptr; |
2151 | } |
2152 | const tflite::LessOptionsT *AsLessOptions() const { |
2153 | return type == BuiltinOptions_LessOptions ? |
2154 | reinterpret_cast<const tflite::LessOptionsT *>(value) : nullptr; |
2155 | } |
2156 | tflite::NegOptionsT *AsNegOptions() { |
2157 | return type == BuiltinOptions_NegOptions ? |
2158 | reinterpret_cast<tflite::NegOptionsT *>(value) : nullptr; |
2159 | } |
2160 | const tflite::NegOptionsT *AsNegOptions() const { |
2161 | return type == BuiltinOptions_NegOptions ? |
2162 | reinterpret_cast<const tflite::NegOptionsT *>(value) : nullptr; |
2163 | } |
2164 | tflite::PadV2OptionsT *AsPadV2Options() { |
2165 | return type == BuiltinOptions_PadV2Options ? |
2166 | reinterpret_cast<tflite::PadV2OptionsT *>(value) : nullptr; |
2167 | } |
2168 | const tflite::PadV2OptionsT *AsPadV2Options() const { |
2169 | return type == BuiltinOptions_PadV2Options ? |
2170 | reinterpret_cast<const tflite::PadV2OptionsT *>(value) : nullptr; |
2171 | } |
2172 | tflite::GreaterOptionsT *AsGreaterOptions() { |
2173 | return type == BuiltinOptions_GreaterOptions ? |
2174 | reinterpret_cast<tflite::GreaterOptionsT *>(value) : nullptr; |
2175 | } |
2176 | const tflite::GreaterOptionsT *AsGreaterOptions() const { |
2177 | return type == BuiltinOptions_GreaterOptions ? |
2178 | reinterpret_cast<const tflite::GreaterOptionsT *>(value) : nullptr; |
2179 | } |
2180 | tflite::GreaterEqualOptionsT *AsGreaterEqualOptions() { |
2181 | return type == BuiltinOptions_GreaterEqualOptions ? |
2182 | reinterpret_cast<tflite::GreaterEqualOptionsT *>(value) : nullptr; |
2183 | } |
2184 | const tflite::GreaterEqualOptionsT *AsGreaterEqualOptions() const { |
2185 | return type == BuiltinOptions_GreaterEqualOptions ? |
2186 | reinterpret_cast<const tflite::GreaterEqualOptionsT *>(value) : nullptr; |
2187 | } |
2188 | tflite::LessEqualOptionsT *AsLessEqualOptions() { |
2189 | return type == BuiltinOptions_LessEqualOptions ? |
2190 | reinterpret_cast<tflite::LessEqualOptionsT *>(value) : nullptr; |
2191 | } |
2192 | const tflite::LessEqualOptionsT *AsLessEqualOptions() const { |
2193 | return type == BuiltinOptions_LessEqualOptions ? |
2194 | reinterpret_cast<const tflite::LessEqualOptionsT *>(value) : nullptr; |
2195 | } |
2196 | tflite::SelectOptionsT *AsSelectOptions() { |
2197 | return type == BuiltinOptions_SelectOptions ? |
2198 | reinterpret_cast<tflite::SelectOptionsT *>(value) : nullptr; |
2199 | } |
2200 | const tflite::SelectOptionsT *AsSelectOptions() const { |
2201 | return type == BuiltinOptions_SelectOptions ? |
2202 | reinterpret_cast<const tflite::SelectOptionsT *>(value) : nullptr; |
2203 | } |
2204 | tflite::SliceOptionsT *AsSliceOptions() { |
2205 | return type == BuiltinOptions_SliceOptions ? |
2206 | reinterpret_cast<tflite::SliceOptionsT *>(value) : nullptr; |
2207 | } |
2208 | const tflite::SliceOptionsT *AsSliceOptions() const { |
2209 | return type == BuiltinOptions_SliceOptions ? |
2210 | reinterpret_cast<const tflite::SliceOptionsT *>(value) : nullptr; |
2211 | } |
2212 | tflite::TransposeConvOptionsT *AsTransposeConvOptions() { |
2213 | return type == BuiltinOptions_TransposeConvOptions ? |
2214 | reinterpret_cast<tflite::TransposeConvOptionsT *>(value) : nullptr; |
2215 | } |
2216 | const tflite::TransposeConvOptionsT *AsTransposeConvOptions() const { |
2217 | return type == BuiltinOptions_TransposeConvOptions ? |
2218 | reinterpret_cast<const tflite::TransposeConvOptionsT *>(value) : nullptr; |
2219 | } |
2220 | tflite::SparseToDenseOptionsT *AsSparseToDenseOptions() { |
2221 | return type == BuiltinOptions_SparseToDenseOptions ? |
2222 | reinterpret_cast<tflite::SparseToDenseOptionsT *>(value) : nullptr; |
2223 | } |
2224 | const tflite::SparseToDenseOptionsT *AsSparseToDenseOptions() const { |
2225 | return type == BuiltinOptions_SparseToDenseOptions ? |
2226 | reinterpret_cast<const tflite::SparseToDenseOptionsT *>(value) : nullptr; |
2227 | } |
2228 | tflite::TileOptionsT *AsTileOptions() { |
2229 | return type == BuiltinOptions_TileOptions ? |
2230 | reinterpret_cast<tflite::TileOptionsT *>(value) : nullptr; |
2231 | } |
2232 | const tflite::TileOptionsT *AsTileOptions() const { |
2233 | return type == BuiltinOptions_TileOptions ? |
2234 | reinterpret_cast<const tflite::TileOptionsT *>(value) : nullptr; |
2235 | } |
2236 | tflite::ExpandDimsOptionsT *AsExpandDimsOptions() { |
2237 | return type == BuiltinOptions_ExpandDimsOptions ? |
2238 | reinterpret_cast<tflite::ExpandDimsOptionsT *>(value) : nullptr; |
2239 | } |
2240 | const tflite::ExpandDimsOptionsT *AsExpandDimsOptions() const { |
2241 | return type == BuiltinOptions_ExpandDimsOptions ? |
2242 | reinterpret_cast<const tflite::ExpandDimsOptionsT *>(value) : nullptr; |
2243 | } |
2244 | tflite::EqualOptionsT *AsEqualOptions() { |
2245 | return type == BuiltinOptions_EqualOptions ? |
2246 | reinterpret_cast<tflite::EqualOptionsT *>(value) : nullptr; |
2247 | } |
2248 | const tflite::EqualOptionsT *AsEqualOptions() const { |
2249 | return type == BuiltinOptions_EqualOptions ? |
2250 | reinterpret_cast<const tflite::EqualOptionsT *>(value) : nullptr; |
2251 | } |
2252 | tflite::NotEqualOptionsT *AsNotEqualOptions() { |
2253 | return type == BuiltinOptions_NotEqualOptions ? |
2254 | reinterpret_cast<tflite::NotEqualOptionsT *>(value) : nullptr; |
2255 | } |
2256 | const tflite::NotEqualOptionsT *AsNotEqualOptions() const { |
2257 | return type == BuiltinOptions_NotEqualOptions ? |
2258 | reinterpret_cast<const tflite::NotEqualOptionsT *>(value) : nullptr; |
2259 | } |
2260 | tflite::ShapeOptionsT *AsShapeOptions() { |
2261 | return type == BuiltinOptions_ShapeOptions ? |
2262 | reinterpret_cast<tflite::ShapeOptionsT *>(value) : nullptr; |
2263 | } |
2264 | const tflite::ShapeOptionsT *AsShapeOptions() const { |
2265 | return type == BuiltinOptions_ShapeOptions ? |
2266 | reinterpret_cast<const tflite::ShapeOptionsT *>(value) : nullptr; |
2267 | } |
2268 | tflite::PowOptionsT *AsPowOptions() { |
2269 | return type == BuiltinOptions_PowOptions ? |
2270 | reinterpret_cast<tflite::PowOptionsT *>(value) : nullptr; |
2271 | } |
2272 | const tflite::PowOptionsT *AsPowOptions() const { |
2273 | return type == BuiltinOptions_PowOptions ? |
2274 | reinterpret_cast<const tflite::PowOptionsT *>(value) : nullptr; |
2275 | } |
2276 | tflite::ArgMinOptionsT *AsArgMinOptions() { |
2277 | return type == BuiltinOptions_ArgMinOptions ? |
2278 | reinterpret_cast<tflite::ArgMinOptionsT *>(value) : nullptr; |
2279 | } |
2280 | const tflite::ArgMinOptionsT *AsArgMinOptions() const { |
2281 | return type == BuiltinOptions_ArgMinOptions ? |
2282 | reinterpret_cast<const tflite::ArgMinOptionsT *>(value) : nullptr; |
2283 | } |
2284 | tflite::FakeQuantOptionsT *AsFakeQuantOptions() { |
2285 | return type == BuiltinOptions_FakeQuantOptions ? |
2286 | reinterpret_cast<tflite::FakeQuantOptionsT *>(value) : nullptr; |
2287 | } |
2288 | const tflite::FakeQuantOptionsT *AsFakeQuantOptions() const { |
2289 | return type == BuiltinOptions_FakeQuantOptions ? |
2290 | reinterpret_cast<const tflite::FakeQuantOptionsT *>(value) : nullptr; |
2291 | } |
2292 | tflite::PackOptionsT *AsPackOptions() { |
2293 | return type == BuiltinOptions_PackOptions ? |
2294 | reinterpret_cast<tflite::PackOptionsT *>(value) : nullptr; |
2295 | } |
2296 | const tflite::PackOptionsT *AsPackOptions() const { |
2297 | return type == BuiltinOptions_PackOptions ? |
2298 | reinterpret_cast<const tflite::PackOptionsT *>(value) : nullptr; |
2299 | } |
2300 | tflite::LogicalOrOptionsT *AsLogicalOrOptions() { |
2301 | return type == BuiltinOptions_LogicalOrOptions ? |
2302 | reinterpret_cast<tflite::LogicalOrOptionsT *>(value) : nullptr; |
2303 | } |
2304 | const tflite::LogicalOrOptionsT *AsLogicalOrOptions() const { |
2305 | return type == BuiltinOptions_LogicalOrOptions ? |
2306 | reinterpret_cast<const tflite::LogicalOrOptionsT *>(value) : nullptr; |
2307 | } |
2308 | tflite::OneHotOptionsT *AsOneHotOptions() { |
2309 | return type == BuiltinOptions_OneHotOptions ? |
2310 | reinterpret_cast<tflite::OneHotOptionsT *>(value) : nullptr; |
2311 | } |
2312 | const tflite::OneHotOptionsT *AsOneHotOptions() const { |
2313 | return type == BuiltinOptions_OneHotOptions ? |
2314 | reinterpret_cast<const tflite::OneHotOptionsT *>(value) : nullptr; |
2315 | } |
2316 | tflite::LogicalAndOptionsT *AsLogicalAndOptions() { |
2317 | return type == BuiltinOptions_LogicalAndOptions ? |
2318 | reinterpret_cast<tflite::LogicalAndOptionsT *>(value) : nullptr; |
2319 | } |
2320 | const tflite::LogicalAndOptionsT *AsLogicalAndOptions() const { |
2321 | return type == BuiltinOptions_LogicalAndOptions ? |
2322 | reinterpret_cast<const tflite::LogicalAndOptionsT *>(value) : nullptr; |
2323 | } |
2324 | tflite::LogicalNotOptionsT *AsLogicalNotOptions() { |
2325 | return type == BuiltinOptions_LogicalNotOptions ? |
2326 | reinterpret_cast<tflite::LogicalNotOptionsT *>(value) : nullptr; |
2327 | } |
2328 | const tflite::LogicalNotOptionsT *AsLogicalNotOptions() const { |
2329 | return type == BuiltinOptions_LogicalNotOptions ? |
2330 | reinterpret_cast<const tflite::LogicalNotOptionsT *>(value) : nullptr; |
2331 | } |
2332 | tflite::UnpackOptionsT *AsUnpackOptions() { |
2333 | return type == BuiltinOptions_UnpackOptions ? |
2334 | reinterpret_cast<tflite::UnpackOptionsT *>(value) : nullptr; |
2335 | } |
2336 | const tflite::UnpackOptionsT *AsUnpackOptions() const { |
2337 | return type == BuiltinOptions_UnpackOptions ? |
2338 | reinterpret_cast<const tflite::UnpackOptionsT *>(value) : nullptr; |
2339 | } |
2340 | tflite::FloorDivOptionsT *AsFloorDivOptions() { |
2341 | return type == BuiltinOptions_FloorDivOptions ? |
2342 | reinterpret_cast<tflite::FloorDivOptionsT *>(value) : nullptr; |
2343 | } |
2344 | const tflite::FloorDivOptionsT *AsFloorDivOptions() const { |
2345 | return type == BuiltinOptions_FloorDivOptions ? |
2346 | reinterpret_cast<const tflite::FloorDivOptionsT *>(value) : nullptr; |
2347 | } |
2348 | tflite::SquareOptionsT *AsSquareOptions() { |
2349 | return type == BuiltinOptions_SquareOptions ? |
2350 | reinterpret_cast<tflite::SquareOptionsT *>(value) : nullptr; |
2351 | } |
2352 | const tflite::SquareOptionsT *AsSquareOptions() const { |
2353 | return type == BuiltinOptions_SquareOptions ? |
2354 | reinterpret_cast<const tflite::SquareOptionsT *>(value) : nullptr; |
2355 | } |
2356 | tflite::ZerosLikeOptionsT *AsZerosLikeOptions() { |
2357 | return type == BuiltinOptions_ZerosLikeOptions ? |
2358 | reinterpret_cast<tflite::ZerosLikeOptionsT *>(value) : nullptr; |
2359 | } |
2360 | const tflite::ZerosLikeOptionsT *AsZerosLikeOptions() const { |
2361 | return type == BuiltinOptions_ZerosLikeOptions ? |
2362 | reinterpret_cast<const tflite::ZerosLikeOptionsT *>(value) : nullptr; |
2363 | } |
2364 | tflite::FillOptionsT *AsFillOptions() { |
2365 | return type == BuiltinOptions_FillOptions ? |
2366 | reinterpret_cast<tflite::FillOptionsT *>(value) : nullptr; |
2367 | } |
2368 | const tflite::FillOptionsT *AsFillOptions() const { |
2369 | return type == BuiltinOptions_FillOptions ? |
2370 | reinterpret_cast<const tflite::FillOptionsT *>(value) : nullptr; |
2371 | } |
2372 | tflite::BidirectionalSequenceLSTMOptionsT *AsBidirectionalSequenceLSTMOptions() { |
2373 | return type == BuiltinOptions_BidirectionalSequenceLSTMOptions ? |
2374 | reinterpret_cast<tflite::BidirectionalSequenceLSTMOptionsT *>(value) : nullptr; |
2375 | } |
2376 | const tflite::BidirectionalSequenceLSTMOptionsT *AsBidirectionalSequenceLSTMOptions() const { |
2377 | return type == BuiltinOptions_BidirectionalSequenceLSTMOptions ? |
2378 | reinterpret_cast<const tflite::BidirectionalSequenceLSTMOptionsT *>(value) : nullptr; |
2379 | } |
2380 | tflite::BidirectionalSequenceRNNOptionsT *AsBidirectionalSequenceRNNOptions() { |
2381 | return type == BuiltinOptions_BidirectionalSequenceRNNOptions ? |
2382 | reinterpret_cast<tflite::BidirectionalSequenceRNNOptionsT *>(value) : nullptr; |
2383 | } |
2384 | const tflite::BidirectionalSequenceRNNOptionsT *AsBidirectionalSequenceRNNOptions() const { |
2385 | return type == BuiltinOptions_BidirectionalSequenceRNNOptions ? |
2386 | reinterpret_cast<const tflite::BidirectionalSequenceRNNOptionsT *>(value) : nullptr; |
2387 | } |
2388 | tflite::UnidirectionalSequenceLSTMOptionsT *AsUnidirectionalSequenceLSTMOptions() { |
2389 | return type == BuiltinOptions_UnidirectionalSequenceLSTMOptions ? |
2390 | reinterpret_cast<tflite::UnidirectionalSequenceLSTMOptionsT *>(value) : nullptr; |
2391 | } |
2392 | const tflite::UnidirectionalSequenceLSTMOptionsT *AsUnidirectionalSequenceLSTMOptions() const { |
2393 | return type == BuiltinOptions_UnidirectionalSequenceLSTMOptions ? |
2394 | reinterpret_cast<const tflite::UnidirectionalSequenceLSTMOptionsT *>(value) : nullptr; |
2395 | } |
2396 | tflite::FloorModOptionsT *AsFloorModOptions() { |
2397 | return type == BuiltinOptions_FloorModOptions ? |
2398 | reinterpret_cast<tflite::FloorModOptionsT *>(value) : nullptr; |
2399 | } |
2400 | const tflite::FloorModOptionsT *AsFloorModOptions() const { |
2401 | return type == BuiltinOptions_FloorModOptions ? |
2402 | reinterpret_cast<const tflite::FloorModOptionsT *>(value) : nullptr; |
2403 | } |
2404 | tflite::RangeOptionsT *AsRangeOptions() { |
2405 | return type == BuiltinOptions_RangeOptions ? |
2406 | reinterpret_cast<tflite::RangeOptionsT *>(value) : nullptr; |
2407 | } |
2408 | const tflite::RangeOptionsT *AsRangeOptions() const { |
2409 | return type == BuiltinOptions_RangeOptions ? |
2410 | reinterpret_cast<const tflite::RangeOptionsT *>(value) : nullptr; |
2411 | } |
2412 | tflite::ResizeNearestNeighborOptionsT *AsResizeNearestNeighborOptions() { |
2413 | return type == BuiltinOptions_ResizeNearestNeighborOptions ? |
2414 | reinterpret_cast<tflite::ResizeNearestNeighborOptionsT *>(value) : nullptr; |
2415 | } |
2416 | const tflite::ResizeNearestNeighborOptionsT *AsResizeNearestNeighborOptions() const { |
2417 | return type == BuiltinOptions_ResizeNearestNeighborOptions ? |
2418 | reinterpret_cast<const tflite::ResizeNearestNeighborOptionsT *>(value) : nullptr; |
2419 | } |
2420 | tflite::LeakyReluOptionsT *AsLeakyReluOptions() { |
2421 | return type == BuiltinOptions_LeakyReluOptions ? |
2422 | reinterpret_cast<tflite::LeakyReluOptionsT *>(value) : nullptr; |
2423 | } |
2424 | const tflite::LeakyReluOptionsT *AsLeakyReluOptions() const { |
2425 | return type == BuiltinOptions_LeakyReluOptions ? |
2426 | reinterpret_cast<const tflite::LeakyReluOptionsT *>(value) : nullptr; |
2427 | } |
2428 | tflite::SquaredDifferenceOptionsT *AsSquaredDifferenceOptions() { |
2429 | return type == BuiltinOptions_SquaredDifferenceOptions ? |
2430 | reinterpret_cast<tflite::SquaredDifferenceOptionsT *>(value) : nullptr; |
2431 | } |
2432 | const tflite::SquaredDifferenceOptionsT *AsSquaredDifferenceOptions() const { |
2433 | return type == BuiltinOptions_SquaredDifferenceOptions ? |
2434 | reinterpret_cast<const tflite::SquaredDifferenceOptionsT *>(value) : nullptr; |
2435 | } |
2436 | tflite::MirrorPadOptionsT *AsMirrorPadOptions() { |
2437 | return type == BuiltinOptions_MirrorPadOptions ? |
2438 | reinterpret_cast<tflite::MirrorPadOptionsT *>(value) : nullptr; |
2439 | } |
2440 | const tflite::MirrorPadOptionsT *AsMirrorPadOptions() const { |
2441 | return type == BuiltinOptions_MirrorPadOptions ? |
2442 | reinterpret_cast<const tflite::MirrorPadOptionsT *>(value) : nullptr; |
2443 | } |
2444 | tflite::AbsOptionsT *AsAbsOptions() { |
2445 | return type == BuiltinOptions_AbsOptions ? |
2446 | reinterpret_cast<tflite::AbsOptionsT *>(value) : nullptr; |
2447 | } |
2448 | const tflite::AbsOptionsT *AsAbsOptions() const { |
2449 | return type == BuiltinOptions_AbsOptions ? |
2450 | reinterpret_cast<const tflite::AbsOptionsT *>(value) : nullptr; |
2451 | } |
2452 | tflite::SplitVOptionsT *AsSplitVOptions() { |
2453 | return type == BuiltinOptions_SplitVOptions ? |
2454 | reinterpret_cast<tflite::SplitVOptionsT *>(value) : nullptr; |
2455 | } |
2456 | const tflite::SplitVOptionsT *AsSplitVOptions() const { |
2457 | return type == BuiltinOptions_SplitVOptions ? |
2458 | reinterpret_cast<const tflite::SplitVOptionsT *>(value) : nullptr; |
2459 | } |
2460 | tflite::UniqueOptionsT *AsUniqueOptions() { |
2461 | return type == BuiltinOptions_UniqueOptions ? |
2462 | reinterpret_cast<tflite::UniqueOptionsT *>(value) : nullptr; |
2463 | } |
2464 | const tflite::UniqueOptionsT *AsUniqueOptions() const { |
2465 | return type == BuiltinOptions_UniqueOptions ? |
2466 | reinterpret_cast<const tflite::UniqueOptionsT *>(value) : nullptr; |
2467 | } |
2468 | tflite::ReverseV2OptionsT *AsReverseV2Options() { |
2469 | return type == BuiltinOptions_ReverseV2Options ? |
2470 | reinterpret_cast<tflite::ReverseV2OptionsT *>(value) : nullptr; |
2471 | } |
2472 | const tflite::ReverseV2OptionsT *AsReverseV2Options() const { |
2473 | return type == BuiltinOptions_ReverseV2Options ? |
2474 | reinterpret_cast<const tflite::ReverseV2OptionsT *>(value) : nullptr; |
2475 | } |
2476 | tflite::AddNOptionsT *AsAddNOptions() { |
2477 | return type == BuiltinOptions_AddNOptions ? |
2478 | reinterpret_cast<tflite::AddNOptionsT *>(value) : nullptr; |
2479 | } |
2480 | const tflite::AddNOptionsT *AsAddNOptions() const { |
2481 | return type == BuiltinOptions_AddNOptions ? |
2482 | reinterpret_cast<const tflite::AddNOptionsT *>(value) : nullptr; |
2483 | } |
2484 | tflite::GatherNdOptionsT *AsGatherNdOptions() { |
2485 | return type == BuiltinOptions_GatherNdOptions ? |
2486 | reinterpret_cast<tflite::GatherNdOptionsT *>(value) : nullptr; |
2487 | } |
2488 | const tflite::GatherNdOptionsT *AsGatherNdOptions() const { |
2489 | return type == BuiltinOptions_GatherNdOptions ? |
2490 | reinterpret_cast<const tflite::GatherNdOptionsT *>(value) : nullptr; |
2491 | } |
2492 | tflite::CosOptionsT *AsCosOptions() { |
2493 | return type == BuiltinOptions_CosOptions ? |
2494 | reinterpret_cast<tflite::CosOptionsT *>(value) : nullptr; |
2495 | } |
2496 | const tflite::CosOptionsT *AsCosOptions() const { |
2497 | return type == BuiltinOptions_CosOptions ? |
2498 | reinterpret_cast<const tflite::CosOptionsT *>(value) : nullptr; |
2499 | } |
2500 | tflite::WhereOptionsT *AsWhereOptions() { |
2501 | return type == BuiltinOptions_WhereOptions ? |
2502 | reinterpret_cast<tflite::WhereOptionsT *>(value) : nullptr; |
2503 | } |
2504 | const tflite::WhereOptionsT *AsWhereOptions() const { |
2505 | return type == BuiltinOptions_WhereOptions ? |
2506 | reinterpret_cast<const tflite::WhereOptionsT *>(value) : nullptr; |
2507 | } |
2508 | tflite::RankOptionsT *AsRankOptions() { |
2509 | return type == BuiltinOptions_RankOptions ? |
2510 | reinterpret_cast<tflite::RankOptionsT *>(value) : nullptr; |
2511 | } |
2512 | const tflite::RankOptionsT *AsRankOptions() const { |
2513 | return type == BuiltinOptions_RankOptions ? |
2514 | reinterpret_cast<const tflite::RankOptionsT *>(value) : nullptr; |
2515 | } |
2516 | tflite::ReverseSequenceOptionsT *AsReverseSequenceOptions() { |
2517 | return type == BuiltinOptions_ReverseSequenceOptions ? |
2518 | reinterpret_cast<tflite::ReverseSequenceOptionsT *>(value) : nullptr; |
2519 | } |
2520 | const tflite::ReverseSequenceOptionsT *AsReverseSequenceOptions() const { |
2521 | return type == BuiltinOptions_ReverseSequenceOptions ? |
2522 | reinterpret_cast<const tflite::ReverseSequenceOptionsT *>(value) : nullptr; |
2523 | } |
2524 | tflite::MatrixDiagOptionsT *AsMatrixDiagOptions() { |
2525 | return type == BuiltinOptions_MatrixDiagOptions ? |
2526 | reinterpret_cast<tflite::MatrixDiagOptionsT *>(value) : nullptr; |
2527 | } |
2528 | const tflite::MatrixDiagOptionsT *AsMatrixDiagOptions() const { |
2529 | return type == BuiltinOptions_MatrixDiagOptions ? |
2530 | reinterpret_cast<const tflite::MatrixDiagOptionsT *>(value) : nullptr; |
2531 | } |
2532 | tflite::QuantizeOptionsT *AsQuantizeOptions() { |
2533 | return type == BuiltinOptions_QuantizeOptions ? |
2534 | reinterpret_cast<tflite::QuantizeOptionsT *>(value) : nullptr; |
2535 | } |
2536 | const tflite::QuantizeOptionsT *AsQuantizeOptions() const { |
2537 | return type == BuiltinOptions_QuantizeOptions ? |
2538 | reinterpret_cast<const tflite::QuantizeOptionsT *>(value) : nullptr; |
2539 | } |
2540 | tflite::MatrixSetDiagOptionsT *AsMatrixSetDiagOptions() { |
2541 | return type == BuiltinOptions_MatrixSetDiagOptions ? |
2542 | reinterpret_cast<tflite::MatrixSetDiagOptionsT *>(value) : nullptr; |
2543 | } |
2544 | const tflite::MatrixSetDiagOptionsT *AsMatrixSetDiagOptions() const { |
2545 | return type == BuiltinOptions_MatrixSetDiagOptions ? |
2546 | reinterpret_cast<const tflite::MatrixSetDiagOptionsT *>(value) : nullptr; |
2547 | } |
2548 | tflite::HardSwishOptionsT *AsHardSwishOptions() { |
2549 | return type == BuiltinOptions_HardSwishOptions ? |
2550 | reinterpret_cast<tflite::HardSwishOptionsT *>(value) : nullptr; |
2551 | } |
2552 | const tflite::HardSwishOptionsT *AsHardSwishOptions() const { |
2553 | return type == BuiltinOptions_HardSwishOptions ? |
2554 | reinterpret_cast<const tflite::HardSwishOptionsT *>(value) : nullptr; |
2555 | } |
2556 | tflite::IfOptionsT *AsIfOptions() { |
2557 | return type == BuiltinOptions_IfOptions ? |
2558 | reinterpret_cast<tflite::IfOptionsT *>(value) : nullptr; |
2559 | } |
2560 | const tflite::IfOptionsT *AsIfOptions() const { |
2561 | return type == BuiltinOptions_IfOptions ? |
2562 | reinterpret_cast<const tflite::IfOptionsT *>(value) : nullptr; |
2563 | } |
2564 | tflite::WhileOptionsT *AsWhileOptions() { |
2565 | return type == BuiltinOptions_WhileOptions ? |
2566 | reinterpret_cast<tflite::WhileOptionsT *>(value) : nullptr; |
2567 | } |
2568 | const tflite::WhileOptionsT *AsWhileOptions() const { |
2569 | return type == BuiltinOptions_WhileOptions ? |
2570 | reinterpret_cast<const tflite::WhileOptionsT *>(value) : nullptr; |
2571 | } |
2572 | tflite::DepthToSpaceOptionsT *AsDepthToSpaceOptions() { |
2573 | return type == BuiltinOptions_DepthToSpaceOptions ? |
2574 | reinterpret_cast<tflite::DepthToSpaceOptionsT *>(value) : nullptr; |
2575 | } |
2576 | const tflite::DepthToSpaceOptionsT *AsDepthToSpaceOptions() const { |
2577 | return type == BuiltinOptions_DepthToSpaceOptions ? |
2578 | reinterpret_cast<const tflite::DepthToSpaceOptionsT *>(value) : nullptr; |
2579 | } |
2580 | tflite::NonMaxSuppressionV4OptionsT *AsNonMaxSuppressionV4Options() { |
2581 | return type == BuiltinOptions_NonMaxSuppressionV4Options ? |
2582 | reinterpret_cast<tflite::NonMaxSuppressionV4OptionsT *>(value) : nullptr; |
2583 | } |
2584 | const tflite::NonMaxSuppressionV4OptionsT *AsNonMaxSuppressionV4Options() const { |
2585 | return type == BuiltinOptions_NonMaxSuppressionV4Options ? |
2586 | reinterpret_cast<const tflite::NonMaxSuppressionV4OptionsT *>(value) : nullptr; |
2587 | } |
2588 | tflite::NonMaxSuppressionV5OptionsT *AsNonMaxSuppressionV5Options() { |
2589 | return type == BuiltinOptions_NonMaxSuppressionV5Options ? |
2590 | reinterpret_cast<tflite::NonMaxSuppressionV5OptionsT *>(value) : nullptr; |
2591 | } |
2592 | const tflite::NonMaxSuppressionV5OptionsT *AsNonMaxSuppressionV5Options() const { |
2593 | return type == BuiltinOptions_NonMaxSuppressionV5Options ? |
2594 | reinterpret_cast<const tflite::NonMaxSuppressionV5OptionsT *>(value) : nullptr; |
2595 | } |
2596 | tflite::ScatterNdOptionsT *AsScatterNdOptions() { |
2597 | return type == BuiltinOptions_ScatterNdOptions ? |
2598 | reinterpret_cast<tflite::ScatterNdOptionsT *>(value) : nullptr; |
2599 | } |
2600 | const tflite::ScatterNdOptionsT *AsScatterNdOptions() const { |
2601 | return type == BuiltinOptions_ScatterNdOptions ? |
2602 | reinterpret_cast<const tflite::ScatterNdOptionsT *>(value) : nullptr; |
2603 | } |
2604 | tflite::SelectV2OptionsT *AsSelectV2Options() { |
2605 | return type == BuiltinOptions_SelectV2Options ? |
2606 | reinterpret_cast<tflite::SelectV2OptionsT *>(value) : nullptr; |
2607 | } |
2608 | const tflite::SelectV2OptionsT *AsSelectV2Options() const { |
2609 | return type == BuiltinOptions_SelectV2Options ? |
2610 | reinterpret_cast<const tflite::SelectV2OptionsT *>(value) : nullptr; |
2611 | } |
2612 | tflite::DensifyOptionsT *AsDensifyOptions() { |
2613 | return type == BuiltinOptions_DensifyOptions ? |
2614 | reinterpret_cast<tflite::DensifyOptionsT *>(value) : nullptr; |
2615 | } |
2616 | const tflite::DensifyOptionsT *AsDensifyOptions() const { |
2617 | return type == BuiltinOptions_DensifyOptions ? |
2618 | reinterpret_cast<const tflite::DensifyOptionsT *>(value) : nullptr; |
2619 | } |
2620 | tflite::SegmentSumOptionsT *AsSegmentSumOptions() { |
2621 | return type == BuiltinOptions_SegmentSumOptions ? |
2622 | reinterpret_cast<tflite::SegmentSumOptionsT *>(value) : nullptr; |
2623 | } |
2624 | const tflite::SegmentSumOptionsT *AsSegmentSumOptions() const { |
2625 | return type == BuiltinOptions_SegmentSumOptions ? |
2626 | reinterpret_cast<const tflite::SegmentSumOptionsT *>(value) : nullptr; |
2627 | } |
2628 | tflite::BatchMatMulOptionsT *AsBatchMatMulOptions() { |
2629 | return type == BuiltinOptions_BatchMatMulOptions ? |
2630 | reinterpret_cast<tflite::BatchMatMulOptionsT *>(value) : nullptr; |
2631 | } |
2632 | const tflite::BatchMatMulOptionsT *AsBatchMatMulOptions() const { |
2633 | return type == BuiltinOptions_BatchMatMulOptions ? |
2634 | reinterpret_cast<const tflite::BatchMatMulOptionsT *>(value) : nullptr; |
2635 | } |
2636 | }; |
2637 | |
2638 | bool VerifyBuiltinOptions(flatbuffers::Verifier &verifier, const void *obj, BuiltinOptions type); |
2639 | bool VerifyBuiltinOptionsVector(flatbuffers::Verifier &verifier, const flatbuffers::Vector<flatbuffers::Offset<void>> *values, const flatbuffers::Vector<uint8_t> *types); |
2640 | |
2641 | enum Padding { |
2642 | Padding_SAME = 0, |
2643 | Padding_VALID = 1, |
2644 | Padding_MIN = Padding_SAME, |
2645 | Padding_MAX = Padding_VALID |
2646 | }; |
2647 | |
2648 | inline const Padding (&EnumValuesPadding())[2] { |
2649 | static const Padding values[] = { |
2650 | Padding_SAME, |
2651 | Padding_VALID |
2652 | }; |
2653 | return values; |
2654 | } |
2655 | |
2656 | inline const char * const *EnumNamesPadding() { |
2657 | static const char * const names[3] = { |
2658 | "SAME" , |
2659 | "VALID" , |
2660 | nullptr |
2661 | }; |
2662 | return names; |
2663 | } |
2664 | |
2665 | inline const char *EnumNamePadding(Padding e) { |
2666 | if (flatbuffers::IsOutRange(e, Padding_SAME, Padding_VALID)) return "" ; |
2667 | const size_t index = static_cast<size_t>(e); |
2668 | return EnumNamesPadding()[index]; |
2669 | } |
2670 | |
2671 | enum ActivationFunctionType { |
2672 | ActivationFunctionType_NONE = 0, |
2673 | ActivationFunctionType_RELU = 1, |
2674 | ActivationFunctionType_RELU_N1_TO_1 = 2, |
2675 | ActivationFunctionType_RELU6 = 3, |
2676 | ActivationFunctionType_TANH = 4, |
2677 | ActivationFunctionType_SIGN_BIT = 5, |
2678 | ActivationFunctionType_MIN = ActivationFunctionType_NONE, |
2679 | ActivationFunctionType_MAX = ActivationFunctionType_SIGN_BIT |
2680 | }; |
2681 | |
2682 | inline const ActivationFunctionType (&EnumValuesActivationFunctionType())[6] { |
2683 | static const ActivationFunctionType values[] = { |
2684 | ActivationFunctionType_NONE, |
2685 | ActivationFunctionType_RELU, |
2686 | ActivationFunctionType_RELU_N1_TO_1, |
2687 | ActivationFunctionType_RELU6, |
2688 | ActivationFunctionType_TANH, |
2689 | ActivationFunctionType_SIGN_BIT |
2690 | }; |
2691 | return values; |
2692 | } |
2693 | |
2694 | inline const char * const *EnumNamesActivationFunctionType() { |
2695 | static const char * const names[7] = { |
2696 | "NONE" , |
2697 | "RELU" , |
2698 | "RELU_N1_TO_1" , |
2699 | "RELU6" , |
2700 | "TANH" , |
2701 | "SIGN_BIT" , |
2702 | nullptr |
2703 | }; |
2704 | return names; |
2705 | } |
2706 | |
2707 | inline const char *EnumNameActivationFunctionType(ActivationFunctionType e) { |
2708 | if (flatbuffers::IsOutRange(e, ActivationFunctionType_NONE, ActivationFunctionType_SIGN_BIT)) return "" ; |
2709 | const size_t index = static_cast<size_t>(e); |
2710 | return EnumNamesActivationFunctionType()[index]; |
2711 | } |
2712 | |
2713 | enum LSHProjectionType { |
2714 | LSHProjectionType_UNKNOWN = 0, |
2715 | LSHProjectionType_SPARSE = 1, |
2716 | LSHProjectionType_DENSE = 2, |
2717 | LSHProjectionType_MIN = LSHProjectionType_UNKNOWN, |
2718 | LSHProjectionType_MAX = LSHProjectionType_DENSE |
2719 | }; |
2720 | |
2721 | inline const LSHProjectionType (&EnumValuesLSHProjectionType())[3] { |
2722 | static const LSHProjectionType values[] = { |
2723 | LSHProjectionType_UNKNOWN, |
2724 | LSHProjectionType_SPARSE, |
2725 | LSHProjectionType_DENSE |
2726 | }; |
2727 | return values; |
2728 | } |
2729 | |
2730 | inline const char * const *EnumNamesLSHProjectionType() { |
2731 | static const char * const names[4] = { |
2732 | "UNKNOWN" , |
2733 | "SPARSE" , |
2734 | "DENSE" , |
2735 | nullptr |
2736 | }; |
2737 | return names; |
2738 | } |
2739 | |
2740 | inline const char *EnumNameLSHProjectionType(LSHProjectionType e) { |
2741 | if (flatbuffers::IsOutRange(e, LSHProjectionType_UNKNOWN, LSHProjectionType_DENSE)) return "" ; |
2742 | const size_t index = static_cast<size_t>(e); |
2743 | return EnumNamesLSHProjectionType()[index]; |
2744 | } |
2745 | |
2746 | enum FullyConnectedOptionsWeightsFormat { |
2747 | FullyConnectedOptionsWeightsFormat_DEFAULT = 0, |
2748 | FullyConnectedOptionsWeightsFormat_SHUFFLED4x16INT8 = 1, |
2749 | FullyConnectedOptionsWeightsFormat_MIN = FullyConnectedOptionsWeightsFormat_DEFAULT, |
2750 | FullyConnectedOptionsWeightsFormat_MAX = FullyConnectedOptionsWeightsFormat_SHUFFLED4x16INT8 |
2751 | }; |
2752 | |
2753 | inline const FullyConnectedOptionsWeightsFormat (&EnumValuesFullyConnectedOptionsWeightsFormat())[2] { |
2754 | static const FullyConnectedOptionsWeightsFormat values[] = { |
2755 | FullyConnectedOptionsWeightsFormat_DEFAULT, |
2756 | FullyConnectedOptionsWeightsFormat_SHUFFLED4x16INT8 |
2757 | }; |
2758 | return values; |
2759 | } |
2760 | |
2761 | inline const char * const *EnumNamesFullyConnectedOptionsWeightsFormat() { |
2762 | static const char * const names[3] = { |
2763 | "DEFAULT" , |
2764 | "SHUFFLED4x16INT8" , |
2765 | nullptr |
2766 | }; |
2767 | return names; |
2768 | } |
2769 | |
2770 | inline const char *EnumNameFullyConnectedOptionsWeightsFormat(FullyConnectedOptionsWeightsFormat e) { |
2771 | if (flatbuffers::IsOutRange(e, FullyConnectedOptionsWeightsFormat_DEFAULT, FullyConnectedOptionsWeightsFormat_SHUFFLED4x16INT8)) return "" ; |
2772 | const size_t index = static_cast<size_t>(e); |
2773 | return EnumNamesFullyConnectedOptionsWeightsFormat()[index]; |
2774 | } |
2775 | |
2776 | enum LSTMKernelType { |
2777 | LSTMKernelType_FULL = 0, |
2778 | LSTMKernelType_BASIC = 1, |
2779 | LSTMKernelType_MIN = LSTMKernelType_FULL, |
2780 | LSTMKernelType_MAX = LSTMKernelType_BASIC |
2781 | }; |
2782 | |
2783 | inline const LSTMKernelType (&EnumValuesLSTMKernelType())[2] { |
2784 | static const LSTMKernelType values[] = { |
2785 | LSTMKernelType_FULL, |
2786 | LSTMKernelType_BASIC |
2787 | }; |
2788 | return values; |
2789 | } |
2790 | |
2791 | inline const char * const *EnumNamesLSTMKernelType() { |
2792 | static const char * const names[3] = { |
2793 | "FULL" , |
2794 | "BASIC" , |
2795 | nullptr |
2796 | }; |
2797 | return names; |
2798 | } |
2799 | |
2800 | inline const char *EnumNameLSTMKernelType(LSTMKernelType e) { |
2801 | if (flatbuffers::IsOutRange(e, LSTMKernelType_FULL, LSTMKernelType_BASIC)) return "" ; |
2802 | const size_t index = static_cast<size_t>(e); |
2803 | return EnumNamesLSTMKernelType()[index]; |
2804 | } |
2805 | |
2806 | enum CombinerType { |
2807 | CombinerType_SUM = 0, |
2808 | CombinerType_MEAN = 1, |
2809 | CombinerType_SQRTN = 2, |
2810 | CombinerType_MIN = CombinerType_SUM, |
2811 | CombinerType_MAX = CombinerType_SQRTN |
2812 | }; |
2813 | |
2814 | inline const CombinerType (&EnumValuesCombinerType())[3] { |
2815 | static const CombinerType values[] = { |
2816 | CombinerType_SUM, |
2817 | CombinerType_MEAN, |
2818 | CombinerType_SQRTN |
2819 | }; |
2820 | return values; |
2821 | } |
2822 | |
2823 | inline const char * const *EnumNamesCombinerType() { |
2824 | static const char * const names[4] = { |
2825 | "SUM" , |
2826 | "MEAN" , |
2827 | "SQRTN" , |
2828 | nullptr |
2829 | }; |
2830 | return names; |
2831 | } |
2832 | |
2833 | inline const char *EnumNameCombinerType(CombinerType e) { |
2834 | if (flatbuffers::IsOutRange(e, CombinerType_SUM, CombinerType_SQRTN)) return "" ; |
2835 | const size_t index = static_cast<size_t>(e); |
2836 | return EnumNamesCombinerType()[index]; |
2837 | } |
2838 | |
2839 | enum MirrorPadMode { |
2840 | MirrorPadMode_REFLECT = 0, |
2841 | MirrorPadMode_SYMMETRIC = 1, |
2842 | MirrorPadMode_MIN = MirrorPadMode_REFLECT, |
2843 | MirrorPadMode_MAX = MirrorPadMode_SYMMETRIC |
2844 | }; |
2845 | |
2846 | inline const MirrorPadMode (&EnumValuesMirrorPadMode())[2] { |
2847 | static const MirrorPadMode values[] = { |
2848 | MirrorPadMode_REFLECT, |
2849 | MirrorPadMode_SYMMETRIC |
2850 | }; |
2851 | return values; |
2852 | } |
2853 | |
2854 | inline const char * const *EnumNamesMirrorPadMode() { |
2855 | static const char * const names[3] = { |
2856 | "REFLECT" , |
2857 | "SYMMETRIC" , |
2858 | nullptr |
2859 | }; |
2860 | return names; |
2861 | } |
2862 | |
2863 | inline const char *EnumNameMirrorPadMode(MirrorPadMode e) { |
2864 | if (flatbuffers::IsOutRange(e, MirrorPadMode_REFLECT, MirrorPadMode_SYMMETRIC)) return "" ; |
2865 | const size_t index = static_cast<size_t>(e); |
2866 | return EnumNamesMirrorPadMode()[index]; |
2867 | } |
2868 | |
2869 | enum CustomOptionsFormat { |
2870 | CustomOptionsFormat_FLEXBUFFERS = 0, |
2871 | CustomOptionsFormat_MIN = CustomOptionsFormat_FLEXBUFFERS, |
2872 | CustomOptionsFormat_MAX = CustomOptionsFormat_FLEXBUFFERS |
2873 | }; |
2874 | |
2875 | inline const CustomOptionsFormat (&EnumValuesCustomOptionsFormat())[1] { |
2876 | static const CustomOptionsFormat values[] = { |
2877 | CustomOptionsFormat_FLEXBUFFERS |
2878 | }; |
2879 | return values; |
2880 | } |
2881 | |
2882 | inline const char * const *EnumNamesCustomOptionsFormat() { |
2883 | static const char * const names[2] = { |
2884 | "FLEXBUFFERS" , |
2885 | nullptr |
2886 | }; |
2887 | return names; |
2888 | } |
2889 | |
2890 | inline const char *EnumNameCustomOptionsFormat(CustomOptionsFormat e) { |
2891 | if (flatbuffers::IsOutRange(e, CustomOptionsFormat_FLEXBUFFERS, CustomOptionsFormat_FLEXBUFFERS)) return "" ; |
2892 | const size_t index = static_cast<size_t>(e); |
2893 | return EnumNamesCustomOptionsFormat()[index]; |
2894 | } |
2895 | |
2896 | struct CustomQuantizationT : public flatbuffers::NativeTable { |
2897 | typedef CustomQuantization TableType; |
2898 | std::vector<uint8_t> custom; |
2899 | CustomQuantizationT() { |
2900 | } |
2901 | }; |
2902 | |
2903 | struct CustomQuantization FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
2904 | typedef CustomQuantizationT NativeTableType; |
2905 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
2906 | VT_CUSTOM = 4 |
2907 | }; |
2908 | const flatbuffers::Vector<uint8_t> *custom() const { |
2909 | return GetPointer<const flatbuffers::Vector<uint8_t> *>(VT_CUSTOM); |
2910 | } |
2911 | bool Verify(flatbuffers::Verifier &verifier) const { |
2912 | return VerifyTableStart(verifier) && |
2913 | VerifyOffset(verifier, VT_CUSTOM) && |
2914 | verifier.VerifyVector(custom()) && |
2915 | verifier.EndTable(); |
2916 | } |
2917 | CustomQuantizationT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
2918 | void UnPackTo(CustomQuantizationT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
2919 | static flatbuffers::Offset<CustomQuantization> Pack(flatbuffers::FlatBufferBuilder &_fbb, const CustomQuantizationT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
2920 | }; |
2921 | |
2922 | struct CustomQuantizationBuilder { |
2923 | flatbuffers::FlatBufferBuilder &fbb_; |
2924 | flatbuffers::uoffset_t start_; |
2925 | void add_custom(flatbuffers::Offset<flatbuffers::Vector<uint8_t>> custom) { |
2926 | fbb_.AddOffset(CustomQuantization::VT_CUSTOM, custom); |
2927 | } |
2928 | explicit CustomQuantizationBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
2929 | : fbb_(_fbb) { |
2930 | start_ = fbb_.StartTable(); |
2931 | } |
2932 | CustomQuantizationBuilder &operator=(const CustomQuantizationBuilder &); |
2933 | flatbuffers::Offset<CustomQuantization> Finish() { |
2934 | const auto end = fbb_.EndTable(start_); |
2935 | auto o = flatbuffers::Offset<CustomQuantization>(end); |
2936 | return o; |
2937 | } |
2938 | }; |
2939 | |
2940 | inline flatbuffers::Offset<CustomQuantization> CreateCustomQuantization( |
2941 | flatbuffers::FlatBufferBuilder &_fbb, |
2942 | flatbuffers::Offset<flatbuffers::Vector<uint8_t>> custom = 0) { |
2943 | CustomQuantizationBuilder builder_(_fbb); |
2944 | builder_.add_custom(custom); |
2945 | return builder_.Finish(); |
2946 | } |
2947 | |
2948 | inline flatbuffers::Offset<CustomQuantization> CreateCustomQuantizationDirect( |
2949 | flatbuffers::FlatBufferBuilder &_fbb, |
2950 | const std::vector<uint8_t> *custom = nullptr) { |
2951 | if (custom) { _fbb.ForceVectorAlignment(custom->size(), sizeof(uint8_t), 16); } |
2952 | auto custom__ = custom ? _fbb.CreateVector<uint8_t>(*custom) : 0; |
2953 | return tflite::CreateCustomQuantization( |
2954 | _fbb, |
2955 | custom__); |
2956 | } |
2957 | |
2958 | flatbuffers::Offset<CustomQuantization> CreateCustomQuantization(flatbuffers::FlatBufferBuilder &_fbb, const CustomQuantizationT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
2959 | |
2960 | struct QuantizationParametersT : public flatbuffers::NativeTable { |
2961 | typedef QuantizationParameters TableType; |
2962 | std::vector<float> min; |
2963 | std::vector<float> max; |
2964 | std::vector<float> scale; |
2965 | std::vector<int64_t> zero_point; |
2966 | tflite::QuantizationDetailsUnion details; |
2967 | int32_t quantized_dimension; |
2968 | QuantizationParametersT() |
2969 | : quantized_dimension(0) { |
2970 | } |
2971 | }; |
2972 | |
2973 | struct QuantizationParameters FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
2974 | typedef QuantizationParametersT NativeTableType; |
2975 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
2976 | VT_MIN = 4, |
2977 | VT_MAX = 6, |
2978 | VT_SCALE = 8, |
2979 | VT_ZERO_POINT = 10, |
2980 | VT_DETAILS_TYPE = 12, |
2981 | VT_DETAILS = 14, |
2982 | VT_QUANTIZED_DIMENSION = 16 |
2983 | }; |
2984 | const flatbuffers::Vector<float> *min() const { |
2985 | return GetPointer<const flatbuffers::Vector<float> *>(VT_MIN); |
2986 | } |
2987 | const flatbuffers::Vector<float> *max() const { |
2988 | return GetPointer<const flatbuffers::Vector<float> *>(VT_MAX); |
2989 | } |
2990 | const flatbuffers::Vector<float> *scale() const { |
2991 | return GetPointer<const flatbuffers::Vector<float> *>(VT_SCALE); |
2992 | } |
2993 | const flatbuffers::Vector<int64_t> *zero_point() const { |
2994 | return GetPointer<const flatbuffers::Vector<int64_t> *>(VT_ZERO_POINT); |
2995 | } |
2996 | tflite::QuantizationDetails details_type() const { |
2997 | return static_cast<tflite::QuantizationDetails>(GetField<uint8_t>(VT_DETAILS_TYPE, 0)); |
2998 | } |
2999 | const void *details() const { |
3000 | return GetPointer<const void *>(VT_DETAILS); |
3001 | } |
3002 | template<typename T> const T *details_as() const; |
3003 | const tflite::CustomQuantization *details_as_CustomQuantization() const { |
3004 | return details_type() == tflite::QuantizationDetails_CustomQuantization ? static_cast<const tflite::CustomQuantization *>(details()) : nullptr; |
3005 | } |
3006 | int32_t quantized_dimension() const { |
3007 | return GetField<int32_t>(VT_QUANTIZED_DIMENSION, 0); |
3008 | } |
3009 | bool Verify(flatbuffers::Verifier &verifier) const { |
3010 | return VerifyTableStart(verifier) && |
3011 | VerifyOffset(verifier, VT_MIN) && |
3012 | verifier.VerifyVector(min()) && |
3013 | VerifyOffset(verifier, VT_MAX) && |
3014 | verifier.VerifyVector(max()) && |
3015 | VerifyOffset(verifier, VT_SCALE) && |
3016 | verifier.VerifyVector(scale()) && |
3017 | VerifyOffset(verifier, VT_ZERO_POINT) && |
3018 | verifier.VerifyVector(zero_point()) && |
3019 | VerifyField<uint8_t>(verifier, VT_DETAILS_TYPE) && |
3020 | VerifyOffset(verifier, VT_DETAILS) && |
3021 | VerifyQuantizationDetails(verifier, details(), details_type()) && |
3022 | VerifyField<int32_t>(verifier, VT_QUANTIZED_DIMENSION) && |
3023 | verifier.EndTable(); |
3024 | } |
3025 | QuantizationParametersT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3026 | void UnPackTo(QuantizationParametersT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3027 | static flatbuffers::Offset<QuantizationParameters> Pack(flatbuffers::FlatBufferBuilder &_fbb, const QuantizationParametersT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3028 | }; |
3029 | |
3030 | template<> inline const tflite::CustomQuantization *QuantizationParameters::details_as<tflite::CustomQuantization>() const { |
3031 | return details_as_CustomQuantization(); |
3032 | } |
3033 | |
3034 | struct QuantizationParametersBuilder { |
3035 | flatbuffers::FlatBufferBuilder &fbb_; |
3036 | flatbuffers::uoffset_t start_; |
3037 | void add_min(flatbuffers::Offset<flatbuffers::Vector<float>> min) { |
3038 | fbb_.AddOffset(QuantizationParameters::VT_MIN, min); |
3039 | } |
3040 | void add_max(flatbuffers::Offset<flatbuffers::Vector<float>> max) { |
3041 | fbb_.AddOffset(QuantizationParameters::VT_MAX, max); |
3042 | } |
3043 | void add_scale(flatbuffers::Offset<flatbuffers::Vector<float>> scale) { |
3044 | fbb_.AddOffset(QuantizationParameters::VT_SCALE, scale); |
3045 | } |
3046 | void add_zero_point(flatbuffers::Offset<flatbuffers::Vector<int64_t>> zero_point) { |
3047 | fbb_.AddOffset(QuantizationParameters::VT_ZERO_POINT, zero_point); |
3048 | } |
3049 | void add_details_type(tflite::QuantizationDetails details_type) { |
3050 | fbb_.AddElement<uint8_t>(QuantizationParameters::VT_DETAILS_TYPE, static_cast<uint8_t>(details_type), 0); |
3051 | } |
3052 | void add_details(flatbuffers::Offset<void> details) { |
3053 | fbb_.AddOffset(QuantizationParameters::VT_DETAILS, details); |
3054 | } |
3055 | void add_quantized_dimension(int32_t quantized_dimension) { |
3056 | fbb_.AddElement<int32_t>(QuantizationParameters::VT_QUANTIZED_DIMENSION, quantized_dimension, 0); |
3057 | } |
3058 | explicit QuantizationParametersBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3059 | : fbb_(_fbb) { |
3060 | start_ = fbb_.StartTable(); |
3061 | } |
3062 | QuantizationParametersBuilder &operator=(const QuantizationParametersBuilder &); |
3063 | flatbuffers::Offset<QuantizationParameters> Finish() { |
3064 | const auto end = fbb_.EndTable(start_); |
3065 | auto o = flatbuffers::Offset<QuantizationParameters>(end); |
3066 | return o; |
3067 | } |
3068 | }; |
3069 | |
3070 | inline flatbuffers::Offset<QuantizationParameters> CreateQuantizationParameters( |
3071 | flatbuffers::FlatBufferBuilder &_fbb, |
3072 | flatbuffers::Offset<flatbuffers::Vector<float>> min = 0, |
3073 | flatbuffers::Offset<flatbuffers::Vector<float>> max = 0, |
3074 | flatbuffers::Offset<flatbuffers::Vector<float>> scale = 0, |
3075 | flatbuffers::Offset<flatbuffers::Vector<int64_t>> zero_point = 0, |
3076 | tflite::QuantizationDetails details_type = tflite::QuantizationDetails_NONE, |
3077 | flatbuffers::Offset<void> details = 0, |
3078 | int32_t quantized_dimension = 0) { |
3079 | QuantizationParametersBuilder builder_(_fbb); |
3080 | builder_.add_quantized_dimension(quantized_dimension); |
3081 | builder_.add_details(details); |
3082 | builder_.add_zero_point(zero_point); |
3083 | builder_.add_scale(scale); |
3084 | builder_.add_max(max); |
3085 | builder_.add_min(min); |
3086 | builder_.add_details_type(details_type); |
3087 | return builder_.Finish(); |
3088 | } |
3089 | |
3090 | inline flatbuffers::Offset<QuantizationParameters> CreateQuantizationParametersDirect( |
3091 | flatbuffers::FlatBufferBuilder &_fbb, |
3092 | const std::vector<float> *min = nullptr, |
3093 | const std::vector<float> *max = nullptr, |
3094 | const std::vector<float> *scale = nullptr, |
3095 | const std::vector<int64_t> *zero_point = nullptr, |
3096 | tflite::QuantizationDetails details_type = tflite::QuantizationDetails_NONE, |
3097 | flatbuffers::Offset<void> details = 0, |
3098 | int32_t quantized_dimension = 0) { |
3099 | auto min__ = min ? _fbb.CreateVector<float>(*min) : 0; |
3100 | auto max__ = max ? _fbb.CreateVector<float>(*max) : 0; |
3101 | auto scale__ = scale ? _fbb.CreateVector<float>(*scale) : 0; |
3102 | auto zero_point__ = zero_point ? _fbb.CreateVector<int64_t>(*zero_point) : 0; |
3103 | return tflite::CreateQuantizationParameters( |
3104 | _fbb, |
3105 | min__, |
3106 | max__, |
3107 | scale__, |
3108 | zero_point__, |
3109 | details_type, |
3110 | details, |
3111 | quantized_dimension); |
3112 | } |
3113 | |
3114 | flatbuffers::Offset<QuantizationParameters> CreateQuantizationParameters(flatbuffers::FlatBufferBuilder &_fbb, const QuantizationParametersT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3115 | |
3116 | struct Int32VectorT : public flatbuffers::NativeTable { |
3117 | typedef Int32Vector TableType; |
3118 | std::vector<int32_t> values; |
3119 | Int32VectorT() { |
3120 | } |
3121 | }; |
3122 | |
3123 | struct Int32Vector FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3124 | typedef Int32VectorT NativeTableType; |
3125 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3126 | VT_VALUES = 4 |
3127 | }; |
3128 | const flatbuffers::Vector<int32_t> *values() const { |
3129 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_VALUES); |
3130 | } |
3131 | bool Verify(flatbuffers::Verifier &verifier) const { |
3132 | return VerifyTableStart(verifier) && |
3133 | VerifyOffset(verifier, VT_VALUES) && |
3134 | verifier.VerifyVector(values()) && |
3135 | verifier.EndTable(); |
3136 | } |
3137 | Int32VectorT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3138 | void UnPackTo(Int32VectorT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3139 | static flatbuffers::Offset<Int32Vector> Pack(flatbuffers::FlatBufferBuilder &_fbb, const Int32VectorT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3140 | }; |
3141 | |
3142 | struct Int32VectorBuilder { |
3143 | flatbuffers::FlatBufferBuilder &fbb_; |
3144 | flatbuffers::uoffset_t start_; |
3145 | void add_values(flatbuffers::Offset<flatbuffers::Vector<int32_t>> values) { |
3146 | fbb_.AddOffset(Int32Vector::VT_VALUES, values); |
3147 | } |
3148 | explicit Int32VectorBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3149 | : fbb_(_fbb) { |
3150 | start_ = fbb_.StartTable(); |
3151 | } |
3152 | Int32VectorBuilder &operator=(const Int32VectorBuilder &); |
3153 | flatbuffers::Offset<Int32Vector> Finish() { |
3154 | const auto end = fbb_.EndTable(start_); |
3155 | auto o = flatbuffers::Offset<Int32Vector>(end); |
3156 | return o; |
3157 | } |
3158 | }; |
3159 | |
3160 | inline flatbuffers::Offset<Int32Vector> CreateInt32Vector( |
3161 | flatbuffers::FlatBufferBuilder &_fbb, |
3162 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> values = 0) { |
3163 | Int32VectorBuilder builder_(_fbb); |
3164 | builder_.add_values(values); |
3165 | return builder_.Finish(); |
3166 | } |
3167 | |
3168 | inline flatbuffers::Offset<Int32Vector> CreateInt32VectorDirect( |
3169 | flatbuffers::FlatBufferBuilder &_fbb, |
3170 | const std::vector<int32_t> *values = nullptr) { |
3171 | auto values__ = values ? _fbb.CreateVector<int32_t>(*values) : 0; |
3172 | return tflite::CreateInt32Vector( |
3173 | _fbb, |
3174 | values__); |
3175 | } |
3176 | |
3177 | flatbuffers::Offset<Int32Vector> CreateInt32Vector(flatbuffers::FlatBufferBuilder &_fbb, const Int32VectorT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3178 | |
3179 | struct Uint16VectorT : public flatbuffers::NativeTable { |
3180 | typedef Uint16Vector TableType; |
3181 | std::vector<uint16_t> values; |
3182 | Uint16VectorT() { |
3183 | } |
3184 | }; |
3185 | |
3186 | struct Uint16Vector FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3187 | typedef Uint16VectorT NativeTableType; |
3188 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3189 | VT_VALUES = 4 |
3190 | }; |
3191 | const flatbuffers::Vector<uint16_t> *values() const { |
3192 | return GetPointer<const flatbuffers::Vector<uint16_t> *>(VT_VALUES); |
3193 | } |
3194 | bool Verify(flatbuffers::Verifier &verifier) const { |
3195 | return VerifyTableStart(verifier) && |
3196 | VerifyOffset(verifier, VT_VALUES) && |
3197 | verifier.VerifyVector(values()) && |
3198 | verifier.EndTable(); |
3199 | } |
3200 | Uint16VectorT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3201 | void UnPackTo(Uint16VectorT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3202 | static flatbuffers::Offset<Uint16Vector> Pack(flatbuffers::FlatBufferBuilder &_fbb, const Uint16VectorT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3203 | }; |
3204 | |
3205 | struct Uint16VectorBuilder { |
3206 | flatbuffers::FlatBufferBuilder &fbb_; |
3207 | flatbuffers::uoffset_t start_; |
3208 | void add_values(flatbuffers::Offset<flatbuffers::Vector<uint16_t>> values) { |
3209 | fbb_.AddOffset(Uint16Vector::VT_VALUES, values); |
3210 | } |
3211 | explicit Uint16VectorBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3212 | : fbb_(_fbb) { |
3213 | start_ = fbb_.StartTable(); |
3214 | } |
3215 | Uint16VectorBuilder &operator=(const Uint16VectorBuilder &); |
3216 | flatbuffers::Offset<Uint16Vector> Finish() { |
3217 | const auto end = fbb_.EndTable(start_); |
3218 | auto o = flatbuffers::Offset<Uint16Vector>(end); |
3219 | return o; |
3220 | } |
3221 | }; |
3222 | |
3223 | inline flatbuffers::Offset<Uint16Vector> CreateUint16Vector( |
3224 | flatbuffers::FlatBufferBuilder &_fbb, |
3225 | flatbuffers::Offset<flatbuffers::Vector<uint16_t>> values = 0) { |
3226 | Uint16VectorBuilder builder_(_fbb); |
3227 | builder_.add_values(values); |
3228 | return builder_.Finish(); |
3229 | } |
3230 | |
3231 | inline flatbuffers::Offset<Uint16Vector> CreateUint16VectorDirect( |
3232 | flatbuffers::FlatBufferBuilder &_fbb, |
3233 | const std::vector<uint16_t> *values = nullptr) { |
3234 | if (values) { _fbb.ForceVectorAlignment(values->size(), sizeof(uint16_t), 4); } |
3235 | auto values__ = values ? _fbb.CreateVector<uint16_t>(*values) : 0; |
3236 | return tflite::CreateUint16Vector( |
3237 | _fbb, |
3238 | values__); |
3239 | } |
3240 | |
3241 | flatbuffers::Offset<Uint16Vector> CreateUint16Vector(flatbuffers::FlatBufferBuilder &_fbb, const Uint16VectorT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3242 | |
3243 | struct Uint8VectorT : public flatbuffers::NativeTable { |
3244 | typedef Uint8Vector TableType; |
3245 | std::vector<uint8_t> values; |
3246 | Uint8VectorT() { |
3247 | } |
3248 | }; |
3249 | |
3250 | struct Uint8Vector FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3251 | typedef Uint8VectorT NativeTableType; |
3252 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3253 | VT_VALUES = 4 |
3254 | }; |
3255 | const flatbuffers::Vector<uint8_t> *values() const { |
3256 | return GetPointer<const flatbuffers::Vector<uint8_t> *>(VT_VALUES); |
3257 | } |
3258 | bool Verify(flatbuffers::Verifier &verifier) const { |
3259 | return VerifyTableStart(verifier) && |
3260 | VerifyOffset(verifier, VT_VALUES) && |
3261 | verifier.VerifyVector(values()) && |
3262 | verifier.EndTable(); |
3263 | } |
3264 | Uint8VectorT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3265 | void UnPackTo(Uint8VectorT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3266 | static flatbuffers::Offset<Uint8Vector> Pack(flatbuffers::FlatBufferBuilder &_fbb, const Uint8VectorT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3267 | }; |
3268 | |
3269 | struct Uint8VectorBuilder { |
3270 | flatbuffers::FlatBufferBuilder &fbb_; |
3271 | flatbuffers::uoffset_t start_; |
3272 | void add_values(flatbuffers::Offset<flatbuffers::Vector<uint8_t>> values) { |
3273 | fbb_.AddOffset(Uint8Vector::VT_VALUES, values); |
3274 | } |
3275 | explicit Uint8VectorBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3276 | : fbb_(_fbb) { |
3277 | start_ = fbb_.StartTable(); |
3278 | } |
3279 | Uint8VectorBuilder &operator=(const Uint8VectorBuilder &); |
3280 | flatbuffers::Offset<Uint8Vector> Finish() { |
3281 | const auto end = fbb_.EndTable(start_); |
3282 | auto o = flatbuffers::Offset<Uint8Vector>(end); |
3283 | return o; |
3284 | } |
3285 | }; |
3286 | |
3287 | inline flatbuffers::Offset<Uint8Vector> CreateUint8Vector( |
3288 | flatbuffers::FlatBufferBuilder &_fbb, |
3289 | flatbuffers::Offset<flatbuffers::Vector<uint8_t>> values = 0) { |
3290 | Uint8VectorBuilder builder_(_fbb); |
3291 | builder_.add_values(values); |
3292 | return builder_.Finish(); |
3293 | } |
3294 | |
3295 | inline flatbuffers::Offset<Uint8Vector> CreateUint8VectorDirect( |
3296 | flatbuffers::FlatBufferBuilder &_fbb, |
3297 | const std::vector<uint8_t> *values = nullptr) { |
3298 | if (values) { _fbb.ForceVectorAlignment(values->size(), sizeof(uint8_t), 4); } |
3299 | auto values__ = values ? _fbb.CreateVector<uint8_t>(*values) : 0; |
3300 | return tflite::CreateUint8Vector( |
3301 | _fbb, |
3302 | values__); |
3303 | } |
3304 | |
3305 | flatbuffers::Offset<Uint8Vector> CreateUint8Vector(flatbuffers::FlatBufferBuilder &_fbb, const Uint8VectorT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3306 | |
3307 | struct DimensionMetadataT : public flatbuffers::NativeTable { |
3308 | typedef DimensionMetadata TableType; |
3309 | tflite::DimensionType format; |
3310 | int32_t dense_size; |
3311 | tflite::SparseIndexVectorUnion array_segments; |
3312 | tflite::SparseIndexVectorUnion array_indices; |
3313 | DimensionMetadataT() |
3314 | : format(tflite::DimensionType_DENSE), |
3315 | dense_size(0) { |
3316 | } |
3317 | }; |
3318 | |
3319 | struct DimensionMetadata FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3320 | typedef DimensionMetadataT NativeTableType; |
3321 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3322 | VT_FORMAT = 4, |
3323 | VT_DENSE_SIZE = 6, |
3324 | VT_ARRAY_SEGMENTS_TYPE = 8, |
3325 | VT_ARRAY_SEGMENTS = 10, |
3326 | VT_ARRAY_INDICES_TYPE = 12, |
3327 | VT_ARRAY_INDICES = 14 |
3328 | }; |
3329 | tflite::DimensionType format() const { |
3330 | return static_cast<tflite::DimensionType>(GetField<int8_t>(VT_FORMAT, 0)); |
3331 | } |
3332 | int32_t dense_size() const { |
3333 | return GetField<int32_t>(VT_DENSE_SIZE, 0); |
3334 | } |
3335 | tflite::SparseIndexVector array_segments_type() const { |
3336 | return static_cast<tflite::SparseIndexVector>(GetField<uint8_t>(VT_ARRAY_SEGMENTS_TYPE, 0)); |
3337 | } |
3338 | const void *array_segments() const { |
3339 | return GetPointer<const void *>(VT_ARRAY_SEGMENTS); |
3340 | } |
3341 | template<typename T> const T *array_segments_as() const; |
3342 | const tflite::Int32Vector *array_segments_as_Int32Vector() const { |
3343 | return array_segments_type() == tflite::SparseIndexVector_Int32Vector ? static_cast<const tflite::Int32Vector *>(array_segments()) : nullptr; |
3344 | } |
3345 | const tflite::Uint16Vector *array_segments_as_Uint16Vector() const { |
3346 | return array_segments_type() == tflite::SparseIndexVector_Uint16Vector ? static_cast<const tflite::Uint16Vector *>(array_segments()) : nullptr; |
3347 | } |
3348 | const tflite::Uint8Vector *array_segments_as_Uint8Vector() const { |
3349 | return array_segments_type() == tflite::SparseIndexVector_Uint8Vector ? static_cast<const tflite::Uint8Vector *>(array_segments()) : nullptr; |
3350 | } |
3351 | tflite::SparseIndexVector array_indices_type() const { |
3352 | return static_cast<tflite::SparseIndexVector>(GetField<uint8_t>(VT_ARRAY_INDICES_TYPE, 0)); |
3353 | } |
3354 | const void *array_indices() const { |
3355 | return GetPointer<const void *>(VT_ARRAY_INDICES); |
3356 | } |
3357 | template<typename T> const T *array_indices_as() const; |
3358 | const tflite::Int32Vector *array_indices_as_Int32Vector() const { |
3359 | return array_indices_type() == tflite::SparseIndexVector_Int32Vector ? static_cast<const tflite::Int32Vector *>(array_indices()) : nullptr; |
3360 | } |
3361 | const tflite::Uint16Vector *array_indices_as_Uint16Vector() const { |
3362 | return array_indices_type() == tflite::SparseIndexVector_Uint16Vector ? static_cast<const tflite::Uint16Vector *>(array_indices()) : nullptr; |
3363 | } |
3364 | const tflite::Uint8Vector *array_indices_as_Uint8Vector() const { |
3365 | return array_indices_type() == tflite::SparseIndexVector_Uint8Vector ? static_cast<const tflite::Uint8Vector *>(array_indices()) : nullptr; |
3366 | } |
3367 | bool Verify(flatbuffers::Verifier &verifier) const { |
3368 | return VerifyTableStart(verifier) && |
3369 | VerifyField<int8_t>(verifier, VT_FORMAT) && |
3370 | VerifyField<int32_t>(verifier, VT_DENSE_SIZE) && |
3371 | VerifyField<uint8_t>(verifier, VT_ARRAY_SEGMENTS_TYPE) && |
3372 | VerifyOffset(verifier, VT_ARRAY_SEGMENTS) && |
3373 | VerifySparseIndexVector(verifier, array_segments(), array_segments_type()) && |
3374 | VerifyField<uint8_t>(verifier, VT_ARRAY_INDICES_TYPE) && |
3375 | VerifyOffset(verifier, VT_ARRAY_INDICES) && |
3376 | VerifySparseIndexVector(verifier, array_indices(), array_indices_type()) && |
3377 | verifier.EndTable(); |
3378 | } |
3379 | DimensionMetadataT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3380 | void UnPackTo(DimensionMetadataT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3381 | static flatbuffers::Offset<DimensionMetadata> Pack(flatbuffers::FlatBufferBuilder &_fbb, const DimensionMetadataT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3382 | }; |
3383 | |
3384 | template<> inline const tflite::Int32Vector *DimensionMetadata::array_segments_as<tflite::Int32Vector>() const { |
3385 | return array_segments_as_Int32Vector(); |
3386 | } |
3387 | |
3388 | template<> inline const tflite::Uint16Vector *DimensionMetadata::array_segments_as<tflite::Uint16Vector>() const { |
3389 | return array_segments_as_Uint16Vector(); |
3390 | } |
3391 | |
3392 | template<> inline const tflite::Uint8Vector *DimensionMetadata::array_segments_as<tflite::Uint8Vector>() const { |
3393 | return array_segments_as_Uint8Vector(); |
3394 | } |
3395 | |
3396 | template<> inline const tflite::Int32Vector *DimensionMetadata::array_indices_as<tflite::Int32Vector>() const { |
3397 | return array_indices_as_Int32Vector(); |
3398 | } |
3399 | |
3400 | template<> inline const tflite::Uint16Vector *DimensionMetadata::array_indices_as<tflite::Uint16Vector>() const { |
3401 | return array_indices_as_Uint16Vector(); |
3402 | } |
3403 | |
3404 | template<> inline const tflite::Uint8Vector *DimensionMetadata::array_indices_as<tflite::Uint8Vector>() const { |
3405 | return array_indices_as_Uint8Vector(); |
3406 | } |
3407 | |
3408 | struct DimensionMetadataBuilder { |
3409 | flatbuffers::FlatBufferBuilder &fbb_; |
3410 | flatbuffers::uoffset_t start_; |
3411 | void add_format(tflite::DimensionType format) { |
3412 | fbb_.AddElement<int8_t>(DimensionMetadata::VT_FORMAT, static_cast<int8_t>(format), 0); |
3413 | } |
3414 | void add_dense_size(int32_t dense_size) { |
3415 | fbb_.AddElement<int32_t>(DimensionMetadata::VT_DENSE_SIZE, dense_size, 0); |
3416 | } |
3417 | void add_array_segments_type(tflite::SparseIndexVector array_segments_type) { |
3418 | fbb_.AddElement<uint8_t>(DimensionMetadata::VT_ARRAY_SEGMENTS_TYPE, static_cast<uint8_t>(array_segments_type), 0); |
3419 | } |
3420 | void add_array_segments(flatbuffers::Offset<void> array_segments) { |
3421 | fbb_.AddOffset(DimensionMetadata::VT_ARRAY_SEGMENTS, array_segments); |
3422 | } |
3423 | void add_array_indices_type(tflite::SparseIndexVector array_indices_type) { |
3424 | fbb_.AddElement<uint8_t>(DimensionMetadata::VT_ARRAY_INDICES_TYPE, static_cast<uint8_t>(array_indices_type), 0); |
3425 | } |
3426 | void add_array_indices(flatbuffers::Offset<void> array_indices) { |
3427 | fbb_.AddOffset(DimensionMetadata::VT_ARRAY_INDICES, array_indices); |
3428 | } |
3429 | explicit DimensionMetadataBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3430 | : fbb_(_fbb) { |
3431 | start_ = fbb_.StartTable(); |
3432 | } |
3433 | DimensionMetadataBuilder &operator=(const DimensionMetadataBuilder &); |
3434 | flatbuffers::Offset<DimensionMetadata> Finish() { |
3435 | const auto end = fbb_.EndTable(start_); |
3436 | auto o = flatbuffers::Offset<DimensionMetadata>(end); |
3437 | return o; |
3438 | } |
3439 | }; |
3440 | |
3441 | inline flatbuffers::Offset<DimensionMetadata> CreateDimensionMetadata( |
3442 | flatbuffers::FlatBufferBuilder &_fbb, |
3443 | tflite::DimensionType format = tflite::DimensionType_DENSE, |
3444 | int32_t dense_size = 0, |
3445 | tflite::SparseIndexVector array_segments_type = tflite::SparseIndexVector_NONE, |
3446 | flatbuffers::Offset<void> array_segments = 0, |
3447 | tflite::SparseIndexVector array_indices_type = tflite::SparseIndexVector_NONE, |
3448 | flatbuffers::Offset<void> array_indices = 0) { |
3449 | DimensionMetadataBuilder builder_(_fbb); |
3450 | builder_.add_array_indices(array_indices); |
3451 | builder_.add_array_segments(array_segments); |
3452 | builder_.add_dense_size(dense_size); |
3453 | builder_.add_array_indices_type(array_indices_type); |
3454 | builder_.add_array_segments_type(array_segments_type); |
3455 | builder_.add_format(format); |
3456 | return builder_.Finish(); |
3457 | } |
3458 | |
3459 | flatbuffers::Offset<DimensionMetadata> CreateDimensionMetadata(flatbuffers::FlatBufferBuilder &_fbb, const DimensionMetadataT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3460 | |
3461 | struct SparsityParametersT : public flatbuffers::NativeTable { |
3462 | typedef SparsityParameters TableType; |
3463 | std::vector<int32_t> traversal_order; |
3464 | std::vector<int32_t> block_map; |
3465 | std::vector<std::unique_ptr<tflite::DimensionMetadataT>> dim_metadata; |
3466 | SparsityParametersT() { |
3467 | } |
3468 | }; |
3469 | |
3470 | struct SparsityParameters FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3471 | typedef SparsityParametersT NativeTableType; |
3472 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3473 | VT_TRAVERSAL_ORDER = 4, |
3474 | VT_BLOCK_MAP = 6, |
3475 | VT_DIM_METADATA = 8 |
3476 | }; |
3477 | const flatbuffers::Vector<int32_t> *traversal_order() const { |
3478 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_TRAVERSAL_ORDER); |
3479 | } |
3480 | const flatbuffers::Vector<int32_t> *block_map() const { |
3481 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_BLOCK_MAP); |
3482 | } |
3483 | const flatbuffers::Vector<flatbuffers::Offset<tflite::DimensionMetadata>> *dim_metadata() const { |
3484 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::DimensionMetadata>> *>(VT_DIM_METADATA); |
3485 | } |
3486 | bool Verify(flatbuffers::Verifier &verifier) const { |
3487 | return VerifyTableStart(verifier) && |
3488 | VerifyOffset(verifier, VT_TRAVERSAL_ORDER) && |
3489 | verifier.VerifyVector(traversal_order()) && |
3490 | VerifyOffset(verifier, VT_BLOCK_MAP) && |
3491 | verifier.VerifyVector(block_map()) && |
3492 | VerifyOffset(verifier, VT_DIM_METADATA) && |
3493 | verifier.VerifyVector(dim_metadata()) && |
3494 | verifier.VerifyVectorOfTables(dim_metadata()) && |
3495 | verifier.EndTable(); |
3496 | } |
3497 | SparsityParametersT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3498 | void UnPackTo(SparsityParametersT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3499 | static flatbuffers::Offset<SparsityParameters> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SparsityParametersT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3500 | }; |
3501 | |
3502 | struct SparsityParametersBuilder { |
3503 | flatbuffers::FlatBufferBuilder &fbb_; |
3504 | flatbuffers::uoffset_t start_; |
3505 | void add_traversal_order(flatbuffers::Offset<flatbuffers::Vector<int32_t>> traversal_order) { |
3506 | fbb_.AddOffset(SparsityParameters::VT_TRAVERSAL_ORDER, traversal_order); |
3507 | } |
3508 | void add_block_map(flatbuffers::Offset<flatbuffers::Vector<int32_t>> block_map) { |
3509 | fbb_.AddOffset(SparsityParameters::VT_BLOCK_MAP, block_map); |
3510 | } |
3511 | void add_dim_metadata(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::DimensionMetadata>>> dim_metadata) { |
3512 | fbb_.AddOffset(SparsityParameters::VT_DIM_METADATA, dim_metadata); |
3513 | } |
3514 | explicit SparsityParametersBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3515 | : fbb_(_fbb) { |
3516 | start_ = fbb_.StartTable(); |
3517 | } |
3518 | SparsityParametersBuilder &operator=(const SparsityParametersBuilder &); |
3519 | flatbuffers::Offset<SparsityParameters> Finish() { |
3520 | const auto end = fbb_.EndTable(start_); |
3521 | auto o = flatbuffers::Offset<SparsityParameters>(end); |
3522 | return o; |
3523 | } |
3524 | }; |
3525 | |
3526 | inline flatbuffers::Offset<SparsityParameters> CreateSparsityParameters( |
3527 | flatbuffers::FlatBufferBuilder &_fbb, |
3528 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> traversal_order = 0, |
3529 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> block_map = 0, |
3530 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::DimensionMetadata>>> dim_metadata = 0) { |
3531 | SparsityParametersBuilder builder_(_fbb); |
3532 | builder_.add_dim_metadata(dim_metadata); |
3533 | builder_.add_block_map(block_map); |
3534 | builder_.add_traversal_order(traversal_order); |
3535 | return builder_.Finish(); |
3536 | } |
3537 | |
3538 | inline flatbuffers::Offset<SparsityParameters> CreateSparsityParametersDirect( |
3539 | flatbuffers::FlatBufferBuilder &_fbb, |
3540 | const std::vector<int32_t> *traversal_order = nullptr, |
3541 | const std::vector<int32_t> *block_map = nullptr, |
3542 | const std::vector<flatbuffers::Offset<tflite::DimensionMetadata>> *dim_metadata = nullptr) { |
3543 | auto traversal_order__ = traversal_order ? _fbb.CreateVector<int32_t>(*traversal_order) : 0; |
3544 | auto block_map__ = block_map ? _fbb.CreateVector<int32_t>(*block_map) : 0; |
3545 | auto dim_metadata__ = dim_metadata ? _fbb.CreateVector<flatbuffers::Offset<tflite::DimensionMetadata>>(*dim_metadata) : 0; |
3546 | return tflite::CreateSparsityParameters( |
3547 | _fbb, |
3548 | traversal_order__, |
3549 | block_map__, |
3550 | dim_metadata__); |
3551 | } |
3552 | |
3553 | flatbuffers::Offset<SparsityParameters> CreateSparsityParameters(flatbuffers::FlatBufferBuilder &_fbb, const SparsityParametersT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3554 | |
3555 | struct TensorT : public flatbuffers::NativeTable { |
3556 | typedef Tensor TableType; |
3557 | std::vector<int32_t> shape; |
3558 | tflite::TensorType type; |
3559 | uint32_t buffer; |
3560 | std::string name; |
3561 | std::unique_ptr<tflite::QuantizationParametersT> quantization; |
3562 | bool is_variable; |
3563 | std::unique_ptr<tflite::SparsityParametersT> sparsity; |
3564 | std::vector<int32_t> shape_signature; |
3565 | TensorT() |
3566 | : type(tflite::TensorType_FLOAT32), |
3567 | buffer(0), |
3568 | is_variable(false) { |
3569 | } |
3570 | }; |
3571 | |
3572 | struct Tensor FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3573 | typedef TensorT NativeTableType; |
3574 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3575 | VT_SHAPE = 4, |
3576 | VT_TYPE = 6, |
3577 | VT_BUFFER = 8, |
3578 | VT_NAME = 10, |
3579 | VT_QUANTIZATION = 12, |
3580 | VT_IS_VARIABLE = 14, |
3581 | VT_SPARSITY = 16, |
3582 | VT_SHAPE_SIGNATURE = 18 |
3583 | }; |
3584 | const flatbuffers::Vector<int32_t> *shape() const { |
3585 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_SHAPE); |
3586 | } |
3587 | tflite::TensorType type() const { |
3588 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_TYPE, 0)); |
3589 | } |
3590 | uint32_t buffer() const { |
3591 | return GetField<uint32_t>(VT_BUFFER, 0); |
3592 | } |
3593 | const flatbuffers::String *name() const { |
3594 | return GetPointer<const flatbuffers::String *>(VT_NAME); |
3595 | } |
3596 | const tflite::QuantizationParameters *quantization() const { |
3597 | return GetPointer<const tflite::QuantizationParameters *>(VT_QUANTIZATION); |
3598 | } |
3599 | bool is_variable() const { |
3600 | return GetField<uint8_t>(VT_IS_VARIABLE, 0) != 0; |
3601 | } |
3602 | const tflite::SparsityParameters *sparsity() const { |
3603 | return GetPointer<const tflite::SparsityParameters *>(VT_SPARSITY); |
3604 | } |
3605 | const flatbuffers::Vector<int32_t> *shape_signature() const { |
3606 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_SHAPE_SIGNATURE); |
3607 | } |
3608 | bool Verify(flatbuffers::Verifier &verifier) const { |
3609 | return VerifyTableStart(verifier) && |
3610 | VerifyOffset(verifier, VT_SHAPE) && |
3611 | verifier.VerifyVector(shape()) && |
3612 | VerifyField<int8_t>(verifier, VT_TYPE) && |
3613 | VerifyField<uint32_t>(verifier, VT_BUFFER) && |
3614 | VerifyOffset(verifier, VT_NAME) && |
3615 | verifier.VerifyString(name()) && |
3616 | VerifyOffset(verifier, VT_QUANTIZATION) && |
3617 | verifier.VerifyTable(quantization()) && |
3618 | VerifyField<uint8_t>(verifier, VT_IS_VARIABLE) && |
3619 | VerifyOffset(verifier, VT_SPARSITY) && |
3620 | verifier.VerifyTable(sparsity()) && |
3621 | VerifyOffset(verifier, VT_SHAPE_SIGNATURE) && |
3622 | verifier.VerifyVector(shape_signature()) && |
3623 | verifier.EndTable(); |
3624 | } |
3625 | TensorT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3626 | void UnPackTo(TensorT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3627 | static flatbuffers::Offset<Tensor> Pack(flatbuffers::FlatBufferBuilder &_fbb, const TensorT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3628 | }; |
3629 | |
3630 | struct TensorBuilder { |
3631 | flatbuffers::FlatBufferBuilder &fbb_; |
3632 | flatbuffers::uoffset_t start_; |
3633 | void add_shape(flatbuffers::Offset<flatbuffers::Vector<int32_t>> shape) { |
3634 | fbb_.AddOffset(Tensor::VT_SHAPE, shape); |
3635 | } |
3636 | void add_type(tflite::TensorType type) { |
3637 | fbb_.AddElement<int8_t>(Tensor::VT_TYPE, static_cast<int8_t>(type), 0); |
3638 | } |
3639 | void add_buffer(uint32_t buffer) { |
3640 | fbb_.AddElement<uint32_t>(Tensor::VT_BUFFER, buffer, 0); |
3641 | } |
3642 | void add_name(flatbuffers::Offset<flatbuffers::String> name) { |
3643 | fbb_.AddOffset(Tensor::VT_NAME, name); |
3644 | } |
3645 | void add_quantization(flatbuffers::Offset<tflite::QuantizationParameters> quantization) { |
3646 | fbb_.AddOffset(Tensor::VT_QUANTIZATION, quantization); |
3647 | } |
3648 | void add_is_variable(bool is_variable) { |
3649 | fbb_.AddElement<uint8_t>(Tensor::VT_IS_VARIABLE, static_cast<uint8_t>(is_variable), 0); |
3650 | } |
3651 | void add_sparsity(flatbuffers::Offset<tflite::SparsityParameters> sparsity) { |
3652 | fbb_.AddOffset(Tensor::VT_SPARSITY, sparsity); |
3653 | } |
3654 | void add_shape_signature(flatbuffers::Offset<flatbuffers::Vector<int32_t>> shape_signature) { |
3655 | fbb_.AddOffset(Tensor::VT_SHAPE_SIGNATURE, shape_signature); |
3656 | } |
3657 | explicit TensorBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3658 | : fbb_(_fbb) { |
3659 | start_ = fbb_.StartTable(); |
3660 | } |
3661 | TensorBuilder &operator=(const TensorBuilder &); |
3662 | flatbuffers::Offset<Tensor> Finish() { |
3663 | const auto end = fbb_.EndTable(start_); |
3664 | auto o = flatbuffers::Offset<Tensor>(end); |
3665 | return o; |
3666 | } |
3667 | }; |
3668 | |
3669 | inline flatbuffers::Offset<Tensor> CreateTensor( |
3670 | flatbuffers::FlatBufferBuilder &_fbb, |
3671 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> shape = 0, |
3672 | tflite::TensorType type = tflite::TensorType_FLOAT32, |
3673 | uint32_t buffer = 0, |
3674 | flatbuffers::Offset<flatbuffers::String> name = 0, |
3675 | flatbuffers::Offset<tflite::QuantizationParameters> quantization = 0, |
3676 | bool is_variable = false, |
3677 | flatbuffers::Offset<tflite::SparsityParameters> sparsity = 0, |
3678 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> shape_signature = 0) { |
3679 | TensorBuilder builder_(_fbb); |
3680 | builder_.add_shape_signature(shape_signature); |
3681 | builder_.add_sparsity(sparsity); |
3682 | builder_.add_quantization(quantization); |
3683 | builder_.add_name(name); |
3684 | builder_.add_buffer(buffer); |
3685 | builder_.add_shape(shape); |
3686 | builder_.add_is_variable(is_variable); |
3687 | builder_.add_type(type); |
3688 | return builder_.Finish(); |
3689 | } |
3690 | |
3691 | inline flatbuffers::Offset<Tensor> CreateTensorDirect( |
3692 | flatbuffers::FlatBufferBuilder &_fbb, |
3693 | const std::vector<int32_t> *shape = nullptr, |
3694 | tflite::TensorType type = tflite::TensorType_FLOAT32, |
3695 | uint32_t buffer = 0, |
3696 | const char *name = nullptr, |
3697 | flatbuffers::Offset<tflite::QuantizationParameters> quantization = 0, |
3698 | bool is_variable = false, |
3699 | flatbuffers::Offset<tflite::SparsityParameters> sparsity = 0, |
3700 | const std::vector<int32_t> *shape_signature = nullptr) { |
3701 | auto shape__ = shape ? _fbb.CreateVector<int32_t>(*shape) : 0; |
3702 | auto name__ = name ? _fbb.CreateString(name) : 0; |
3703 | auto shape_signature__ = shape_signature ? _fbb.CreateVector<int32_t>(*shape_signature) : 0; |
3704 | return tflite::CreateTensor( |
3705 | _fbb, |
3706 | shape__, |
3707 | type, |
3708 | buffer, |
3709 | name__, |
3710 | quantization, |
3711 | is_variable, |
3712 | sparsity, |
3713 | shape_signature__); |
3714 | } |
3715 | |
3716 | flatbuffers::Offset<Tensor> CreateTensor(flatbuffers::FlatBufferBuilder &_fbb, const TensorT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3717 | |
3718 | struct Conv2DOptionsT : public flatbuffers::NativeTable { |
3719 | typedef Conv2DOptions TableType; |
3720 | tflite::Padding padding; |
3721 | int32_t stride_w; |
3722 | int32_t stride_h; |
3723 | tflite::ActivationFunctionType fused_activation_function; |
3724 | int32_t dilation_w_factor; |
3725 | int32_t dilation_h_factor; |
3726 | Conv2DOptionsT() |
3727 | : padding(tflite::Padding_SAME), |
3728 | stride_w(0), |
3729 | stride_h(0), |
3730 | fused_activation_function(tflite::ActivationFunctionType_NONE), |
3731 | dilation_w_factor(1), |
3732 | dilation_h_factor(1) { |
3733 | } |
3734 | }; |
3735 | |
3736 | struct Conv2DOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3737 | typedef Conv2DOptionsT NativeTableType; |
3738 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3739 | VT_PADDING = 4, |
3740 | VT_STRIDE_W = 6, |
3741 | VT_STRIDE_H = 8, |
3742 | VT_FUSED_ACTIVATION_FUNCTION = 10, |
3743 | VT_DILATION_W_FACTOR = 12, |
3744 | VT_DILATION_H_FACTOR = 14 |
3745 | }; |
3746 | tflite::Padding padding() const { |
3747 | return static_cast<tflite::Padding>(GetField<int8_t>(VT_PADDING, 0)); |
3748 | } |
3749 | int32_t stride_w() const { |
3750 | return GetField<int32_t>(VT_STRIDE_W, 0); |
3751 | } |
3752 | int32_t stride_h() const { |
3753 | return GetField<int32_t>(VT_STRIDE_H, 0); |
3754 | } |
3755 | tflite::ActivationFunctionType fused_activation_function() const { |
3756 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
3757 | } |
3758 | int32_t dilation_w_factor() const { |
3759 | return GetField<int32_t>(VT_DILATION_W_FACTOR, 1); |
3760 | } |
3761 | int32_t dilation_h_factor() const { |
3762 | return GetField<int32_t>(VT_DILATION_H_FACTOR, 1); |
3763 | } |
3764 | bool Verify(flatbuffers::Verifier &verifier) const { |
3765 | return VerifyTableStart(verifier) && |
3766 | VerifyField<int8_t>(verifier, VT_PADDING) && |
3767 | VerifyField<int32_t>(verifier, VT_STRIDE_W) && |
3768 | VerifyField<int32_t>(verifier, VT_STRIDE_H) && |
3769 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
3770 | VerifyField<int32_t>(verifier, VT_DILATION_W_FACTOR) && |
3771 | VerifyField<int32_t>(verifier, VT_DILATION_H_FACTOR) && |
3772 | verifier.EndTable(); |
3773 | } |
3774 | Conv2DOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3775 | void UnPackTo(Conv2DOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3776 | static flatbuffers::Offset<Conv2DOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const Conv2DOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3777 | }; |
3778 | |
3779 | struct Conv2DOptionsBuilder { |
3780 | flatbuffers::FlatBufferBuilder &fbb_; |
3781 | flatbuffers::uoffset_t start_; |
3782 | void add_padding(tflite::Padding padding) { |
3783 | fbb_.AddElement<int8_t>(Conv2DOptions::VT_PADDING, static_cast<int8_t>(padding), 0); |
3784 | } |
3785 | void add_stride_w(int32_t stride_w) { |
3786 | fbb_.AddElement<int32_t>(Conv2DOptions::VT_STRIDE_W, stride_w, 0); |
3787 | } |
3788 | void add_stride_h(int32_t stride_h) { |
3789 | fbb_.AddElement<int32_t>(Conv2DOptions::VT_STRIDE_H, stride_h, 0); |
3790 | } |
3791 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
3792 | fbb_.AddElement<int8_t>(Conv2DOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
3793 | } |
3794 | void add_dilation_w_factor(int32_t dilation_w_factor) { |
3795 | fbb_.AddElement<int32_t>(Conv2DOptions::VT_DILATION_W_FACTOR, dilation_w_factor, 1); |
3796 | } |
3797 | void add_dilation_h_factor(int32_t dilation_h_factor) { |
3798 | fbb_.AddElement<int32_t>(Conv2DOptions::VT_DILATION_H_FACTOR, dilation_h_factor, 1); |
3799 | } |
3800 | explicit Conv2DOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3801 | : fbb_(_fbb) { |
3802 | start_ = fbb_.StartTable(); |
3803 | } |
3804 | Conv2DOptionsBuilder &operator=(const Conv2DOptionsBuilder &); |
3805 | flatbuffers::Offset<Conv2DOptions> Finish() { |
3806 | const auto end = fbb_.EndTable(start_); |
3807 | auto o = flatbuffers::Offset<Conv2DOptions>(end); |
3808 | return o; |
3809 | } |
3810 | }; |
3811 | |
3812 | inline flatbuffers::Offset<Conv2DOptions> CreateConv2DOptions( |
3813 | flatbuffers::FlatBufferBuilder &_fbb, |
3814 | tflite::Padding padding = tflite::Padding_SAME, |
3815 | int32_t stride_w = 0, |
3816 | int32_t stride_h = 0, |
3817 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
3818 | int32_t dilation_w_factor = 1, |
3819 | int32_t dilation_h_factor = 1) { |
3820 | Conv2DOptionsBuilder builder_(_fbb); |
3821 | builder_.add_dilation_h_factor(dilation_h_factor); |
3822 | builder_.add_dilation_w_factor(dilation_w_factor); |
3823 | builder_.add_stride_h(stride_h); |
3824 | builder_.add_stride_w(stride_w); |
3825 | builder_.add_fused_activation_function(fused_activation_function); |
3826 | builder_.add_padding(padding); |
3827 | return builder_.Finish(); |
3828 | } |
3829 | |
3830 | flatbuffers::Offset<Conv2DOptions> CreateConv2DOptions(flatbuffers::FlatBufferBuilder &_fbb, const Conv2DOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3831 | |
3832 | struct Pool2DOptionsT : public flatbuffers::NativeTable { |
3833 | typedef Pool2DOptions TableType; |
3834 | tflite::Padding padding; |
3835 | int32_t stride_w; |
3836 | int32_t stride_h; |
3837 | int32_t filter_width; |
3838 | int32_t filter_height; |
3839 | tflite::ActivationFunctionType fused_activation_function; |
3840 | Pool2DOptionsT() |
3841 | : padding(tflite::Padding_SAME), |
3842 | stride_w(0), |
3843 | stride_h(0), |
3844 | filter_width(0), |
3845 | filter_height(0), |
3846 | fused_activation_function(tflite::ActivationFunctionType_NONE) { |
3847 | } |
3848 | }; |
3849 | |
3850 | struct Pool2DOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3851 | typedef Pool2DOptionsT NativeTableType; |
3852 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3853 | VT_PADDING = 4, |
3854 | VT_STRIDE_W = 6, |
3855 | VT_STRIDE_H = 8, |
3856 | VT_FILTER_WIDTH = 10, |
3857 | VT_FILTER_HEIGHT = 12, |
3858 | VT_FUSED_ACTIVATION_FUNCTION = 14 |
3859 | }; |
3860 | tflite::Padding padding() const { |
3861 | return static_cast<tflite::Padding>(GetField<int8_t>(VT_PADDING, 0)); |
3862 | } |
3863 | int32_t stride_w() const { |
3864 | return GetField<int32_t>(VT_STRIDE_W, 0); |
3865 | } |
3866 | int32_t stride_h() const { |
3867 | return GetField<int32_t>(VT_STRIDE_H, 0); |
3868 | } |
3869 | int32_t filter_width() const { |
3870 | return GetField<int32_t>(VT_FILTER_WIDTH, 0); |
3871 | } |
3872 | int32_t filter_height() const { |
3873 | return GetField<int32_t>(VT_FILTER_HEIGHT, 0); |
3874 | } |
3875 | tflite::ActivationFunctionType fused_activation_function() const { |
3876 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
3877 | } |
3878 | bool Verify(flatbuffers::Verifier &verifier) const { |
3879 | return VerifyTableStart(verifier) && |
3880 | VerifyField<int8_t>(verifier, VT_PADDING) && |
3881 | VerifyField<int32_t>(verifier, VT_STRIDE_W) && |
3882 | VerifyField<int32_t>(verifier, VT_STRIDE_H) && |
3883 | VerifyField<int32_t>(verifier, VT_FILTER_WIDTH) && |
3884 | VerifyField<int32_t>(verifier, VT_FILTER_HEIGHT) && |
3885 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
3886 | verifier.EndTable(); |
3887 | } |
3888 | Pool2DOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3889 | void UnPackTo(Pool2DOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
3890 | static flatbuffers::Offset<Pool2DOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const Pool2DOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3891 | }; |
3892 | |
3893 | struct Pool2DOptionsBuilder { |
3894 | flatbuffers::FlatBufferBuilder &fbb_; |
3895 | flatbuffers::uoffset_t start_; |
3896 | void add_padding(tflite::Padding padding) { |
3897 | fbb_.AddElement<int8_t>(Pool2DOptions::VT_PADDING, static_cast<int8_t>(padding), 0); |
3898 | } |
3899 | void add_stride_w(int32_t stride_w) { |
3900 | fbb_.AddElement<int32_t>(Pool2DOptions::VT_STRIDE_W, stride_w, 0); |
3901 | } |
3902 | void add_stride_h(int32_t stride_h) { |
3903 | fbb_.AddElement<int32_t>(Pool2DOptions::VT_STRIDE_H, stride_h, 0); |
3904 | } |
3905 | void add_filter_width(int32_t filter_width) { |
3906 | fbb_.AddElement<int32_t>(Pool2DOptions::VT_FILTER_WIDTH, filter_width, 0); |
3907 | } |
3908 | void add_filter_height(int32_t filter_height) { |
3909 | fbb_.AddElement<int32_t>(Pool2DOptions::VT_FILTER_HEIGHT, filter_height, 0); |
3910 | } |
3911 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
3912 | fbb_.AddElement<int8_t>(Pool2DOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
3913 | } |
3914 | explicit Pool2DOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
3915 | : fbb_(_fbb) { |
3916 | start_ = fbb_.StartTable(); |
3917 | } |
3918 | Pool2DOptionsBuilder &operator=(const Pool2DOptionsBuilder &); |
3919 | flatbuffers::Offset<Pool2DOptions> Finish() { |
3920 | const auto end = fbb_.EndTable(start_); |
3921 | auto o = flatbuffers::Offset<Pool2DOptions>(end); |
3922 | return o; |
3923 | } |
3924 | }; |
3925 | |
3926 | inline flatbuffers::Offset<Pool2DOptions> CreatePool2DOptions( |
3927 | flatbuffers::FlatBufferBuilder &_fbb, |
3928 | tflite::Padding padding = tflite::Padding_SAME, |
3929 | int32_t stride_w = 0, |
3930 | int32_t stride_h = 0, |
3931 | int32_t filter_width = 0, |
3932 | int32_t filter_height = 0, |
3933 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
3934 | Pool2DOptionsBuilder builder_(_fbb); |
3935 | builder_.add_filter_height(filter_height); |
3936 | builder_.add_filter_width(filter_width); |
3937 | builder_.add_stride_h(stride_h); |
3938 | builder_.add_stride_w(stride_w); |
3939 | builder_.add_fused_activation_function(fused_activation_function); |
3940 | builder_.add_padding(padding); |
3941 | return builder_.Finish(); |
3942 | } |
3943 | |
3944 | flatbuffers::Offset<Pool2DOptions> CreatePool2DOptions(flatbuffers::FlatBufferBuilder &_fbb, const Pool2DOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
3945 | |
3946 | struct DepthwiseConv2DOptionsT : public flatbuffers::NativeTable { |
3947 | typedef DepthwiseConv2DOptions TableType; |
3948 | tflite::Padding padding; |
3949 | int32_t stride_w; |
3950 | int32_t stride_h; |
3951 | int32_t depth_multiplier; |
3952 | tflite::ActivationFunctionType fused_activation_function; |
3953 | int32_t dilation_w_factor; |
3954 | int32_t dilation_h_factor; |
3955 | DepthwiseConv2DOptionsT() |
3956 | : padding(tflite::Padding_SAME), |
3957 | stride_w(0), |
3958 | stride_h(0), |
3959 | depth_multiplier(0), |
3960 | fused_activation_function(tflite::ActivationFunctionType_NONE), |
3961 | dilation_w_factor(1), |
3962 | dilation_h_factor(1) { |
3963 | } |
3964 | }; |
3965 | |
3966 | struct DepthwiseConv2DOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
3967 | typedef DepthwiseConv2DOptionsT NativeTableType; |
3968 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
3969 | VT_PADDING = 4, |
3970 | VT_STRIDE_W = 6, |
3971 | VT_STRIDE_H = 8, |
3972 | VT_DEPTH_MULTIPLIER = 10, |
3973 | VT_FUSED_ACTIVATION_FUNCTION = 12, |
3974 | VT_DILATION_W_FACTOR = 14, |
3975 | VT_DILATION_H_FACTOR = 16 |
3976 | }; |
3977 | tflite::Padding padding() const { |
3978 | return static_cast<tflite::Padding>(GetField<int8_t>(VT_PADDING, 0)); |
3979 | } |
3980 | int32_t stride_w() const { |
3981 | return GetField<int32_t>(VT_STRIDE_W, 0); |
3982 | } |
3983 | int32_t stride_h() const { |
3984 | return GetField<int32_t>(VT_STRIDE_H, 0); |
3985 | } |
3986 | int32_t depth_multiplier() const { |
3987 | return GetField<int32_t>(VT_DEPTH_MULTIPLIER, 0); |
3988 | } |
3989 | tflite::ActivationFunctionType fused_activation_function() const { |
3990 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
3991 | } |
3992 | int32_t dilation_w_factor() const { |
3993 | return GetField<int32_t>(VT_DILATION_W_FACTOR, 1); |
3994 | } |
3995 | int32_t dilation_h_factor() const { |
3996 | return GetField<int32_t>(VT_DILATION_H_FACTOR, 1); |
3997 | } |
3998 | bool Verify(flatbuffers::Verifier &verifier) const { |
3999 | return VerifyTableStart(verifier) && |
4000 | VerifyField<int8_t>(verifier, VT_PADDING) && |
4001 | VerifyField<int32_t>(verifier, VT_STRIDE_W) && |
4002 | VerifyField<int32_t>(verifier, VT_STRIDE_H) && |
4003 | VerifyField<int32_t>(verifier, VT_DEPTH_MULTIPLIER) && |
4004 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4005 | VerifyField<int32_t>(verifier, VT_DILATION_W_FACTOR) && |
4006 | VerifyField<int32_t>(verifier, VT_DILATION_H_FACTOR) && |
4007 | verifier.EndTable(); |
4008 | } |
4009 | DepthwiseConv2DOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4010 | void UnPackTo(DepthwiseConv2DOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4011 | static flatbuffers::Offset<DepthwiseConv2DOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const DepthwiseConv2DOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4012 | }; |
4013 | |
4014 | struct DepthwiseConv2DOptionsBuilder { |
4015 | flatbuffers::FlatBufferBuilder &fbb_; |
4016 | flatbuffers::uoffset_t start_; |
4017 | void add_padding(tflite::Padding padding) { |
4018 | fbb_.AddElement<int8_t>(DepthwiseConv2DOptions::VT_PADDING, static_cast<int8_t>(padding), 0); |
4019 | } |
4020 | void add_stride_w(int32_t stride_w) { |
4021 | fbb_.AddElement<int32_t>(DepthwiseConv2DOptions::VT_STRIDE_W, stride_w, 0); |
4022 | } |
4023 | void add_stride_h(int32_t stride_h) { |
4024 | fbb_.AddElement<int32_t>(DepthwiseConv2DOptions::VT_STRIDE_H, stride_h, 0); |
4025 | } |
4026 | void add_depth_multiplier(int32_t depth_multiplier) { |
4027 | fbb_.AddElement<int32_t>(DepthwiseConv2DOptions::VT_DEPTH_MULTIPLIER, depth_multiplier, 0); |
4028 | } |
4029 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4030 | fbb_.AddElement<int8_t>(DepthwiseConv2DOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4031 | } |
4032 | void add_dilation_w_factor(int32_t dilation_w_factor) { |
4033 | fbb_.AddElement<int32_t>(DepthwiseConv2DOptions::VT_DILATION_W_FACTOR, dilation_w_factor, 1); |
4034 | } |
4035 | void add_dilation_h_factor(int32_t dilation_h_factor) { |
4036 | fbb_.AddElement<int32_t>(DepthwiseConv2DOptions::VT_DILATION_H_FACTOR, dilation_h_factor, 1); |
4037 | } |
4038 | explicit DepthwiseConv2DOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4039 | : fbb_(_fbb) { |
4040 | start_ = fbb_.StartTable(); |
4041 | } |
4042 | DepthwiseConv2DOptionsBuilder &operator=(const DepthwiseConv2DOptionsBuilder &); |
4043 | flatbuffers::Offset<DepthwiseConv2DOptions> Finish() { |
4044 | const auto end = fbb_.EndTable(start_); |
4045 | auto o = flatbuffers::Offset<DepthwiseConv2DOptions>(end); |
4046 | return o; |
4047 | } |
4048 | }; |
4049 | |
4050 | inline flatbuffers::Offset<DepthwiseConv2DOptions> CreateDepthwiseConv2DOptions( |
4051 | flatbuffers::FlatBufferBuilder &_fbb, |
4052 | tflite::Padding padding = tflite::Padding_SAME, |
4053 | int32_t stride_w = 0, |
4054 | int32_t stride_h = 0, |
4055 | int32_t depth_multiplier = 0, |
4056 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
4057 | int32_t dilation_w_factor = 1, |
4058 | int32_t dilation_h_factor = 1) { |
4059 | DepthwiseConv2DOptionsBuilder builder_(_fbb); |
4060 | builder_.add_dilation_h_factor(dilation_h_factor); |
4061 | builder_.add_dilation_w_factor(dilation_w_factor); |
4062 | builder_.add_depth_multiplier(depth_multiplier); |
4063 | builder_.add_stride_h(stride_h); |
4064 | builder_.add_stride_w(stride_w); |
4065 | builder_.add_fused_activation_function(fused_activation_function); |
4066 | builder_.add_padding(padding); |
4067 | return builder_.Finish(); |
4068 | } |
4069 | |
4070 | flatbuffers::Offset<DepthwiseConv2DOptions> CreateDepthwiseConv2DOptions(flatbuffers::FlatBufferBuilder &_fbb, const DepthwiseConv2DOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4071 | |
4072 | struct ConcatEmbeddingsOptionsT : public flatbuffers::NativeTable { |
4073 | typedef ConcatEmbeddingsOptions TableType; |
4074 | int32_t num_channels; |
4075 | std::vector<int32_t> num_columns_per_channel; |
4076 | std::vector<int32_t> embedding_dim_per_channel; |
4077 | ConcatEmbeddingsOptionsT() |
4078 | : num_channels(0) { |
4079 | } |
4080 | }; |
4081 | |
4082 | struct ConcatEmbeddingsOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4083 | typedef ConcatEmbeddingsOptionsT NativeTableType; |
4084 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4085 | VT_NUM_CHANNELS = 4, |
4086 | VT_NUM_COLUMNS_PER_CHANNEL = 6, |
4087 | VT_EMBEDDING_DIM_PER_CHANNEL = 8 |
4088 | }; |
4089 | int32_t num_channels() const { |
4090 | return GetField<int32_t>(VT_NUM_CHANNELS, 0); |
4091 | } |
4092 | const flatbuffers::Vector<int32_t> *num_columns_per_channel() const { |
4093 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_NUM_COLUMNS_PER_CHANNEL); |
4094 | } |
4095 | const flatbuffers::Vector<int32_t> *embedding_dim_per_channel() const { |
4096 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_EMBEDDING_DIM_PER_CHANNEL); |
4097 | } |
4098 | bool Verify(flatbuffers::Verifier &verifier) const { |
4099 | return VerifyTableStart(verifier) && |
4100 | VerifyField<int32_t>(verifier, VT_NUM_CHANNELS) && |
4101 | VerifyOffset(verifier, VT_NUM_COLUMNS_PER_CHANNEL) && |
4102 | verifier.VerifyVector(num_columns_per_channel()) && |
4103 | VerifyOffset(verifier, VT_EMBEDDING_DIM_PER_CHANNEL) && |
4104 | verifier.VerifyVector(embedding_dim_per_channel()) && |
4105 | verifier.EndTable(); |
4106 | } |
4107 | ConcatEmbeddingsOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4108 | void UnPackTo(ConcatEmbeddingsOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4109 | static flatbuffers::Offset<ConcatEmbeddingsOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ConcatEmbeddingsOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4110 | }; |
4111 | |
4112 | struct ConcatEmbeddingsOptionsBuilder { |
4113 | flatbuffers::FlatBufferBuilder &fbb_; |
4114 | flatbuffers::uoffset_t start_; |
4115 | void add_num_channels(int32_t num_channels) { |
4116 | fbb_.AddElement<int32_t>(ConcatEmbeddingsOptions::VT_NUM_CHANNELS, num_channels, 0); |
4117 | } |
4118 | void add_num_columns_per_channel(flatbuffers::Offset<flatbuffers::Vector<int32_t>> num_columns_per_channel) { |
4119 | fbb_.AddOffset(ConcatEmbeddingsOptions::VT_NUM_COLUMNS_PER_CHANNEL, num_columns_per_channel); |
4120 | } |
4121 | void add_embedding_dim_per_channel(flatbuffers::Offset<flatbuffers::Vector<int32_t>> embedding_dim_per_channel) { |
4122 | fbb_.AddOffset(ConcatEmbeddingsOptions::VT_EMBEDDING_DIM_PER_CHANNEL, embedding_dim_per_channel); |
4123 | } |
4124 | explicit ConcatEmbeddingsOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4125 | : fbb_(_fbb) { |
4126 | start_ = fbb_.StartTable(); |
4127 | } |
4128 | ConcatEmbeddingsOptionsBuilder &operator=(const ConcatEmbeddingsOptionsBuilder &); |
4129 | flatbuffers::Offset<ConcatEmbeddingsOptions> Finish() { |
4130 | const auto end = fbb_.EndTable(start_); |
4131 | auto o = flatbuffers::Offset<ConcatEmbeddingsOptions>(end); |
4132 | return o; |
4133 | } |
4134 | }; |
4135 | |
4136 | inline flatbuffers::Offset<ConcatEmbeddingsOptions> CreateConcatEmbeddingsOptions( |
4137 | flatbuffers::FlatBufferBuilder &_fbb, |
4138 | int32_t num_channels = 0, |
4139 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> num_columns_per_channel = 0, |
4140 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> embedding_dim_per_channel = 0) { |
4141 | ConcatEmbeddingsOptionsBuilder builder_(_fbb); |
4142 | builder_.add_embedding_dim_per_channel(embedding_dim_per_channel); |
4143 | builder_.add_num_columns_per_channel(num_columns_per_channel); |
4144 | builder_.add_num_channels(num_channels); |
4145 | return builder_.Finish(); |
4146 | } |
4147 | |
4148 | inline flatbuffers::Offset<ConcatEmbeddingsOptions> CreateConcatEmbeddingsOptionsDirect( |
4149 | flatbuffers::FlatBufferBuilder &_fbb, |
4150 | int32_t num_channels = 0, |
4151 | const std::vector<int32_t> *num_columns_per_channel = nullptr, |
4152 | const std::vector<int32_t> *embedding_dim_per_channel = nullptr) { |
4153 | auto num_columns_per_channel__ = num_columns_per_channel ? _fbb.CreateVector<int32_t>(*num_columns_per_channel) : 0; |
4154 | auto embedding_dim_per_channel__ = embedding_dim_per_channel ? _fbb.CreateVector<int32_t>(*embedding_dim_per_channel) : 0; |
4155 | return tflite::CreateConcatEmbeddingsOptions( |
4156 | _fbb, |
4157 | num_channels, |
4158 | num_columns_per_channel__, |
4159 | embedding_dim_per_channel__); |
4160 | } |
4161 | |
4162 | flatbuffers::Offset<ConcatEmbeddingsOptions> CreateConcatEmbeddingsOptions(flatbuffers::FlatBufferBuilder &_fbb, const ConcatEmbeddingsOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4163 | |
4164 | struct LSHProjectionOptionsT : public flatbuffers::NativeTable { |
4165 | typedef LSHProjectionOptions TableType; |
4166 | tflite::LSHProjectionType type; |
4167 | LSHProjectionOptionsT() |
4168 | : type(tflite::LSHProjectionType_UNKNOWN) { |
4169 | } |
4170 | }; |
4171 | |
4172 | struct LSHProjectionOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4173 | typedef LSHProjectionOptionsT NativeTableType; |
4174 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4175 | VT_TYPE = 4 |
4176 | }; |
4177 | tflite::LSHProjectionType type() const { |
4178 | return static_cast<tflite::LSHProjectionType>(GetField<int8_t>(VT_TYPE, 0)); |
4179 | } |
4180 | bool Verify(flatbuffers::Verifier &verifier) const { |
4181 | return VerifyTableStart(verifier) && |
4182 | VerifyField<int8_t>(verifier, VT_TYPE) && |
4183 | verifier.EndTable(); |
4184 | } |
4185 | LSHProjectionOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4186 | void UnPackTo(LSHProjectionOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4187 | static flatbuffers::Offset<LSHProjectionOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LSHProjectionOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4188 | }; |
4189 | |
4190 | struct LSHProjectionOptionsBuilder { |
4191 | flatbuffers::FlatBufferBuilder &fbb_; |
4192 | flatbuffers::uoffset_t start_; |
4193 | void add_type(tflite::LSHProjectionType type) { |
4194 | fbb_.AddElement<int8_t>(LSHProjectionOptions::VT_TYPE, static_cast<int8_t>(type), 0); |
4195 | } |
4196 | explicit LSHProjectionOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4197 | : fbb_(_fbb) { |
4198 | start_ = fbb_.StartTable(); |
4199 | } |
4200 | LSHProjectionOptionsBuilder &operator=(const LSHProjectionOptionsBuilder &); |
4201 | flatbuffers::Offset<LSHProjectionOptions> Finish() { |
4202 | const auto end = fbb_.EndTable(start_); |
4203 | auto o = flatbuffers::Offset<LSHProjectionOptions>(end); |
4204 | return o; |
4205 | } |
4206 | }; |
4207 | |
4208 | inline flatbuffers::Offset<LSHProjectionOptions> CreateLSHProjectionOptions( |
4209 | flatbuffers::FlatBufferBuilder &_fbb, |
4210 | tflite::LSHProjectionType type = tflite::LSHProjectionType_UNKNOWN) { |
4211 | LSHProjectionOptionsBuilder builder_(_fbb); |
4212 | builder_.add_type(type); |
4213 | return builder_.Finish(); |
4214 | } |
4215 | |
4216 | flatbuffers::Offset<LSHProjectionOptions> CreateLSHProjectionOptions(flatbuffers::FlatBufferBuilder &_fbb, const LSHProjectionOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4217 | |
4218 | struct SVDFOptionsT : public flatbuffers::NativeTable { |
4219 | typedef SVDFOptions TableType; |
4220 | int32_t rank; |
4221 | tflite::ActivationFunctionType fused_activation_function; |
4222 | bool asymmetric_quantize_inputs; |
4223 | SVDFOptionsT() |
4224 | : rank(0), |
4225 | fused_activation_function(tflite::ActivationFunctionType_NONE), |
4226 | asymmetric_quantize_inputs(false) { |
4227 | } |
4228 | }; |
4229 | |
4230 | struct SVDFOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4231 | typedef SVDFOptionsT NativeTableType; |
4232 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4233 | VT_RANK = 4, |
4234 | VT_FUSED_ACTIVATION_FUNCTION = 6, |
4235 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 8 |
4236 | }; |
4237 | int32_t rank() const { |
4238 | return GetField<int32_t>(VT_RANK, 0); |
4239 | } |
4240 | tflite::ActivationFunctionType fused_activation_function() const { |
4241 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4242 | } |
4243 | bool asymmetric_quantize_inputs() const { |
4244 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
4245 | } |
4246 | bool Verify(flatbuffers::Verifier &verifier) const { |
4247 | return VerifyTableStart(verifier) && |
4248 | VerifyField<int32_t>(verifier, VT_RANK) && |
4249 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4250 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
4251 | verifier.EndTable(); |
4252 | } |
4253 | SVDFOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4254 | void UnPackTo(SVDFOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4255 | static flatbuffers::Offset<SVDFOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SVDFOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4256 | }; |
4257 | |
4258 | struct SVDFOptionsBuilder { |
4259 | flatbuffers::FlatBufferBuilder &fbb_; |
4260 | flatbuffers::uoffset_t start_; |
4261 | void add_rank(int32_t rank) { |
4262 | fbb_.AddElement<int32_t>(SVDFOptions::VT_RANK, rank, 0); |
4263 | } |
4264 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4265 | fbb_.AddElement<int8_t>(SVDFOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4266 | } |
4267 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
4268 | fbb_.AddElement<uint8_t>(SVDFOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
4269 | } |
4270 | explicit SVDFOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4271 | : fbb_(_fbb) { |
4272 | start_ = fbb_.StartTable(); |
4273 | } |
4274 | SVDFOptionsBuilder &operator=(const SVDFOptionsBuilder &); |
4275 | flatbuffers::Offset<SVDFOptions> Finish() { |
4276 | const auto end = fbb_.EndTable(start_); |
4277 | auto o = flatbuffers::Offset<SVDFOptions>(end); |
4278 | return o; |
4279 | } |
4280 | }; |
4281 | |
4282 | inline flatbuffers::Offset<SVDFOptions> CreateSVDFOptions( |
4283 | flatbuffers::FlatBufferBuilder &_fbb, |
4284 | int32_t rank = 0, |
4285 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
4286 | bool asymmetric_quantize_inputs = false) { |
4287 | SVDFOptionsBuilder builder_(_fbb); |
4288 | builder_.add_rank(rank); |
4289 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
4290 | builder_.add_fused_activation_function(fused_activation_function); |
4291 | return builder_.Finish(); |
4292 | } |
4293 | |
4294 | flatbuffers::Offset<SVDFOptions> CreateSVDFOptions(flatbuffers::FlatBufferBuilder &_fbb, const SVDFOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4295 | |
4296 | struct RNNOptionsT : public flatbuffers::NativeTable { |
4297 | typedef RNNOptions TableType; |
4298 | tflite::ActivationFunctionType fused_activation_function; |
4299 | bool asymmetric_quantize_inputs; |
4300 | RNNOptionsT() |
4301 | : fused_activation_function(tflite::ActivationFunctionType_NONE), |
4302 | asymmetric_quantize_inputs(false) { |
4303 | } |
4304 | }; |
4305 | |
4306 | struct RNNOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4307 | typedef RNNOptionsT NativeTableType; |
4308 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4309 | VT_FUSED_ACTIVATION_FUNCTION = 4, |
4310 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 6 |
4311 | }; |
4312 | tflite::ActivationFunctionType fused_activation_function() const { |
4313 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4314 | } |
4315 | bool asymmetric_quantize_inputs() const { |
4316 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
4317 | } |
4318 | bool Verify(flatbuffers::Verifier &verifier) const { |
4319 | return VerifyTableStart(verifier) && |
4320 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4321 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
4322 | verifier.EndTable(); |
4323 | } |
4324 | RNNOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4325 | void UnPackTo(RNNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4326 | static flatbuffers::Offset<RNNOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const RNNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4327 | }; |
4328 | |
4329 | struct RNNOptionsBuilder { |
4330 | flatbuffers::FlatBufferBuilder &fbb_; |
4331 | flatbuffers::uoffset_t start_; |
4332 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4333 | fbb_.AddElement<int8_t>(RNNOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4334 | } |
4335 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
4336 | fbb_.AddElement<uint8_t>(RNNOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
4337 | } |
4338 | explicit RNNOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4339 | : fbb_(_fbb) { |
4340 | start_ = fbb_.StartTable(); |
4341 | } |
4342 | RNNOptionsBuilder &operator=(const RNNOptionsBuilder &); |
4343 | flatbuffers::Offset<RNNOptions> Finish() { |
4344 | const auto end = fbb_.EndTable(start_); |
4345 | auto o = flatbuffers::Offset<RNNOptions>(end); |
4346 | return o; |
4347 | } |
4348 | }; |
4349 | |
4350 | inline flatbuffers::Offset<RNNOptions> CreateRNNOptions( |
4351 | flatbuffers::FlatBufferBuilder &_fbb, |
4352 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
4353 | bool asymmetric_quantize_inputs = false) { |
4354 | RNNOptionsBuilder builder_(_fbb); |
4355 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
4356 | builder_.add_fused_activation_function(fused_activation_function); |
4357 | return builder_.Finish(); |
4358 | } |
4359 | |
4360 | flatbuffers::Offset<RNNOptions> CreateRNNOptions(flatbuffers::FlatBufferBuilder &_fbb, const RNNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4361 | |
4362 | struct SequenceRNNOptionsT : public flatbuffers::NativeTable { |
4363 | typedef SequenceRNNOptions TableType; |
4364 | bool time_major; |
4365 | tflite::ActivationFunctionType fused_activation_function; |
4366 | bool asymmetric_quantize_inputs; |
4367 | SequenceRNNOptionsT() |
4368 | : time_major(false), |
4369 | fused_activation_function(tflite::ActivationFunctionType_NONE), |
4370 | asymmetric_quantize_inputs(false) { |
4371 | } |
4372 | }; |
4373 | |
4374 | struct SequenceRNNOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4375 | typedef SequenceRNNOptionsT NativeTableType; |
4376 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4377 | VT_TIME_MAJOR = 4, |
4378 | VT_FUSED_ACTIVATION_FUNCTION = 6, |
4379 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 8 |
4380 | }; |
4381 | bool time_major() const { |
4382 | return GetField<uint8_t>(VT_TIME_MAJOR, 0) != 0; |
4383 | } |
4384 | tflite::ActivationFunctionType fused_activation_function() const { |
4385 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4386 | } |
4387 | bool asymmetric_quantize_inputs() const { |
4388 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
4389 | } |
4390 | bool Verify(flatbuffers::Verifier &verifier) const { |
4391 | return VerifyTableStart(verifier) && |
4392 | VerifyField<uint8_t>(verifier, VT_TIME_MAJOR) && |
4393 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4394 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
4395 | verifier.EndTable(); |
4396 | } |
4397 | SequenceRNNOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4398 | void UnPackTo(SequenceRNNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4399 | static flatbuffers::Offset<SequenceRNNOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SequenceRNNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4400 | }; |
4401 | |
4402 | struct SequenceRNNOptionsBuilder { |
4403 | flatbuffers::FlatBufferBuilder &fbb_; |
4404 | flatbuffers::uoffset_t start_; |
4405 | void add_time_major(bool time_major) { |
4406 | fbb_.AddElement<uint8_t>(SequenceRNNOptions::VT_TIME_MAJOR, static_cast<uint8_t>(time_major), 0); |
4407 | } |
4408 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4409 | fbb_.AddElement<int8_t>(SequenceRNNOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4410 | } |
4411 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
4412 | fbb_.AddElement<uint8_t>(SequenceRNNOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
4413 | } |
4414 | explicit SequenceRNNOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4415 | : fbb_(_fbb) { |
4416 | start_ = fbb_.StartTable(); |
4417 | } |
4418 | SequenceRNNOptionsBuilder &operator=(const SequenceRNNOptionsBuilder &); |
4419 | flatbuffers::Offset<SequenceRNNOptions> Finish() { |
4420 | const auto end = fbb_.EndTable(start_); |
4421 | auto o = flatbuffers::Offset<SequenceRNNOptions>(end); |
4422 | return o; |
4423 | } |
4424 | }; |
4425 | |
4426 | inline flatbuffers::Offset<SequenceRNNOptions> CreateSequenceRNNOptions( |
4427 | flatbuffers::FlatBufferBuilder &_fbb, |
4428 | bool time_major = false, |
4429 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
4430 | bool asymmetric_quantize_inputs = false) { |
4431 | SequenceRNNOptionsBuilder builder_(_fbb); |
4432 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
4433 | builder_.add_fused_activation_function(fused_activation_function); |
4434 | builder_.add_time_major(time_major); |
4435 | return builder_.Finish(); |
4436 | } |
4437 | |
4438 | flatbuffers::Offset<SequenceRNNOptions> CreateSequenceRNNOptions(flatbuffers::FlatBufferBuilder &_fbb, const SequenceRNNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4439 | |
4440 | struct BidirectionalSequenceRNNOptionsT : public flatbuffers::NativeTable { |
4441 | typedef BidirectionalSequenceRNNOptions TableType; |
4442 | bool time_major; |
4443 | tflite::ActivationFunctionType fused_activation_function; |
4444 | bool merge_outputs; |
4445 | bool asymmetric_quantize_inputs; |
4446 | BidirectionalSequenceRNNOptionsT() |
4447 | : time_major(false), |
4448 | fused_activation_function(tflite::ActivationFunctionType_NONE), |
4449 | merge_outputs(false), |
4450 | asymmetric_quantize_inputs(false) { |
4451 | } |
4452 | }; |
4453 | |
4454 | struct BidirectionalSequenceRNNOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4455 | typedef BidirectionalSequenceRNNOptionsT NativeTableType; |
4456 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4457 | VT_TIME_MAJOR = 4, |
4458 | VT_FUSED_ACTIVATION_FUNCTION = 6, |
4459 | VT_MERGE_OUTPUTS = 8, |
4460 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 10 |
4461 | }; |
4462 | bool time_major() const { |
4463 | return GetField<uint8_t>(VT_TIME_MAJOR, 0) != 0; |
4464 | } |
4465 | tflite::ActivationFunctionType fused_activation_function() const { |
4466 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4467 | } |
4468 | bool merge_outputs() const { |
4469 | return GetField<uint8_t>(VT_MERGE_OUTPUTS, 0) != 0; |
4470 | } |
4471 | bool asymmetric_quantize_inputs() const { |
4472 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
4473 | } |
4474 | bool Verify(flatbuffers::Verifier &verifier) const { |
4475 | return VerifyTableStart(verifier) && |
4476 | VerifyField<uint8_t>(verifier, VT_TIME_MAJOR) && |
4477 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4478 | VerifyField<uint8_t>(verifier, VT_MERGE_OUTPUTS) && |
4479 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
4480 | verifier.EndTable(); |
4481 | } |
4482 | BidirectionalSequenceRNNOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4483 | void UnPackTo(BidirectionalSequenceRNNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4484 | static flatbuffers::Offset<BidirectionalSequenceRNNOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceRNNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4485 | }; |
4486 | |
4487 | struct BidirectionalSequenceRNNOptionsBuilder { |
4488 | flatbuffers::FlatBufferBuilder &fbb_; |
4489 | flatbuffers::uoffset_t start_; |
4490 | void add_time_major(bool time_major) { |
4491 | fbb_.AddElement<uint8_t>(BidirectionalSequenceRNNOptions::VT_TIME_MAJOR, static_cast<uint8_t>(time_major), 0); |
4492 | } |
4493 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4494 | fbb_.AddElement<int8_t>(BidirectionalSequenceRNNOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4495 | } |
4496 | void add_merge_outputs(bool merge_outputs) { |
4497 | fbb_.AddElement<uint8_t>(BidirectionalSequenceRNNOptions::VT_MERGE_OUTPUTS, static_cast<uint8_t>(merge_outputs), 0); |
4498 | } |
4499 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
4500 | fbb_.AddElement<uint8_t>(BidirectionalSequenceRNNOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
4501 | } |
4502 | explicit BidirectionalSequenceRNNOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4503 | : fbb_(_fbb) { |
4504 | start_ = fbb_.StartTable(); |
4505 | } |
4506 | BidirectionalSequenceRNNOptionsBuilder &operator=(const BidirectionalSequenceRNNOptionsBuilder &); |
4507 | flatbuffers::Offset<BidirectionalSequenceRNNOptions> Finish() { |
4508 | const auto end = fbb_.EndTable(start_); |
4509 | auto o = flatbuffers::Offset<BidirectionalSequenceRNNOptions>(end); |
4510 | return o; |
4511 | } |
4512 | }; |
4513 | |
4514 | inline flatbuffers::Offset<BidirectionalSequenceRNNOptions> CreateBidirectionalSequenceRNNOptions( |
4515 | flatbuffers::FlatBufferBuilder &_fbb, |
4516 | bool time_major = false, |
4517 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
4518 | bool merge_outputs = false, |
4519 | bool asymmetric_quantize_inputs = false) { |
4520 | BidirectionalSequenceRNNOptionsBuilder builder_(_fbb); |
4521 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
4522 | builder_.add_merge_outputs(merge_outputs); |
4523 | builder_.add_fused_activation_function(fused_activation_function); |
4524 | builder_.add_time_major(time_major); |
4525 | return builder_.Finish(); |
4526 | } |
4527 | |
4528 | flatbuffers::Offset<BidirectionalSequenceRNNOptions> CreateBidirectionalSequenceRNNOptions(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceRNNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4529 | |
4530 | struct FullyConnectedOptionsT : public flatbuffers::NativeTable { |
4531 | typedef FullyConnectedOptions TableType; |
4532 | tflite::ActivationFunctionType fused_activation_function; |
4533 | tflite::FullyConnectedOptionsWeightsFormat weights_format; |
4534 | bool keep_num_dims; |
4535 | bool asymmetric_quantize_inputs; |
4536 | FullyConnectedOptionsT() |
4537 | : fused_activation_function(tflite::ActivationFunctionType_NONE), |
4538 | weights_format(tflite::FullyConnectedOptionsWeightsFormat_DEFAULT), |
4539 | keep_num_dims(false), |
4540 | asymmetric_quantize_inputs(false) { |
4541 | } |
4542 | }; |
4543 | |
4544 | struct FullyConnectedOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4545 | typedef FullyConnectedOptionsT NativeTableType; |
4546 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4547 | VT_FUSED_ACTIVATION_FUNCTION = 4, |
4548 | VT_WEIGHTS_FORMAT = 6, |
4549 | VT_KEEP_NUM_DIMS = 8, |
4550 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 10 |
4551 | }; |
4552 | tflite::ActivationFunctionType fused_activation_function() const { |
4553 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4554 | } |
4555 | tflite::FullyConnectedOptionsWeightsFormat weights_format() const { |
4556 | return static_cast<tflite::FullyConnectedOptionsWeightsFormat>(GetField<int8_t>(VT_WEIGHTS_FORMAT, 0)); |
4557 | } |
4558 | bool keep_num_dims() const { |
4559 | return GetField<uint8_t>(VT_KEEP_NUM_DIMS, 0) != 0; |
4560 | } |
4561 | bool asymmetric_quantize_inputs() const { |
4562 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
4563 | } |
4564 | bool Verify(flatbuffers::Verifier &verifier) const { |
4565 | return VerifyTableStart(verifier) && |
4566 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4567 | VerifyField<int8_t>(verifier, VT_WEIGHTS_FORMAT) && |
4568 | VerifyField<uint8_t>(verifier, VT_KEEP_NUM_DIMS) && |
4569 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
4570 | verifier.EndTable(); |
4571 | } |
4572 | FullyConnectedOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4573 | void UnPackTo(FullyConnectedOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4574 | static flatbuffers::Offset<FullyConnectedOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const FullyConnectedOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4575 | }; |
4576 | |
4577 | struct FullyConnectedOptionsBuilder { |
4578 | flatbuffers::FlatBufferBuilder &fbb_; |
4579 | flatbuffers::uoffset_t start_; |
4580 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4581 | fbb_.AddElement<int8_t>(FullyConnectedOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4582 | } |
4583 | void add_weights_format(tflite::FullyConnectedOptionsWeightsFormat weights_format) { |
4584 | fbb_.AddElement<int8_t>(FullyConnectedOptions::VT_WEIGHTS_FORMAT, static_cast<int8_t>(weights_format), 0); |
4585 | } |
4586 | void add_keep_num_dims(bool keep_num_dims) { |
4587 | fbb_.AddElement<uint8_t>(FullyConnectedOptions::VT_KEEP_NUM_DIMS, static_cast<uint8_t>(keep_num_dims), 0); |
4588 | } |
4589 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
4590 | fbb_.AddElement<uint8_t>(FullyConnectedOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
4591 | } |
4592 | explicit FullyConnectedOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4593 | : fbb_(_fbb) { |
4594 | start_ = fbb_.StartTable(); |
4595 | } |
4596 | FullyConnectedOptionsBuilder &operator=(const FullyConnectedOptionsBuilder &); |
4597 | flatbuffers::Offset<FullyConnectedOptions> Finish() { |
4598 | const auto end = fbb_.EndTable(start_); |
4599 | auto o = flatbuffers::Offset<FullyConnectedOptions>(end); |
4600 | return o; |
4601 | } |
4602 | }; |
4603 | |
4604 | inline flatbuffers::Offset<FullyConnectedOptions> CreateFullyConnectedOptions( |
4605 | flatbuffers::FlatBufferBuilder &_fbb, |
4606 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
4607 | tflite::FullyConnectedOptionsWeightsFormat weights_format = tflite::FullyConnectedOptionsWeightsFormat_DEFAULT, |
4608 | bool keep_num_dims = false, |
4609 | bool asymmetric_quantize_inputs = false) { |
4610 | FullyConnectedOptionsBuilder builder_(_fbb); |
4611 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
4612 | builder_.add_keep_num_dims(keep_num_dims); |
4613 | builder_.add_weights_format(weights_format); |
4614 | builder_.add_fused_activation_function(fused_activation_function); |
4615 | return builder_.Finish(); |
4616 | } |
4617 | |
4618 | flatbuffers::Offset<FullyConnectedOptions> CreateFullyConnectedOptions(flatbuffers::FlatBufferBuilder &_fbb, const FullyConnectedOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4619 | |
4620 | struct SoftmaxOptionsT : public flatbuffers::NativeTable { |
4621 | typedef SoftmaxOptions TableType; |
4622 | float beta; |
4623 | SoftmaxOptionsT() |
4624 | : beta(0.0f) { |
4625 | } |
4626 | }; |
4627 | |
4628 | struct SoftmaxOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4629 | typedef SoftmaxOptionsT NativeTableType; |
4630 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4631 | VT_BETA = 4 |
4632 | }; |
4633 | float beta() const { |
4634 | return GetField<float>(VT_BETA, 0.0f); |
4635 | } |
4636 | bool Verify(flatbuffers::Verifier &verifier) const { |
4637 | return VerifyTableStart(verifier) && |
4638 | VerifyField<float>(verifier, VT_BETA) && |
4639 | verifier.EndTable(); |
4640 | } |
4641 | SoftmaxOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4642 | void UnPackTo(SoftmaxOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4643 | static flatbuffers::Offset<SoftmaxOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SoftmaxOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4644 | }; |
4645 | |
4646 | struct SoftmaxOptionsBuilder { |
4647 | flatbuffers::FlatBufferBuilder &fbb_; |
4648 | flatbuffers::uoffset_t start_; |
4649 | void add_beta(float beta) { |
4650 | fbb_.AddElement<float>(SoftmaxOptions::VT_BETA, beta, 0.0f); |
4651 | } |
4652 | explicit SoftmaxOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4653 | : fbb_(_fbb) { |
4654 | start_ = fbb_.StartTable(); |
4655 | } |
4656 | SoftmaxOptionsBuilder &operator=(const SoftmaxOptionsBuilder &); |
4657 | flatbuffers::Offset<SoftmaxOptions> Finish() { |
4658 | const auto end = fbb_.EndTable(start_); |
4659 | auto o = flatbuffers::Offset<SoftmaxOptions>(end); |
4660 | return o; |
4661 | } |
4662 | }; |
4663 | |
4664 | inline flatbuffers::Offset<SoftmaxOptions> CreateSoftmaxOptions( |
4665 | flatbuffers::FlatBufferBuilder &_fbb, |
4666 | float beta = 0.0f) { |
4667 | SoftmaxOptionsBuilder builder_(_fbb); |
4668 | builder_.add_beta(beta); |
4669 | return builder_.Finish(); |
4670 | } |
4671 | |
4672 | flatbuffers::Offset<SoftmaxOptions> CreateSoftmaxOptions(flatbuffers::FlatBufferBuilder &_fbb, const SoftmaxOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4673 | |
4674 | struct ConcatenationOptionsT : public flatbuffers::NativeTable { |
4675 | typedef ConcatenationOptions TableType; |
4676 | int32_t axis; |
4677 | tflite::ActivationFunctionType fused_activation_function; |
4678 | ConcatenationOptionsT() |
4679 | : axis(0), |
4680 | fused_activation_function(tflite::ActivationFunctionType_NONE) { |
4681 | } |
4682 | }; |
4683 | |
4684 | struct ConcatenationOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4685 | typedef ConcatenationOptionsT NativeTableType; |
4686 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4687 | VT_AXIS = 4, |
4688 | VT_FUSED_ACTIVATION_FUNCTION = 6 |
4689 | }; |
4690 | int32_t axis() const { |
4691 | return GetField<int32_t>(VT_AXIS, 0); |
4692 | } |
4693 | tflite::ActivationFunctionType fused_activation_function() const { |
4694 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4695 | } |
4696 | bool Verify(flatbuffers::Verifier &verifier) const { |
4697 | return VerifyTableStart(verifier) && |
4698 | VerifyField<int32_t>(verifier, VT_AXIS) && |
4699 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4700 | verifier.EndTable(); |
4701 | } |
4702 | ConcatenationOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4703 | void UnPackTo(ConcatenationOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4704 | static flatbuffers::Offset<ConcatenationOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ConcatenationOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4705 | }; |
4706 | |
4707 | struct ConcatenationOptionsBuilder { |
4708 | flatbuffers::FlatBufferBuilder &fbb_; |
4709 | flatbuffers::uoffset_t start_; |
4710 | void add_axis(int32_t axis) { |
4711 | fbb_.AddElement<int32_t>(ConcatenationOptions::VT_AXIS, axis, 0); |
4712 | } |
4713 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4714 | fbb_.AddElement<int8_t>(ConcatenationOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4715 | } |
4716 | explicit ConcatenationOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4717 | : fbb_(_fbb) { |
4718 | start_ = fbb_.StartTable(); |
4719 | } |
4720 | ConcatenationOptionsBuilder &operator=(const ConcatenationOptionsBuilder &); |
4721 | flatbuffers::Offset<ConcatenationOptions> Finish() { |
4722 | const auto end = fbb_.EndTable(start_); |
4723 | auto o = flatbuffers::Offset<ConcatenationOptions>(end); |
4724 | return o; |
4725 | } |
4726 | }; |
4727 | |
4728 | inline flatbuffers::Offset<ConcatenationOptions> CreateConcatenationOptions( |
4729 | flatbuffers::FlatBufferBuilder &_fbb, |
4730 | int32_t axis = 0, |
4731 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
4732 | ConcatenationOptionsBuilder builder_(_fbb); |
4733 | builder_.add_axis(axis); |
4734 | builder_.add_fused_activation_function(fused_activation_function); |
4735 | return builder_.Finish(); |
4736 | } |
4737 | |
4738 | flatbuffers::Offset<ConcatenationOptions> CreateConcatenationOptions(flatbuffers::FlatBufferBuilder &_fbb, const ConcatenationOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4739 | |
4740 | struct AddOptionsT : public flatbuffers::NativeTable { |
4741 | typedef AddOptions TableType; |
4742 | tflite::ActivationFunctionType fused_activation_function; |
4743 | AddOptionsT() |
4744 | : fused_activation_function(tflite::ActivationFunctionType_NONE) { |
4745 | } |
4746 | }; |
4747 | |
4748 | struct AddOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4749 | typedef AddOptionsT NativeTableType; |
4750 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4751 | VT_FUSED_ACTIVATION_FUNCTION = 4 |
4752 | }; |
4753 | tflite::ActivationFunctionType fused_activation_function() const { |
4754 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4755 | } |
4756 | bool Verify(flatbuffers::Verifier &verifier) const { |
4757 | return VerifyTableStart(verifier) && |
4758 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4759 | verifier.EndTable(); |
4760 | } |
4761 | AddOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4762 | void UnPackTo(AddOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4763 | static flatbuffers::Offset<AddOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AddOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4764 | }; |
4765 | |
4766 | struct AddOptionsBuilder { |
4767 | flatbuffers::FlatBufferBuilder &fbb_; |
4768 | flatbuffers::uoffset_t start_; |
4769 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4770 | fbb_.AddElement<int8_t>(AddOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4771 | } |
4772 | explicit AddOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4773 | : fbb_(_fbb) { |
4774 | start_ = fbb_.StartTable(); |
4775 | } |
4776 | AddOptionsBuilder &operator=(const AddOptionsBuilder &); |
4777 | flatbuffers::Offset<AddOptions> Finish() { |
4778 | const auto end = fbb_.EndTable(start_); |
4779 | auto o = flatbuffers::Offset<AddOptions>(end); |
4780 | return o; |
4781 | } |
4782 | }; |
4783 | |
4784 | inline flatbuffers::Offset<AddOptions> CreateAddOptions( |
4785 | flatbuffers::FlatBufferBuilder &_fbb, |
4786 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
4787 | AddOptionsBuilder builder_(_fbb); |
4788 | builder_.add_fused_activation_function(fused_activation_function); |
4789 | return builder_.Finish(); |
4790 | } |
4791 | |
4792 | flatbuffers::Offset<AddOptions> CreateAddOptions(flatbuffers::FlatBufferBuilder &_fbb, const AddOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4793 | |
4794 | struct MulOptionsT : public flatbuffers::NativeTable { |
4795 | typedef MulOptions TableType; |
4796 | tflite::ActivationFunctionType fused_activation_function; |
4797 | MulOptionsT() |
4798 | : fused_activation_function(tflite::ActivationFunctionType_NONE) { |
4799 | } |
4800 | }; |
4801 | |
4802 | struct MulOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4803 | typedef MulOptionsT NativeTableType; |
4804 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4805 | VT_FUSED_ACTIVATION_FUNCTION = 4 |
4806 | }; |
4807 | tflite::ActivationFunctionType fused_activation_function() const { |
4808 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4809 | } |
4810 | bool Verify(flatbuffers::Verifier &verifier) const { |
4811 | return VerifyTableStart(verifier) && |
4812 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4813 | verifier.EndTable(); |
4814 | } |
4815 | MulOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4816 | void UnPackTo(MulOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4817 | static flatbuffers::Offset<MulOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const MulOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4818 | }; |
4819 | |
4820 | struct MulOptionsBuilder { |
4821 | flatbuffers::FlatBufferBuilder &fbb_; |
4822 | flatbuffers::uoffset_t start_; |
4823 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4824 | fbb_.AddElement<int8_t>(MulOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4825 | } |
4826 | explicit MulOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4827 | : fbb_(_fbb) { |
4828 | start_ = fbb_.StartTable(); |
4829 | } |
4830 | MulOptionsBuilder &operator=(const MulOptionsBuilder &); |
4831 | flatbuffers::Offset<MulOptions> Finish() { |
4832 | const auto end = fbb_.EndTable(start_); |
4833 | auto o = flatbuffers::Offset<MulOptions>(end); |
4834 | return o; |
4835 | } |
4836 | }; |
4837 | |
4838 | inline flatbuffers::Offset<MulOptions> CreateMulOptions( |
4839 | flatbuffers::FlatBufferBuilder &_fbb, |
4840 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
4841 | MulOptionsBuilder builder_(_fbb); |
4842 | builder_.add_fused_activation_function(fused_activation_function); |
4843 | return builder_.Finish(); |
4844 | } |
4845 | |
4846 | flatbuffers::Offset<MulOptions> CreateMulOptions(flatbuffers::FlatBufferBuilder &_fbb, const MulOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4847 | |
4848 | struct L2NormOptionsT : public flatbuffers::NativeTable { |
4849 | typedef L2NormOptions TableType; |
4850 | tflite::ActivationFunctionType fused_activation_function; |
4851 | L2NormOptionsT() |
4852 | : fused_activation_function(tflite::ActivationFunctionType_NONE) { |
4853 | } |
4854 | }; |
4855 | |
4856 | struct L2NormOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4857 | typedef L2NormOptionsT NativeTableType; |
4858 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4859 | VT_FUSED_ACTIVATION_FUNCTION = 4 |
4860 | }; |
4861 | tflite::ActivationFunctionType fused_activation_function() const { |
4862 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
4863 | } |
4864 | bool Verify(flatbuffers::Verifier &verifier) const { |
4865 | return VerifyTableStart(verifier) && |
4866 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
4867 | verifier.EndTable(); |
4868 | } |
4869 | L2NormOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4870 | void UnPackTo(L2NormOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4871 | static flatbuffers::Offset<L2NormOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const L2NormOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4872 | }; |
4873 | |
4874 | struct L2NormOptionsBuilder { |
4875 | flatbuffers::FlatBufferBuilder &fbb_; |
4876 | flatbuffers::uoffset_t start_; |
4877 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
4878 | fbb_.AddElement<int8_t>(L2NormOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
4879 | } |
4880 | explicit L2NormOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4881 | : fbb_(_fbb) { |
4882 | start_ = fbb_.StartTable(); |
4883 | } |
4884 | L2NormOptionsBuilder &operator=(const L2NormOptionsBuilder &); |
4885 | flatbuffers::Offset<L2NormOptions> Finish() { |
4886 | const auto end = fbb_.EndTable(start_); |
4887 | auto o = flatbuffers::Offset<L2NormOptions>(end); |
4888 | return o; |
4889 | } |
4890 | }; |
4891 | |
4892 | inline flatbuffers::Offset<L2NormOptions> CreateL2NormOptions( |
4893 | flatbuffers::FlatBufferBuilder &_fbb, |
4894 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
4895 | L2NormOptionsBuilder builder_(_fbb); |
4896 | builder_.add_fused_activation_function(fused_activation_function); |
4897 | return builder_.Finish(); |
4898 | } |
4899 | |
4900 | flatbuffers::Offset<L2NormOptions> CreateL2NormOptions(flatbuffers::FlatBufferBuilder &_fbb, const L2NormOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4901 | |
4902 | struct LocalResponseNormalizationOptionsT : public flatbuffers::NativeTable { |
4903 | typedef LocalResponseNormalizationOptions TableType; |
4904 | int32_t radius; |
4905 | float bias; |
4906 | float alpha; |
4907 | float beta; |
4908 | LocalResponseNormalizationOptionsT() |
4909 | : radius(0), |
4910 | bias(0.0f), |
4911 | alpha(0.0f), |
4912 | beta(0.0f) { |
4913 | } |
4914 | }; |
4915 | |
4916 | struct LocalResponseNormalizationOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
4917 | typedef LocalResponseNormalizationOptionsT NativeTableType; |
4918 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
4919 | VT_RADIUS = 4, |
4920 | VT_BIAS = 6, |
4921 | VT_ALPHA = 8, |
4922 | VT_BETA = 10 |
4923 | }; |
4924 | int32_t radius() const { |
4925 | return GetField<int32_t>(VT_RADIUS, 0); |
4926 | } |
4927 | float bias() const { |
4928 | return GetField<float>(VT_BIAS, 0.0f); |
4929 | } |
4930 | float alpha() const { |
4931 | return GetField<float>(VT_ALPHA, 0.0f); |
4932 | } |
4933 | float beta() const { |
4934 | return GetField<float>(VT_BETA, 0.0f); |
4935 | } |
4936 | bool Verify(flatbuffers::Verifier &verifier) const { |
4937 | return VerifyTableStart(verifier) && |
4938 | VerifyField<int32_t>(verifier, VT_RADIUS) && |
4939 | VerifyField<float>(verifier, VT_BIAS) && |
4940 | VerifyField<float>(verifier, VT_ALPHA) && |
4941 | VerifyField<float>(verifier, VT_BETA) && |
4942 | verifier.EndTable(); |
4943 | } |
4944 | LocalResponseNormalizationOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4945 | void UnPackTo(LocalResponseNormalizationOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
4946 | static flatbuffers::Offset<LocalResponseNormalizationOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LocalResponseNormalizationOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4947 | }; |
4948 | |
4949 | struct LocalResponseNormalizationOptionsBuilder { |
4950 | flatbuffers::FlatBufferBuilder &fbb_; |
4951 | flatbuffers::uoffset_t start_; |
4952 | void add_radius(int32_t radius) { |
4953 | fbb_.AddElement<int32_t>(LocalResponseNormalizationOptions::VT_RADIUS, radius, 0); |
4954 | } |
4955 | void add_bias(float bias) { |
4956 | fbb_.AddElement<float>(LocalResponseNormalizationOptions::VT_BIAS, bias, 0.0f); |
4957 | } |
4958 | void add_alpha(float alpha) { |
4959 | fbb_.AddElement<float>(LocalResponseNormalizationOptions::VT_ALPHA, alpha, 0.0f); |
4960 | } |
4961 | void add_beta(float beta) { |
4962 | fbb_.AddElement<float>(LocalResponseNormalizationOptions::VT_BETA, beta, 0.0f); |
4963 | } |
4964 | explicit LocalResponseNormalizationOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
4965 | : fbb_(_fbb) { |
4966 | start_ = fbb_.StartTable(); |
4967 | } |
4968 | LocalResponseNormalizationOptionsBuilder &operator=(const LocalResponseNormalizationOptionsBuilder &); |
4969 | flatbuffers::Offset<LocalResponseNormalizationOptions> Finish() { |
4970 | const auto end = fbb_.EndTable(start_); |
4971 | auto o = flatbuffers::Offset<LocalResponseNormalizationOptions>(end); |
4972 | return o; |
4973 | } |
4974 | }; |
4975 | |
4976 | inline flatbuffers::Offset<LocalResponseNormalizationOptions> CreateLocalResponseNormalizationOptions( |
4977 | flatbuffers::FlatBufferBuilder &_fbb, |
4978 | int32_t radius = 0, |
4979 | float bias = 0.0f, |
4980 | float alpha = 0.0f, |
4981 | float beta = 0.0f) { |
4982 | LocalResponseNormalizationOptionsBuilder builder_(_fbb); |
4983 | builder_.add_beta(beta); |
4984 | builder_.add_alpha(alpha); |
4985 | builder_.add_bias(bias); |
4986 | builder_.add_radius(radius); |
4987 | return builder_.Finish(); |
4988 | } |
4989 | |
4990 | flatbuffers::Offset<LocalResponseNormalizationOptions> CreateLocalResponseNormalizationOptions(flatbuffers::FlatBufferBuilder &_fbb, const LocalResponseNormalizationOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
4991 | |
4992 | struct LSTMOptionsT : public flatbuffers::NativeTable { |
4993 | typedef LSTMOptions TableType; |
4994 | tflite::ActivationFunctionType fused_activation_function; |
4995 | float cell_clip; |
4996 | float proj_clip; |
4997 | tflite::LSTMKernelType kernel_type; |
4998 | bool asymmetric_quantize_inputs; |
4999 | LSTMOptionsT() |
5000 | : fused_activation_function(tflite::ActivationFunctionType_NONE), |
5001 | cell_clip(0.0f), |
5002 | proj_clip(0.0f), |
5003 | kernel_type(tflite::LSTMKernelType_FULL), |
5004 | asymmetric_quantize_inputs(false) { |
5005 | } |
5006 | }; |
5007 | |
5008 | struct LSTMOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5009 | typedef LSTMOptionsT NativeTableType; |
5010 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5011 | VT_FUSED_ACTIVATION_FUNCTION = 4, |
5012 | VT_CELL_CLIP = 6, |
5013 | VT_PROJ_CLIP = 8, |
5014 | VT_KERNEL_TYPE = 10, |
5015 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 12 |
5016 | }; |
5017 | tflite::ActivationFunctionType fused_activation_function() const { |
5018 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
5019 | } |
5020 | float cell_clip() const { |
5021 | return GetField<float>(VT_CELL_CLIP, 0.0f); |
5022 | } |
5023 | float proj_clip() const { |
5024 | return GetField<float>(VT_PROJ_CLIP, 0.0f); |
5025 | } |
5026 | tflite::LSTMKernelType kernel_type() const { |
5027 | return static_cast<tflite::LSTMKernelType>(GetField<int8_t>(VT_KERNEL_TYPE, 0)); |
5028 | } |
5029 | bool asymmetric_quantize_inputs() const { |
5030 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
5031 | } |
5032 | bool Verify(flatbuffers::Verifier &verifier) const { |
5033 | return VerifyTableStart(verifier) && |
5034 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
5035 | VerifyField<float>(verifier, VT_CELL_CLIP) && |
5036 | VerifyField<float>(verifier, VT_PROJ_CLIP) && |
5037 | VerifyField<int8_t>(verifier, VT_KERNEL_TYPE) && |
5038 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
5039 | verifier.EndTable(); |
5040 | } |
5041 | LSTMOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5042 | void UnPackTo(LSTMOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5043 | static flatbuffers::Offset<LSTMOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LSTMOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5044 | }; |
5045 | |
5046 | struct LSTMOptionsBuilder { |
5047 | flatbuffers::FlatBufferBuilder &fbb_; |
5048 | flatbuffers::uoffset_t start_; |
5049 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
5050 | fbb_.AddElement<int8_t>(LSTMOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
5051 | } |
5052 | void add_cell_clip(float cell_clip) { |
5053 | fbb_.AddElement<float>(LSTMOptions::VT_CELL_CLIP, cell_clip, 0.0f); |
5054 | } |
5055 | void add_proj_clip(float proj_clip) { |
5056 | fbb_.AddElement<float>(LSTMOptions::VT_PROJ_CLIP, proj_clip, 0.0f); |
5057 | } |
5058 | void add_kernel_type(tflite::LSTMKernelType kernel_type) { |
5059 | fbb_.AddElement<int8_t>(LSTMOptions::VT_KERNEL_TYPE, static_cast<int8_t>(kernel_type), 0); |
5060 | } |
5061 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
5062 | fbb_.AddElement<uint8_t>(LSTMOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
5063 | } |
5064 | explicit LSTMOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5065 | : fbb_(_fbb) { |
5066 | start_ = fbb_.StartTable(); |
5067 | } |
5068 | LSTMOptionsBuilder &operator=(const LSTMOptionsBuilder &); |
5069 | flatbuffers::Offset<LSTMOptions> Finish() { |
5070 | const auto end = fbb_.EndTable(start_); |
5071 | auto o = flatbuffers::Offset<LSTMOptions>(end); |
5072 | return o; |
5073 | } |
5074 | }; |
5075 | |
5076 | inline flatbuffers::Offset<LSTMOptions> CreateLSTMOptions( |
5077 | flatbuffers::FlatBufferBuilder &_fbb, |
5078 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
5079 | float cell_clip = 0.0f, |
5080 | float proj_clip = 0.0f, |
5081 | tflite::LSTMKernelType kernel_type = tflite::LSTMKernelType_FULL, |
5082 | bool asymmetric_quantize_inputs = false) { |
5083 | LSTMOptionsBuilder builder_(_fbb); |
5084 | builder_.add_proj_clip(proj_clip); |
5085 | builder_.add_cell_clip(cell_clip); |
5086 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
5087 | builder_.add_kernel_type(kernel_type); |
5088 | builder_.add_fused_activation_function(fused_activation_function); |
5089 | return builder_.Finish(); |
5090 | } |
5091 | |
5092 | flatbuffers::Offset<LSTMOptions> CreateLSTMOptions(flatbuffers::FlatBufferBuilder &_fbb, const LSTMOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5093 | |
5094 | struct UnidirectionalSequenceLSTMOptionsT : public flatbuffers::NativeTable { |
5095 | typedef UnidirectionalSequenceLSTMOptions TableType; |
5096 | tflite::ActivationFunctionType fused_activation_function; |
5097 | float cell_clip; |
5098 | float proj_clip; |
5099 | bool time_major; |
5100 | bool asymmetric_quantize_inputs; |
5101 | UnidirectionalSequenceLSTMOptionsT() |
5102 | : fused_activation_function(tflite::ActivationFunctionType_NONE), |
5103 | cell_clip(0.0f), |
5104 | proj_clip(0.0f), |
5105 | time_major(false), |
5106 | asymmetric_quantize_inputs(false) { |
5107 | } |
5108 | }; |
5109 | |
5110 | struct UnidirectionalSequenceLSTMOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5111 | typedef UnidirectionalSequenceLSTMOptionsT NativeTableType; |
5112 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5113 | VT_FUSED_ACTIVATION_FUNCTION = 4, |
5114 | VT_CELL_CLIP = 6, |
5115 | VT_PROJ_CLIP = 8, |
5116 | VT_TIME_MAJOR = 10, |
5117 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 12 |
5118 | }; |
5119 | tflite::ActivationFunctionType fused_activation_function() const { |
5120 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
5121 | } |
5122 | float cell_clip() const { |
5123 | return GetField<float>(VT_CELL_CLIP, 0.0f); |
5124 | } |
5125 | float proj_clip() const { |
5126 | return GetField<float>(VT_PROJ_CLIP, 0.0f); |
5127 | } |
5128 | bool time_major() const { |
5129 | return GetField<uint8_t>(VT_TIME_MAJOR, 0) != 0; |
5130 | } |
5131 | bool asymmetric_quantize_inputs() const { |
5132 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
5133 | } |
5134 | bool Verify(flatbuffers::Verifier &verifier) const { |
5135 | return VerifyTableStart(verifier) && |
5136 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
5137 | VerifyField<float>(verifier, VT_CELL_CLIP) && |
5138 | VerifyField<float>(verifier, VT_PROJ_CLIP) && |
5139 | VerifyField<uint8_t>(verifier, VT_TIME_MAJOR) && |
5140 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
5141 | verifier.EndTable(); |
5142 | } |
5143 | UnidirectionalSequenceLSTMOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5144 | void UnPackTo(UnidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5145 | static flatbuffers::Offset<UnidirectionalSequenceLSTMOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const UnidirectionalSequenceLSTMOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5146 | }; |
5147 | |
5148 | struct UnidirectionalSequenceLSTMOptionsBuilder { |
5149 | flatbuffers::FlatBufferBuilder &fbb_; |
5150 | flatbuffers::uoffset_t start_; |
5151 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
5152 | fbb_.AddElement<int8_t>(UnidirectionalSequenceLSTMOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
5153 | } |
5154 | void add_cell_clip(float cell_clip) { |
5155 | fbb_.AddElement<float>(UnidirectionalSequenceLSTMOptions::VT_CELL_CLIP, cell_clip, 0.0f); |
5156 | } |
5157 | void add_proj_clip(float proj_clip) { |
5158 | fbb_.AddElement<float>(UnidirectionalSequenceLSTMOptions::VT_PROJ_CLIP, proj_clip, 0.0f); |
5159 | } |
5160 | void add_time_major(bool time_major) { |
5161 | fbb_.AddElement<uint8_t>(UnidirectionalSequenceLSTMOptions::VT_TIME_MAJOR, static_cast<uint8_t>(time_major), 0); |
5162 | } |
5163 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
5164 | fbb_.AddElement<uint8_t>(UnidirectionalSequenceLSTMOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
5165 | } |
5166 | explicit UnidirectionalSequenceLSTMOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5167 | : fbb_(_fbb) { |
5168 | start_ = fbb_.StartTable(); |
5169 | } |
5170 | UnidirectionalSequenceLSTMOptionsBuilder &operator=(const UnidirectionalSequenceLSTMOptionsBuilder &); |
5171 | flatbuffers::Offset<UnidirectionalSequenceLSTMOptions> Finish() { |
5172 | const auto end = fbb_.EndTable(start_); |
5173 | auto o = flatbuffers::Offset<UnidirectionalSequenceLSTMOptions>(end); |
5174 | return o; |
5175 | } |
5176 | }; |
5177 | |
5178 | inline flatbuffers::Offset<UnidirectionalSequenceLSTMOptions> CreateUnidirectionalSequenceLSTMOptions( |
5179 | flatbuffers::FlatBufferBuilder &_fbb, |
5180 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
5181 | float cell_clip = 0.0f, |
5182 | float proj_clip = 0.0f, |
5183 | bool time_major = false, |
5184 | bool asymmetric_quantize_inputs = false) { |
5185 | UnidirectionalSequenceLSTMOptionsBuilder builder_(_fbb); |
5186 | builder_.add_proj_clip(proj_clip); |
5187 | builder_.add_cell_clip(cell_clip); |
5188 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
5189 | builder_.add_time_major(time_major); |
5190 | builder_.add_fused_activation_function(fused_activation_function); |
5191 | return builder_.Finish(); |
5192 | } |
5193 | |
5194 | flatbuffers::Offset<UnidirectionalSequenceLSTMOptions> CreateUnidirectionalSequenceLSTMOptions(flatbuffers::FlatBufferBuilder &_fbb, const UnidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5195 | |
5196 | struct BidirectionalSequenceLSTMOptionsT : public flatbuffers::NativeTable { |
5197 | typedef BidirectionalSequenceLSTMOptions TableType; |
5198 | tflite::ActivationFunctionType fused_activation_function; |
5199 | float cell_clip; |
5200 | float proj_clip; |
5201 | bool merge_outputs; |
5202 | bool time_major; |
5203 | bool asymmetric_quantize_inputs; |
5204 | BidirectionalSequenceLSTMOptionsT() |
5205 | : fused_activation_function(tflite::ActivationFunctionType_NONE), |
5206 | cell_clip(0.0f), |
5207 | proj_clip(0.0f), |
5208 | merge_outputs(false), |
5209 | time_major(true), |
5210 | asymmetric_quantize_inputs(false) { |
5211 | } |
5212 | }; |
5213 | |
5214 | struct BidirectionalSequenceLSTMOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5215 | typedef BidirectionalSequenceLSTMOptionsT NativeTableType; |
5216 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5217 | VT_FUSED_ACTIVATION_FUNCTION = 4, |
5218 | VT_CELL_CLIP = 6, |
5219 | VT_PROJ_CLIP = 8, |
5220 | VT_MERGE_OUTPUTS = 10, |
5221 | VT_TIME_MAJOR = 12, |
5222 | VT_ASYMMETRIC_QUANTIZE_INPUTS = 14 |
5223 | }; |
5224 | tflite::ActivationFunctionType fused_activation_function() const { |
5225 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
5226 | } |
5227 | float cell_clip() const { |
5228 | return GetField<float>(VT_CELL_CLIP, 0.0f); |
5229 | } |
5230 | float proj_clip() const { |
5231 | return GetField<float>(VT_PROJ_CLIP, 0.0f); |
5232 | } |
5233 | bool merge_outputs() const { |
5234 | return GetField<uint8_t>(VT_MERGE_OUTPUTS, 0) != 0; |
5235 | } |
5236 | bool time_major() const { |
5237 | return GetField<uint8_t>(VT_TIME_MAJOR, 1) != 0; |
5238 | } |
5239 | bool asymmetric_quantize_inputs() const { |
5240 | return GetField<uint8_t>(VT_ASYMMETRIC_QUANTIZE_INPUTS, 0) != 0; |
5241 | } |
5242 | bool Verify(flatbuffers::Verifier &verifier) const { |
5243 | return VerifyTableStart(verifier) && |
5244 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
5245 | VerifyField<float>(verifier, VT_CELL_CLIP) && |
5246 | VerifyField<float>(verifier, VT_PROJ_CLIP) && |
5247 | VerifyField<uint8_t>(verifier, VT_MERGE_OUTPUTS) && |
5248 | VerifyField<uint8_t>(verifier, VT_TIME_MAJOR) && |
5249 | VerifyField<uint8_t>(verifier, VT_ASYMMETRIC_QUANTIZE_INPUTS) && |
5250 | verifier.EndTable(); |
5251 | } |
5252 | BidirectionalSequenceLSTMOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5253 | void UnPackTo(BidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5254 | static flatbuffers::Offset<BidirectionalSequenceLSTMOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceLSTMOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5255 | }; |
5256 | |
5257 | struct BidirectionalSequenceLSTMOptionsBuilder { |
5258 | flatbuffers::FlatBufferBuilder &fbb_; |
5259 | flatbuffers::uoffset_t start_; |
5260 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
5261 | fbb_.AddElement<int8_t>(BidirectionalSequenceLSTMOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
5262 | } |
5263 | void add_cell_clip(float cell_clip) { |
5264 | fbb_.AddElement<float>(BidirectionalSequenceLSTMOptions::VT_CELL_CLIP, cell_clip, 0.0f); |
5265 | } |
5266 | void add_proj_clip(float proj_clip) { |
5267 | fbb_.AddElement<float>(BidirectionalSequenceLSTMOptions::VT_PROJ_CLIP, proj_clip, 0.0f); |
5268 | } |
5269 | void add_merge_outputs(bool merge_outputs) { |
5270 | fbb_.AddElement<uint8_t>(BidirectionalSequenceLSTMOptions::VT_MERGE_OUTPUTS, static_cast<uint8_t>(merge_outputs), 0); |
5271 | } |
5272 | void add_time_major(bool time_major) { |
5273 | fbb_.AddElement<uint8_t>(BidirectionalSequenceLSTMOptions::VT_TIME_MAJOR, static_cast<uint8_t>(time_major), 1); |
5274 | } |
5275 | void add_asymmetric_quantize_inputs(bool asymmetric_quantize_inputs) { |
5276 | fbb_.AddElement<uint8_t>(BidirectionalSequenceLSTMOptions::VT_ASYMMETRIC_QUANTIZE_INPUTS, static_cast<uint8_t>(asymmetric_quantize_inputs), 0); |
5277 | } |
5278 | explicit BidirectionalSequenceLSTMOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5279 | : fbb_(_fbb) { |
5280 | start_ = fbb_.StartTable(); |
5281 | } |
5282 | BidirectionalSequenceLSTMOptionsBuilder &operator=(const BidirectionalSequenceLSTMOptionsBuilder &); |
5283 | flatbuffers::Offset<BidirectionalSequenceLSTMOptions> Finish() { |
5284 | const auto end = fbb_.EndTable(start_); |
5285 | auto o = flatbuffers::Offset<BidirectionalSequenceLSTMOptions>(end); |
5286 | return o; |
5287 | } |
5288 | }; |
5289 | |
5290 | inline flatbuffers::Offset<BidirectionalSequenceLSTMOptions> CreateBidirectionalSequenceLSTMOptions( |
5291 | flatbuffers::FlatBufferBuilder &_fbb, |
5292 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE, |
5293 | float cell_clip = 0.0f, |
5294 | float proj_clip = 0.0f, |
5295 | bool merge_outputs = false, |
5296 | bool time_major = true, |
5297 | bool asymmetric_quantize_inputs = false) { |
5298 | BidirectionalSequenceLSTMOptionsBuilder builder_(_fbb); |
5299 | builder_.add_proj_clip(proj_clip); |
5300 | builder_.add_cell_clip(cell_clip); |
5301 | builder_.add_asymmetric_quantize_inputs(asymmetric_quantize_inputs); |
5302 | builder_.add_time_major(time_major); |
5303 | builder_.add_merge_outputs(merge_outputs); |
5304 | builder_.add_fused_activation_function(fused_activation_function); |
5305 | return builder_.Finish(); |
5306 | } |
5307 | |
5308 | flatbuffers::Offset<BidirectionalSequenceLSTMOptions> CreateBidirectionalSequenceLSTMOptions(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5309 | |
5310 | struct ResizeBilinearOptionsT : public flatbuffers::NativeTable { |
5311 | typedef ResizeBilinearOptions TableType; |
5312 | bool align_corners; |
5313 | bool half_pixel_centers; |
5314 | ResizeBilinearOptionsT() |
5315 | : align_corners(false), |
5316 | half_pixel_centers(false) { |
5317 | } |
5318 | }; |
5319 | |
5320 | struct ResizeBilinearOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5321 | typedef ResizeBilinearOptionsT NativeTableType; |
5322 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5323 | VT_ALIGN_CORNERS = 8, |
5324 | VT_HALF_PIXEL_CENTERS = 10 |
5325 | }; |
5326 | bool align_corners() const { |
5327 | return GetField<uint8_t>(VT_ALIGN_CORNERS, 0) != 0; |
5328 | } |
5329 | bool half_pixel_centers() const { |
5330 | return GetField<uint8_t>(VT_HALF_PIXEL_CENTERS, 0) != 0; |
5331 | } |
5332 | bool Verify(flatbuffers::Verifier &verifier) const { |
5333 | return VerifyTableStart(verifier) && |
5334 | VerifyField<uint8_t>(verifier, VT_ALIGN_CORNERS) && |
5335 | VerifyField<uint8_t>(verifier, VT_HALF_PIXEL_CENTERS) && |
5336 | verifier.EndTable(); |
5337 | } |
5338 | ResizeBilinearOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5339 | void UnPackTo(ResizeBilinearOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5340 | static flatbuffers::Offset<ResizeBilinearOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ResizeBilinearOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5341 | }; |
5342 | |
5343 | struct ResizeBilinearOptionsBuilder { |
5344 | flatbuffers::FlatBufferBuilder &fbb_; |
5345 | flatbuffers::uoffset_t start_; |
5346 | void add_align_corners(bool align_corners) { |
5347 | fbb_.AddElement<uint8_t>(ResizeBilinearOptions::VT_ALIGN_CORNERS, static_cast<uint8_t>(align_corners), 0); |
5348 | } |
5349 | void add_half_pixel_centers(bool half_pixel_centers) { |
5350 | fbb_.AddElement<uint8_t>(ResizeBilinearOptions::VT_HALF_PIXEL_CENTERS, static_cast<uint8_t>(half_pixel_centers), 0); |
5351 | } |
5352 | explicit ResizeBilinearOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5353 | : fbb_(_fbb) { |
5354 | start_ = fbb_.StartTable(); |
5355 | } |
5356 | ResizeBilinearOptionsBuilder &operator=(const ResizeBilinearOptionsBuilder &); |
5357 | flatbuffers::Offset<ResizeBilinearOptions> Finish() { |
5358 | const auto end = fbb_.EndTable(start_); |
5359 | auto o = flatbuffers::Offset<ResizeBilinearOptions>(end); |
5360 | return o; |
5361 | } |
5362 | }; |
5363 | |
5364 | inline flatbuffers::Offset<ResizeBilinearOptions> CreateResizeBilinearOptions( |
5365 | flatbuffers::FlatBufferBuilder &_fbb, |
5366 | bool align_corners = false, |
5367 | bool half_pixel_centers = false) { |
5368 | ResizeBilinearOptionsBuilder builder_(_fbb); |
5369 | builder_.add_half_pixel_centers(half_pixel_centers); |
5370 | builder_.add_align_corners(align_corners); |
5371 | return builder_.Finish(); |
5372 | } |
5373 | |
5374 | flatbuffers::Offset<ResizeBilinearOptions> CreateResizeBilinearOptions(flatbuffers::FlatBufferBuilder &_fbb, const ResizeBilinearOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5375 | |
5376 | struct ResizeNearestNeighborOptionsT : public flatbuffers::NativeTable { |
5377 | typedef ResizeNearestNeighborOptions TableType; |
5378 | bool align_corners; |
5379 | bool half_pixel_centers; |
5380 | ResizeNearestNeighborOptionsT() |
5381 | : align_corners(false), |
5382 | half_pixel_centers(false) { |
5383 | } |
5384 | }; |
5385 | |
5386 | struct ResizeNearestNeighborOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5387 | typedef ResizeNearestNeighborOptionsT NativeTableType; |
5388 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5389 | VT_ALIGN_CORNERS = 4, |
5390 | VT_HALF_PIXEL_CENTERS = 6 |
5391 | }; |
5392 | bool align_corners() const { |
5393 | return GetField<uint8_t>(VT_ALIGN_CORNERS, 0) != 0; |
5394 | } |
5395 | bool half_pixel_centers() const { |
5396 | return GetField<uint8_t>(VT_HALF_PIXEL_CENTERS, 0) != 0; |
5397 | } |
5398 | bool Verify(flatbuffers::Verifier &verifier) const { |
5399 | return VerifyTableStart(verifier) && |
5400 | VerifyField<uint8_t>(verifier, VT_ALIGN_CORNERS) && |
5401 | VerifyField<uint8_t>(verifier, VT_HALF_PIXEL_CENTERS) && |
5402 | verifier.EndTable(); |
5403 | } |
5404 | ResizeNearestNeighborOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5405 | void UnPackTo(ResizeNearestNeighborOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5406 | static flatbuffers::Offset<ResizeNearestNeighborOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ResizeNearestNeighborOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5407 | }; |
5408 | |
5409 | struct ResizeNearestNeighborOptionsBuilder { |
5410 | flatbuffers::FlatBufferBuilder &fbb_; |
5411 | flatbuffers::uoffset_t start_; |
5412 | void add_align_corners(bool align_corners) { |
5413 | fbb_.AddElement<uint8_t>(ResizeNearestNeighborOptions::VT_ALIGN_CORNERS, static_cast<uint8_t>(align_corners), 0); |
5414 | } |
5415 | void add_half_pixel_centers(bool half_pixel_centers) { |
5416 | fbb_.AddElement<uint8_t>(ResizeNearestNeighborOptions::VT_HALF_PIXEL_CENTERS, static_cast<uint8_t>(half_pixel_centers), 0); |
5417 | } |
5418 | explicit ResizeNearestNeighborOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5419 | : fbb_(_fbb) { |
5420 | start_ = fbb_.StartTable(); |
5421 | } |
5422 | ResizeNearestNeighborOptionsBuilder &operator=(const ResizeNearestNeighborOptionsBuilder &); |
5423 | flatbuffers::Offset<ResizeNearestNeighborOptions> Finish() { |
5424 | const auto end = fbb_.EndTable(start_); |
5425 | auto o = flatbuffers::Offset<ResizeNearestNeighborOptions>(end); |
5426 | return o; |
5427 | } |
5428 | }; |
5429 | |
5430 | inline flatbuffers::Offset<ResizeNearestNeighborOptions> CreateResizeNearestNeighborOptions( |
5431 | flatbuffers::FlatBufferBuilder &_fbb, |
5432 | bool align_corners = false, |
5433 | bool half_pixel_centers = false) { |
5434 | ResizeNearestNeighborOptionsBuilder builder_(_fbb); |
5435 | builder_.add_half_pixel_centers(half_pixel_centers); |
5436 | builder_.add_align_corners(align_corners); |
5437 | return builder_.Finish(); |
5438 | } |
5439 | |
5440 | flatbuffers::Offset<ResizeNearestNeighborOptions> CreateResizeNearestNeighborOptions(flatbuffers::FlatBufferBuilder &_fbb, const ResizeNearestNeighborOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5441 | |
5442 | struct CallOptionsT : public flatbuffers::NativeTable { |
5443 | typedef CallOptions TableType; |
5444 | uint32_t subgraph; |
5445 | CallOptionsT() |
5446 | : subgraph(0) { |
5447 | } |
5448 | }; |
5449 | |
5450 | struct CallOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5451 | typedef CallOptionsT NativeTableType; |
5452 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5453 | VT_SUBGRAPH = 4 |
5454 | }; |
5455 | uint32_t subgraph() const { |
5456 | return GetField<uint32_t>(VT_SUBGRAPH, 0); |
5457 | } |
5458 | bool Verify(flatbuffers::Verifier &verifier) const { |
5459 | return VerifyTableStart(verifier) && |
5460 | VerifyField<uint32_t>(verifier, VT_SUBGRAPH) && |
5461 | verifier.EndTable(); |
5462 | } |
5463 | CallOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5464 | void UnPackTo(CallOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5465 | static flatbuffers::Offset<CallOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const CallOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5466 | }; |
5467 | |
5468 | struct CallOptionsBuilder { |
5469 | flatbuffers::FlatBufferBuilder &fbb_; |
5470 | flatbuffers::uoffset_t start_; |
5471 | void add_subgraph(uint32_t subgraph) { |
5472 | fbb_.AddElement<uint32_t>(CallOptions::VT_SUBGRAPH, subgraph, 0); |
5473 | } |
5474 | explicit CallOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5475 | : fbb_(_fbb) { |
5476 | start_ = fbb_.StartTable(); |
5477 | } |
5478 | CallOptionsBuilder &operator=(const CallOptionsBuilder &); |
5479 | flatbuffers::Offset<CallOptions> Finish() { |
5480 | const auto end = fbb_.EndTable(start_); |
5481 | auto o = flatbuffers::Offset<CallOptions>(end); |
5482 | return o; |
5483 | } |
5484 | }; |
5485 | |
5486 | inline flatbuffers::Offset<CallOptions> CreateCallOptions( |
5487 | flatbuffers::FlatBufferBuilder &_fbb, |
5488 | uint32_t subgraph = 0) { |
5489 | CallOptionsBuilder builder_(_fbb); |
5490 | builder_.add_subgraph(subgraph); |
5491 | return builder_.Finish(); |
5492 | } |
5493 | |
5494 | flatbuffers::Offset<CallOptions> CreateCallOptions(flatbuffers::FlatBufferBuilder &_fbb, const CallOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5495 | |
5496 | struct PadOptionsT : public flatbuffers::NativeTable { |
5497 | typedef PadOptions TableType; |
5498 | PadOptionsT() { |
5499 | } |
5500 | }; |
5501 | |
5502 | struct PadOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5503 | typedef PadOptionsT NativeTableType; |
5504 | bool Verify(flatbuffers::Verifier &verifier) const { |
5505 | return VerifyTableStart(verifier) && |
5506 | verifier.EndTable(); |
5507 | } |
5508 | PadOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5509 | void UnPackTo(PadOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5510 | static flatbuffers::Offset<PadOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const PadOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5511 | }; |
5512 | |
5513 | struct PadOptionsBuilder { |
5514 | flatbuffers::FlatBufferBuilder &fbb_; |
5515 | flatbuffers::uoffset_t start_; |
5516 | explicit PadOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5517 | : fbb_(_fbb) { |
5518 | start_ = fbb_.StartTable(); |
5519 | } |
5520 | PadOptionsBuilder &operator=(const PadOptionsBuilder &); |
5521 | flatbuffers::Offset<PadOptions> Finish() { |
5522 | const auto end = fbb_.EndTable(start_); |
5523 | auto o = flatbuffers::Offset<PadOptions>(end); |
5524 | return o; |
5525 | } |
5526 | }; |
5527 | |
5528 | inline flatbuffers::Offset<PadOptions> CreatePadOptions( |
5529 | flatbuffers::FlatBufferBuilder &_fbb) { |
5530 | PadOptionsBuilder builder_(_fbb); |
5531 | return builder_.Finish(); |
5532 | } |
5533 | |
5534 | flatbuffers::Offset<PadOptions> CreatePadOptions(flatbuffers::FlatBufferBuilder &_fbb, const PadOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5535 | |
5536 | struct PadV2OptionsT : public flatbuffers::NativeTable { |
5537 | typedef PadV2Options TableType; |
5538 | PadV2OptionsT() { |
5539 | } |
5540 | }; |
5541 | |
5542 | struct PadV2Options FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5543 | typedef PadV2OptionsT NativeTableType; |
5544 | bool Verify(flatbuffers::Verifier &verifier) const { |
5545 | return VerifyTableStart(verifier) && |
5546 | verifier.EndTable(); |
5547 | } |
5548 | PadV2OptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5549 | void UnPackTo(PadV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5550 | static flatbuffers::Offset<PadV2Options> Pack(flatbuffers::FlatBufferBuilder &_fbb, const PadV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5551 | }; |
5552 | |
5553 | struct PadV2OptionsBuilder { |
5554 | flatbuffers::FlatBufferBuilder &fbb_; |
5555 | flatbuffers::uoffset_t start_; |
5556 | explicit PadV2OptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5557 | : fbb_(_fbb) { |
5558 | start_ = fbb_.StartTable(); |
5559 | } |
5560 | PadV2OptionsBuilder &operator=(const PadV2OptionsBuilder &); |
5561 | flatbuffers::Offset<PadV2Options> Finish() { |
5562 | const auto end = fbb_.EndTable(start_); |
5563 | auto o = flatbuffers::Offset<PadV2Options>(end); |
5564 | return o; |
5565 | } |
5566 | }; |
5567 | |
5568 | inline flatbuffers::Offset<PadV2Options> CreatePadV2Options( |
5569 | flatbuffers::FlatBufferBuilder &_fbb) { |
5570 | PadV2OptionsBuilder builder_(_fbb); |
5571 | return builder_.Finish(); |
5572 | } |
5573 | |
5574 | flatbuffers::Offset<PadV2Options> CreatePadV2Options(flatbuffers::FlatBufferBuilder &_fbb, const PadV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5575 | |
5576 | struct ReshapeOptionsT : public flatbuffers::NativeTable { |
5577 | typedef ReshapeOptions TableType; |
5578 | std::vector<int32_t> new_shape; |
5579 | ReshapeOptionsT() { |
5580 | } |
5581 | }; |
5582 | |
5583 | struct ReshapeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5584 | typedef ReshapeOptionsT NativeTableType; |
5585 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5586 | VT_NEW_SHAPE = 4 |
5587 | }; |
5588 | const flatbuffers::Vector<int32_t> *new_shape() const { |
5589 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_NEW_SHAPE); |
5590 | } |
5591 | bool Verify(flatbuffers::Verifier &verifier) const { |
5592 | return VerifyTableStart(verifier) && |
5593 | VerifyOffset(verifier, VT_NEW_SHAPE) && |
5594 | verifier.VerifyVector(new_shape()) && |
5595 | verifier.EndTable(); |
5596 | } |
5597 | ReshapeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5598 | void UnPackTo(ReshapeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5599 | static flatbuffers::Offset<ReshapeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReshapeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5600 | }; |
5601 | |
5602 | struct ReshapeOptionsBuilder { |
5603 | flatbuffers::FlatBufferBuilder &fbb_; |
5604 | flatbuffers::uoffset_t start_; |
5605 | void add_new_shape(flatbuffers::Offset<flatbuffers::Vector<int32_t>> new_shape) { |
5606 | fbb_.AddOffset(ReshapeOptions::VT_NEW_SHAPE, new_shape); |
5607 | } |
5608 | explicit ReshapeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5609 | : fbb_(_fbb) { |
5610 | start_ = fbb_.StartTable(); |
5611 | } |
5612 | ReshapeOptionsBuilder &operator=(const ReshapeOptionsBuilder &); |
5613 | flatbuffers::Offset<ReshapeOptions> Finish() { |
5614 | const auto end = fbb_.EndTable(start_); |
5615 | auto o = flatbuffers::Offset<ReshapeOptions>(end); |
5616 | return o; |
5617 | } |
5618 | }; |
5619 | |
5620 | inline flatbuffers::Offset<ReshapeOptions> CreateReshapeOptions( |
5621 | flatbuffers::FlatBufferBuilder &_fbb, |
5622 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> new_shape = 0) { |
5623 | ReshapeOptionsBuilder builder_(_fbb); |
5624 | builder_.add_new_shape(new_shape); |
5625 | return builder_.Finish(); |
5626 | } |
5627 | |
5628 | inline flatbuffers::Offset<ReshapeOptions> CreateReshapeOptionsDirect( |
5629 | flatbuffers::FlatBufferBuilder &_fbb, |
5630 | const std::vector<int32_t> *new_shape = nullptr) { |
5631 | auto new_shape__ = new_shape ? _fbb.CreateVector<int32_t>(*new_shape) : 0; |
5632 | return tflite::CreateReshapeOptions( |
5633 | _fbb, |
5634 | new_shape__); |
5635 | } |
5636 | |
5637 | flatbuffers::Offset<ReshapeOptions> CreateReshapeOptions(flatbuffers::FlatBufferBuilder &_fbb, const ReshapeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5638 | |
5639 | struct SpaceToBatchNDOptionsT : public flatbuffers::NativeTable { |
5640 | typedef SpaceToBatchNDOptions TableType; |
5641 | SpaceToBatchNDOptionsT() { |
5642 | } |
5643 | }; |
5644 | |
5645 | struct SpaceToBatchNDOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5646 | typedef SpaceToBatchNDOptionsT NativeTableType; |
5647 | bool Verify(flatbuffers::Verifier &verifier) const { |
5648 | return VerifyTableStart(verifier) && |
5649 | verifier.EndTable(); |
5650 | } |
5651 | SpaceToBatchNDOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5652 | void UnPackTo(SpaceToBatchNDOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5653 | static flatbuffers::Offset<SpaceToBatchNDOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToBatchNDOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5654 | }; |
5655 | |
5656 | struct SpaceToBatchNDOptionsBuilder { |
5657 | flatbuffers::FlatBufferBuilder &fbb_; |
5658 | flatbuffers::uoffset_t start_; |
5659 | explicit SpaceToBatchNDOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5660 | : fbb_(_fbb) { |
5661 | start_ = fbb_.StartTable(); |
5662 | } |
5663 | SpaceToBatchNDOptionsBuilder &operator=(const SpaceToBatchNDOptionsBuilder &); |
5664 | flatbuffers::Offset<SpaceToBatchNDOptions> Finish() { |
5665 | const auto end = fbb_.EndTable(start_); |
5666 | auto o = flatbuffers::Offset<SpaceToBatchNDOptions>(end); |
5667 | return o; |
5668 | } |
5669 | }; |
5670 | |
5671 | inline flatbuffers::Offset<SpaceToBatchNDOptions> CreateSpaceToBatchNDOptions( |
5672 | flatbuffers::FlatBufferBuilder &_fbb) { |
5673 | SpaceToBatchNDOptionsBuilder builder_(_fbb); |
5674 | return builder_.Finish(); |
5675 | } |
5676 | |
5677 | flatbuffers::Offset<SpaceToBatchNDOptions> CreateSpaceToBatchNDOptions(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToBatchNDOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5678 | |
5679 | struct BatchToSpaceNDOptionsT : public flatbuffers::NativeTable { |
5680 | typedef BatchToSpaceNDOptions TableType; |
5681 | BatchToSpaceNDOptionsT() { |
5682 | } |
5683 | }; |
5684 | |
5685 | struct BatchToSpaceNDOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5686 | typedef BatchToSpaceNDOptionsT NativeTableType; |
5687 | bool Verify(flatbuffers::Verifier &verifier) const { |
5688 | return VerifyTableStart(verifier) && |
5689 | verifier.EndTable(); |
5690 | } |
5691 | BatchToSpaceNDOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5692 | void UnPackTo(BatchToSpaceNDOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5693 | static flatbuffers::Offset<BatchToSpaceNDOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const BatchToSpaceNDOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5694 | }; |
5695 | |
5696 | struct BatchToSpaceNDOptionsBuilder { |
5697 | flatbuffers::FlatBufferBuilder &fbb_; |
5698 | flatbuffers::uoffset_t start_; |
5699 | explicit BatchToSpaceNDOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5700 | : fbb_(_fbb) { |
5701 | start_ = fbb_.StartTable(); |
5702 | } |
5703 | BatchToSpaceNDOptionsBuilder &operator=(const BatchToSpaceNDOptionsBuilder &); |
5704 | flatbuffers::Offset<BatchToSpaceNDOptions> Finish() { |
5705 | const auto end = fbb_.EndTable(start_); |
5706 | auto o = flatbuffers::Offset<BatchToSpaceNDOptions>(end); |
5707 | return o; |
5708 | } |
5709 | }; |
5710 | |
5711 | inline flatbuffers::Offset<BatchToSpaceNDOptions> CreateBatchToSpaceNDOptions( |
5712 | flatbuffers::FlatBufferBuilder &_fbb) { |
5713 | BatchToSpaceNDOptionsBuilder builder_(_fbb); |
5714 | return builder_.Finish(); |
5715 | } |
5716 | |
5717 | flatbuffers::Offset<BatchToSpaceNDOptions> CreateBatchToSpaceNDOptions(flatbuffers::FlatBufferBuilder &_fbb, const BatchToSpaceNDOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5718 | |
5719 | struct SkipGramOptionsT : public flatbuffers::NativeTable { |
5720 | typedef SkipGramOptions TableType; |
5721 | int32_t ngram_size; |
5722 | int32_t max_skip_size; |
5723 | bool include_all_ngrams; |
5724 | SkipGramOptionsT() |
5725 | : ngram_size(0), |
5726 | max_skip_size(0), |
5727 | include_all_ngrams(false) { |
5728 | } |
5729 | }; |
5730 | |
5731 | struct SkipGramOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5732 | typedef SkipGramOptionsT NativeTableType; |
5733 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5734 | VT_NGRAM_SIZE = 4, |
5735 | VT_MAX_SKIP_SIZE = 6, |
5736 | VT_INCLUDE_ALL_NGRAMS = 8 |
5737 | }; |
5738 | int32_t ngram_size() const { |
5739 | return GetField<int32_t>(VT_NGRAM_SIZE, 0); |
5740 | } |
5741 | int32_t max_skip_size() const { |
5742 | return GetField<int32_t>(VT_MAX_SKIP_SIZE, 0); |
5743 | } |
5744 | bool include_all_ngrams() const { |
5745 | return GetField<uint8_t>(VT_INCLUDE_ALL_NGRAMS, 0) != 0; |
5746 | } |
5747 | bool Verify(flatbuffers::Verifier &verifier) const { |
5748 | return VerifyTableStart(verifier) && |
5749 | VerifyField<int32_t>(verifier, VT_NGRAM_SIZE) && |
5750 | VerifyField<int32_t>(verifier, VT_MAX_SKIP_SIZE) && |
5751 | VerifyField<uint8_t>(verifier, VT_INCLUDE_ALL_NGRAMS) && |
5752 | verifier.EndTable(); |
5753 | } |
5754 | SkipGramOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5755 | void UnPackTo(SkipGramOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5756 | static flatbuffers::Offset<SkipGramOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SkipGramOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5757 | }; |
5758 | |
5759 | struct SkipGramOptionsBuilder { |
5760 | flatbuffers::FlatBufferBuilder &fbb_; |
5761 | flatbuffers::uoffset_t start_; |
5762 | void add_ngram_size(int32_t ngram_size) { |
5763 | fbb_.AddElement<int32_t>(SkipGramOptions::VT_NGRAM_SIZE, ngram_size, 0); |
5764 | } |
5765 | void add_max_skip_size(int32_t max_skip_size) { |
5766 | fbb_.AddElement<int32_t>(SkipGramOptions::VT_MAX_SKIP_SIZE, max_skip_size, 0); |
5767 | } |
5768 | void add_include_all_ngrams(bool include_all_ngrams) { |
5769 | fbb_.AddElement<uint8_t>(SkipGramOptions::VT_INCLUDE_ALL_NGRAMS, static_cast<uint8_t>(include_all_ngrams), 0); |
5770 | } |
5771 | explicit SkipGramOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5772 | : fbb_(_fbb) { |
5773 | start_ = fbb_.StartTable(); |
5774 | } |
5775 | SkipGramOptionsBuilder &operator=(const SkipGramOptionsBuilder &); |
5776 | flatbuffers::Offset<SkipGramOptions> Finish() { |
5777 | const auto end = fbb_.EndTable(start_); |
5778 | auto o = flatbuffers::Offset<SkipGramOptions>(end); |
5779 | return o; |
5780 | } |
5781 | }; |
5782 | |
5783 | inline flatbuffers::Offset<SkipGramOptions> CreateSkipGramOptions( |
5784 | flatbuffers::FlatBufferBuilder &_fbb, |
5785 | int32_t ngram_size = 0, |
5786 | int32_t max_skip_size = 0, |
5787 | bool include_all_ngrams = false) { |
5788 | SkipGramOptionsBuilder builder_(_fbb); |
5789 | builder_.add_max_skip_size(max_skip_size); |
5790 | builder_.add_ngram_size(ngram_size); |
5791 | builder_.add_include_all_ngrams(include_all_ngrams); |
5792 | return builder_.Finish(); |
5793 | } |
5794 | |
5795 | flatbuffers::Offset<SkipGramOptions> CreateSkipGramOptions(flatbuffers::FlatBufferBuilder &_fbb, const SkipGramOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5796 | |
5797 | struct SpaceToDepthOptionsT : public flatbuffers::NativeTable { |
5798 | typedef SpaceToDepthOptions TableType; |
5799 | int32_t block_size; |
5800 | SpaceToDepthOptionsT() |
5801 | : block_size(0) { |
5802 | } |
5803 | }; |
5804 | |
5805 | struct SpaceToDepthOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5806 | typedef SpaceToDepthOptionsT NativeTableType; |
5807 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5808 | VT_BLOCK_SIZE = 4 |
5809 | }; |
5810 | int32_t block_size() const { |
5811 | return GetField<int32_t>(VT_BLOCK_SIZE, 0); |
5812 | } |
5813 | bool Verify(flatbuffers::Verifier &verifier) const { |
5814 | return VerifyTableStart(verifier) && |
5815 | VerifyField<int32_t>(verifier, VT_BLOCK_SIZE) && |
5816 | verifier.EndTable(); |
5817 | } |
5818 | SpaceToDepthOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5819 | void UnPackTo(SpaceToDepthOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5820 | static flatbuffers::Offset<SpaceToDepthOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToDepthOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5821 | }; |
5822 | |
5823 | struct SpaceToDepthOptionsBuilder { |
5824 | flatbuffers::FlatBufferBuilder &fbb_; |
5825 | flatbuffers::uoffset_t start_; |
5826 | void add_block_size(int32_t block_size) { |
5827 | fbb_.AddElement<int32_t>(SpaceToDepthOptions::VT_BLOCK_SIZE, block_size, 0); |
5828 | } |
5829 | explicit SpaceToDepthOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5830 | : fbb_(_fbb) { |
5831 | start_ = fbb_.StartTable(); |
5832 | } |
5833 | SpaceToDepthOptionsBuilder &operator=(const SpaceToDepthOptionsBuilder &); |
5834 | flatbuffers::Offset<SpaceToDepthOptions> Finish() { |
5835 | const auto end = fbb_.EndTable(start_); |
5836 | auto o = flatbuffers::Offset<SpaceToDepthOptions>(end); |
5837 | return o; |
5838 | } |
5839 | }; |
5840 | |
5841 | inline flatbuffers::Offset<SpaceToDepthOptions> CreateSpaceToDepthOptions( |
5842 | flatbuffers::FlatBufferBuilder &_fbb, |
5843 | int32_t block_size = 0) { |
5844 | SpaceToDepthOptionsBuilder builder_(_fbb); |
5845 | builder_.add_block_size(block_size); |
5846 | return builder_.Finish(); |
5847 | } |
5848 | |
5849 | flatbuffers::Offset<SpaceToDepthOptions> CreateSpaceToDepthOptions(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToDepthOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5850 | |
5851 | struct DepthToSpaceOptionsT : public flatbuffers::NativeTable { |
5852 | typedef DepthToSpaceOptions TableType; |
5853 | int32_t block_size; |
5854 | DepthToSpaceOptionsT() |
5855 | : block_size(0) { |
5856 | } |
5857 | }; |
5858 | |
5859 | struct DepthToSpaceOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5860 | typedef DepthToSpaceOptionsT NativeTableType; |
5861 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5862 | VT_BLOCK_SIZE = 4 |
5863 | }; |
5864 | int32_t block_size() const { |
5865 | return GetField<int32_t>(VT_BLOCK_SIZE, 0); |
5866 | } |
5867 | bool Verify(flatbuffers::Verifier &verifier) const { |
5868 | return VerifyTableStart(verifier) && |
5869 | VerifyField<int32_t>(verifier, VT_BLOCK_SIZE) && |
5870 | verifier.EndTable(); |
5871 | } |
5872 | DepthToSpaceOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5873 | void UnPackTo(DepthToSpaceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5874 | static flatbuffers::Offset<DepthToSpaceOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const DepthToSpaceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5875 | }; |
5876 | |
5877 | struct DepthToSpaceOptionsBuilder { |
5878 | flatbuffers::FlatBufferBuilder &fbb_; |
5879 | flatbuffers::uoffset_t start_; |
5880 | void add_block_size(int32_t block_size) { |
5881 | fbb_.AddElement<int32_t>(DepthToSpaceOptions::VT_BLOCK_SIZE, block_size, 0); |
5882 | } |
5883 | explicit DepthToSpaceOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5884 | : fbb_(_fbb) { |
5885 | start_ = fbb_.StartTable(); |
5886 | } |
5887 | DepthToSpaceOptionsBuilder &operator=(const DepthToSpaceOptionsBuilder &); |
5888 | flatbuffers::Offset<DepthToSpaceOptions> Finish() { |
5889 | const auto end = fbb_.EndTable(start_); |
5890 | auto o = flatbuffers::Offset<DepthToSpaceOptions>(end); |
5891 | return o; |
5892 | } |
5893 | }; |
5894 | |
5895 | inline flatbuffers::Offset<DepthToSpaceOptions> CreateDepthToSpaceOptions( |
5896 | flatbuffers::FlatBufferBuilder &_fbb, |
5897 | int32_t block_size = 0) { |
5898 | DepthToSpaceOptionsBuilder builder_(_fbb); |
5899 | builder_.add_block_size(block_size); |
5900 | return builder_.Finish(); |
5901 | } |
5902 | |
5903 | flatbuffers::Offset<DepthToSpaceOptions> CreateDepthToSpaceOptions(flatbuffers::FlatBufferBuilder &_fbb, const DepthToSpaceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5904 | |
5905 | struct SubOptionsT : public flatbuffers::NativeTable { |
5906 | typedef SubOptions TableType; |
5907 | tflite::ActivationFunctionType fused_activation_function; |
5908 | SubOptionsT() |
5909 | : fused_activation_function(tflite::ActivationFunctionType_NONE) { |
5910 | } |
5911 | }; |
5912 | |
5913 | struct SubOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5914 | typedef SubOptionsT NativeTableType; |
5915 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5916 | VT_FUSED_ACTIVATION_FUNCTION = 4 |
5917 | }; |
5918 | tflite::ActivationFunctionType fused_activation_function() const { |
5919 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
5920 | } |
5921 | bool Verify(flatbuffers::Verifier &verifier) const { |
5922 | return VerifyTableStart(verifier) && |
5923 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
5924 | verifier.EndTable(); |
5925 | } |
5926 | SubOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5927 | void UnPackTo(SubOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5928 | static flatbuffers::Offset<SubOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SubOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5929 | }; |
5930 | |
5931 | struct SubOptionsBuilder { |
5932 | flatbuffers::FlatBufferBuilder &fbb_; |
5933 | flatbuffers::uoffset_t start_; |
5934 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
5935 | fbb_.AddElement<int8_t>(SubOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
5936 | } |
5937 | explicit SubOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5938 | : fbb_(_fbb) { |
5939 | start_ = fbb_.StartTable(); |
5940 | } |
5941 | SubOptionsBuilder &operator=(const SubOptionsBuilder &); |
5942 | flatbuffers::Offset<SubOptions> Finish() { |
5943 | const auto end = fbb_.EndTable(start_); |
5944 | auto o = flatbuffers::Offset<SubOptions>(end); |
5945 | return o; |
5946 | } |
5947 | }; |
5948 | |
5949 | inline flatbuffers::Offset<SubOptions> CreateSubOptions( |
5950 | flatbuffers::FlatBufferBuilder &_fbb, |
5951 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
5952 | SubOptionsBuilder builder_(_fbb); |
5953 | builder_.add_fused_activation_function(fused_activation_function); |
5954 | return builder_.Finish(); |
5955 | } |
5956 | |
5957 | flatbuffers::Offset<SubOptions> CreateSubOptions(flatbuffers::FlatBufferBuilder &_fbb, const SubOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5958 | |
5959 | struct DivOptionsT : public flatbuffers::NativeTable { |
5960 | typedef DivOptions TableType; |
5961 | tflite::ActivationFunctionType fused_activation_function; |
5962 | DivOptionsT() |
5963 | : fused_activation_function(tflite::ActivationFunctionType_NONE) { |
5964 | } |
5965 | }; |
5966 | |
5967 | struct DivOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
5968 | typedef DivOptionsT NativeTableType; |
5969 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
5970 | VT_FUSED_ACTIVATION_FUNCTION = 4 |
5971 | }; |
5972 | tflite::ActivationFunctionType fused_activation_function() const { |
5973 | return static_cast<tflite::ActivationFunctionType>(GetField<int8_t>(VT_FUSED_ACTIVATION_FUNCTION, 0)); |
5974 | } |
5975 | bool Verify(flatbuffers::Verifier &verifier) const { |
5976 | return VerifyTableStart(verifier) && |
5977 | VerifyField<int8_t>(verifier, VT_FUSED_ACTIVATION_FUNCTION) && |
5978 | verifier.EndTable(); |
5979 | } |
5980 | DivOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5981 | void UnPackTo(DivOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
5982 | static flatbuffers::Offset<DivOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const DivOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
5983 | }; |
5984 | |
5985 | struct DivOptionsBuilder { |
5986 | flatbuffers::FlatBufferBuilder &fbb_; |
5987 | flatbuffers::uoffset_t start_; |
5988 | void add_fused_activation_function(tflite::ActivationFunctionType fused_activation_function) { |
5989 | fbb_.AddElement<int8_t>(DivOptions::VT_FUSED_ACTIVATION_FUNCTION, static_cast<int8_t>(fused_activation_function), 0); |
5990 | } |
5991 | explicit DivOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
5992 | : fbb_(_fbb) { |
5993 | start_ = fbb_.StartTable(); |
5994 | } |
5995 | DivOptionsBuilder &operator=(const DivOptionsBuilder &); |
5996 | flatbuffers::Offset<DivOptions> Finish() { |
5997 | const auto end = fbb_.EndTable(start_); |
5998 | auto o = flatbuffers::Offset<DivOptions>(end); |
5999 | return o; |
6000 | } |
6001 | }; |
6002 | |
6003 | inline flatbuffers::Offset<DivOptions> CreateDivOptions( |
6004 | flatbuffers::FlatBufferBuilder &_fbb, |
6005 | tflite::ActivationFunctionType fused_activation_function = tflite::ActivationFunctionType_NONE) { |
6006 | DivOptionsBuilder builder_(_fbb); |
6007 | builder_.add_fused_activation_function(fused_activation_function); |
6008 | return builder_.Finish(); |
6009 | } |
6010 | |
6011 | flatbuffers::Offset<DivOptions> CreateDivOptions(flatbuffers::FlatBufferBuilder &_fbb, const DivOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6012 | |
6013 | struct TopKV2OptionsT : public flatbuffers::NativeTable { |
6014 | typedef TopKV2Options TableType; |
6015 | TopKV2OptionsT() { |
6016 | } |
6017 | }; |
6018 | |
6019 | struct TopKV2Options FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6020 | typedef TopKV2OptionsT NativeTableType; |
6021 | bool Verify(flatbuffers::Verifier &verifier) const { |
6022 | return VerifyTableStart(verifier) && |
6023 | verifier.EndTable(); |
6024 | } |
6025 | TopKV2OptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6026 | void UnPackTo(TopKV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6027 | static flatbuffers::Offset<TopKV2Options> Pack(flatbuffers::FlatBufferBuilder &_fbb, const TopKV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6028 | }; |
6029 | |
6030 | struct TopKV2OptionsBuilder { |
6031 | flatbuffers::FlatBufferBuilder &fbb_; |
6032 | flatbuffers::uoffset_t start_; |
6033 | explicit TopKV2OptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6034 | : fbb_(_fbb) { |
6035 | start_ = fbb_.StartTable(); |
6036 | } |
6037 | TopKV2OptionsBuilder &operator=(const TopKV2OptionsBuilder &); |
6038 | flatbuffers::Offset<TopKV2Options> Finish() { |
6039 | const auto end = fbb_.EndTable(start_); |
6040 | auto o = flatbuffers::Offset<TopKV2Options>(end); |
6041 | return o; |
6042 | } |
6043 | }; |
6044 | |
6045 | inline flatbuffers::Offset<TopKV2Options> CreateTopKV2Options( |
6046 | flatbuffers::FlatBufferBuilder &_fbb) { |
6047 | TopKV2OptionsBuilder builder_(_fbb); |
6048 | return builder_.Finish(); |
6049 | } |
6050 | |
6051 | flatbuffers::Offset<TopKV2Options> CreateTopKV2Options(flatbuffers::FlatBufferBuilder &_fbb, const TopKV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6052 | |
6053 | struct EmbeddingLookupSparseOptionsT : public flatbuffers::NativeTable { |
6054 | typedef EmbeddingLookupSparseOptions TableType; |
6055 | tflite::CombinerType combiner; |
6056 | EmbeddingLookupSparseOptionsT() |
6057 | : combiner(tflite::CombinerType_SUM) { |
6058 | } |
6059 | }; |
6060 | |
6061 | struct EmbeddingLookupSparseOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6062 | typedef EmbeddingLookupSparseOptionsT NativeTableType; |
6063 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6064 | VT_COMBINER = 4 |
6065 | }; |
6066 | tflite::CombinerType combiner() const { |
6067 | return static_cast<tflite::CombinerType>(GetField<int8_t>(VT_COMBINER, 0)); |
6068 | } |
6069 | bool Verify(flatbuffers::Verifier &verifier) const { |
6070 | return VerifyTableStart(verifier) && |
6071 | VerifyField<int8_t>(verifier, VT_COMBINER) && |
6072 | verifier.EndTable(); |
6073 | } |
6074 | EmbeddingLookupSparseOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6075 | void UnPackTo(EmbeddingLookupSparseOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6076 | static flatbuffers::Offset<EmbeddingLookupSparseOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const EmbeddingLookupSparseOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6077 | }; |
6078 | |
6079 | struct EmbeddingLookupSparseOptionsBuilder { |
6080 | flatbuffers::FlatBufferBuilder &fbb_; |
6081 | flatbuffers::uoffset_t start_; |
6082 | void add_combiner(tflite::CombinerType combiner) { |
6083 | fbb_.AddElement<int8_t>(EmbeddingLookupSparseOptions::VT_COMBINER, static_cast<int8_t>(combiner), 0); |
6084 | } |
6085 | explicit EmbeddingLookupSparseOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6086 | : fbb_(_fbb) { |
6087 | start_ = fbb_.StartTable(); |
6088 | } |
6089 | EmbeddingLookupSparseOptionsBuilder &operator=(const EmbeddingLookupSparseOptionsBuilder &); |
6090 | flatbuffers::Offset<EmbeddingLookupSparseOptions> Finish() { |
6091 | const auto end = fbb_.EndTable(start_); |
6092 | auto o = flatbuffers::Offset<EmbeddingLookupSparseOptions>(end); |
6093 | return o; |
6094 | } |
6095 | }; |
6096 | |
6097 | inline flatbuffers::Offset<EmbeddingLookupSparseOptions> CreateEmbeddingLookupSparseOptions( |
6098 | flatbuffers::FlatBufferBuilder &_fbb, |
6099 | tflite::CombinerType combiner = tflite::CombinerType_SUM) { |
6100 | EmbeddingLookupSparseOptionsBuilder builder_(_fbb); |
6101 | builder_.add_combiner(combiner); |
6102 | return builder_.Finish(); |
6103 | } |
6104 | |
6105 | flatbuffers::Offset<EmbeddingLookupSparseOptions> CreateEmbeddingLookupSparseOptions(flatbuffers::FlatBufferBuilder &_fbb, const EmbeddingLookupSparseOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6106 | |
6107 | struct GatherOptionsT : public flatbuffers::NativeTable { |
6108 | typedef GatherOptions TableType; |
6109 | int32_t axis; |
6110 | GatherOptionsT() |
6111 | : axis(0) { |
6112 | } |
6113 | }; |
6114 | |
6115 | struct GatherOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6116 | typedef GatherOptionsT NativeTableType; |
6117 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6118 | VT_AXIS = 4 |
6119 | }; |
6120 | int32_t axis() const { |
6121 | return GetField<int32_t>(VT_AXIS, 0); |
6122 | } |
6123 | bool Verify(flatbuffers::Verifier &verifier) const { |
6124 | return VerifyTableStart(verifier) && |
6125 | VerifyField<int32_t>(verifier, VT_AXIS) && |
6126 | verifier.EndTable(); |
6127 | } |
6128 | GatherOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6129 | void UnPackTo(GatherOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6130 | static flatbuffers::Offset<GatherOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const GatherOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6131 | }; |
6132 | |
6133 | struct GatherOptionsBuilder { |
6134 | flatbuffers::FlatBufferBuilder &fbb_; |
6135 | flatbuffers::uoffset_t start_; |
6136 | void add_axis(int32_t axis) { |
6137 | fbb_.AddElement<int32_t>(GatherOptions::VT_AXIS, axis, 0); |
6138 | } |
6139 | explicit GatherOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6140 | : fbb_(_fbb) { |
6141 | start_ = fbb_.StartTable(); |
6142 | } |
6143 | GatherOptionsBuilder &operator=(const GatherOptionsBuilder &); |
6144 | flatbuffers::Offset<GatherOptions> Finish() { |
6145 | const auto end = fbb_.EndTable(start_); |
6146 | auto o = flatbuffers::Offset<GatherOptions>(end); |
6147 | return o; |
6148 | } |
6149 | }; |
6150 | |
6151 | inline flatbuffers::Offset<GatherOptions> CreateGatherOptions( |
6152 | flatbuffers::FlatBufferBuilder &_fbb, |
6153 | int32_t axis = 0) { |
6154 | GatherOptionsBuilder builder_(_fbb); |
6155 | builder_.add_axis(axis); |
6156 | return builder_.Finish(); |
6157 | } |
6158 | |
6159 | flatbuffers::Offset<GatherOptions> CreateGatherOptions(flatbuffers::FlatBufferBuilder &_fbb, const GatherOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6160 | |
6161 | struct TransposeOptionsT : public flatbuffers::NativeTable { |
6162 | typedef TransposeOptions TableType; |
6163 | TransposeOptionsT() { |
6164 | } |
6165 | }; |
6166 | |
6167 | struct TransposeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6168 | typedef TransposeOptionsT NativeTableType; |
6169 | bool Verify(flatbuffers::Verifier &verifier) const { |
6170 | return VerifyTableStart(verifier) && |
6171 | verifier.EndTable(); |
6172 | } |
6173 | TransposeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6174 | void UnPackTo(TransposeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6175 | static flatbuffers::Offset<TransposeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const TransposeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6176 | }; |
6177 | |
6178 | struct TransposeOptionsBuilder { |
6179 | flatbuffers::FlatBufferBuilder &fbb_; |
6180 | flatbuffers::uoffset_t start_; |
6181 | explicit TransposeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6182 | : fbb_(_fbb) { |
6183 | start_ = fbb_.StartTable(); |
6184 | } |
6185 | TransposeOptionsBuilder &operator=(const TransposeOptionsBuilder &); |
6186 | flatbuffers::Offset<TransposeOptions> Finish() { |
6187 | const auto end = fbb_.EndTable(start_); |
6188 | auto o = flatbuffers::Offset<TransposeOptions>(end); |
6189 | return o; |
6190 | } |
6191 | }; |
6192 | |
6193 | inline flatbuffers::Offset<TransposeOptions> CreateTransposeOptions( |
6194 | flatbuffers::FlatBufferBuilder &_fbb) { |
6195 | TransposeOptionsBuilder builder_(_fbb); |
6196 | return builder_.Finish(); |
6197 | } |
6198 | |
6199 | flatbuffers::Offset<TransposeOptions> CreateTransposeOptions(flatbuffers::FlatBufferBuilder &_fbb, const TransposeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6200 | |
6201 | struct ExpOptionsT : public flatbuffers::NativeTable { |
6202 | typedef ExpOptions TableType; |
6203 | ExpOptionsT() { |
6204 | } |
6205 | }; |
6206 | |
6207 | struct ExpOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6208 | typedef ExpOptionsT NativeTableType; |
6209 | bool Verify(flatbuffers::Verifier &verifier) const { |
6210 | return VerifyTableStart(verifier) && |
6211 | verifier.EndTable(); |
6212 | } |
6213 | ExpOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6214 | void UnPackTo(ExpOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6215 | static flatbuffers::Offset<ExpOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ExpOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6216 | }; |
6217 | |
6218 | struct ExpOptionsBuilder { |
6219 | flatbuffers::FlatBufferBuilder &fbb_; |
6220 | flatbuffers::uoffset_t start_; |
6221 | explicit ExpOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6222 | : fbb_(_fbb) { |
6223 | start_ = fbb_.StartTable(); |
6224 | } |
6225 | ExpOptionsBuilder &operator=(const ExpOptionsBuilder &); |
6226 | flatbuffers::Offset<ExpOptions> Finish() { |
6227 | const auto end = fbb_.EndTable(start_); |
6228 | auto o = flatbuffers::Offset<ExpOptions>(end); |
6229 | return o; |
6230 | } |
6231 | }; |
6232 | |
6233 | inline flatbuffers::Offset<ExpOptions> CreateExpOptions( |
6234 | flatbuffers::FlatBufferBuilder &_fbb) { |
6235 | ExpOptionsBuilder builder_(_fbb); |
6236 | return builder_.Finish(); |
6237 | } |
6238 | |
6239 | flatbuffers::Offset<ExpOptions> CreateExpOptions(flatbuffers::FlatBufferBuilder &_fbb, const ExpOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6240 | |
6241 | struct CosOptionsT : public flatbuffers::NativeTable { |
6242 | typedef CosOptions TableType; |
6243 | CosOptionsT() { |
6244 | } |
6245 | }; |
6246 | |
6247 | struct CosOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6248 | typedef CosOptionsT NativeTableType; |
6249 | bool Verify(flatbuffers::Verifier &verifier) const { |
6250 | return VerifyTableStart(verifier) && |
6251 | verifier.EndTable(); |
6252 | } |
6253 | CosOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6254 | void UnPackTo(CosOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6255 | static flatbuffers::Offset<CosOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const CosOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6256 | }; |
6257 | |
6258 | struct CosOptionsBuilder { |
6259 | flatbuffers::FlatBufferBuilder &fbb_; |
6260 | flatbuffers::uoffset_t start_; |
6261 | explicit CosOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6262 | : fbb_(_fbb) { |
6263 | start_ = fbb_.StartTable(); |
6264 | } |
6265 | CosOptionsBuilder &operator=(const CosOptionsBuilder &); |
6266 | flatbuffers::Offset<CosOptions> Finish() { |
6267 | const auto end = fbb_.EndTable(start_); |
6268 | auto o = flatbuffers::Offset<CosOptions>(end); |
6269 | return o; |
6270 | } |
6271 | }; |
6272 | |
6273 | inline flatbuffers::Offset<CosOptions> CreateCosOptions( |
6274 | flatbuffers::FlatBufferBuilder &_fbb) { |
6275 | CosOptionsBuilder builder_(_fbb); |
6276 | return builder_.Finish(); |
6277 | } |
6278 | |
6279 | flatbuffers::Offset<CosOptions> CreateCosOptions(flatbuffers::FlatBufferBuilder &_fbb, const CosOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6280 | |
6281 | struct ReducerOptionsT : public flatbuffers::NativeTable { |
6282 | typedef ReducerOptions TableType; |
6283 | bool keep_dims; |
6284 | ReducerOptionsT() |
6285 | : keep_dims(false) { |
6286 | } |
6287 | }; |
6288 | |
6289 | struct ReducerOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6290 | typedef ReducerOptionsT NativeTableType; |
6291 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6292 | VT_KEEP_DIMS = 4 |
6293 | }; |
6294 | bool keep_dims() const { |
6295 | return GetField<uint8_t>(VT_KEEP_DIMS, 0) != 0; |
6296 | } |
6297 | bool Verify(flatbuffers::Verifier &verifier) const { |
6298 | return VerifyTableStart(verifier) && |
6299 | VerifyField<uint8_t>(verifier, VT_KEEP_DIMS) && |
6300 | verifier.EndTable(); |
6301 | } |
6302 | ReducerOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6303 | void UnPackTo(ReducerOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6304 | static flatbuffers::Offset<ReducerOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReducerOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6305 | }; |
6306 | |
6307 | struct ReducerOptionsBuilder { |
6308 | flatbuffers::FlatBufferBuilder &fbb_; |
6309 | flatbuffers::uoffset_t start_; |
6310 | void add_keep_dims(bool keep_dims) { |
6311 | fbb_.AddElement<uint8_t>(ReducerOptions::VT_KEEP_DIMS, static_cast<uint8_t>(keep_dims), 0); |
6312 | } |
6313 | explicit ReducerOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6314 | : fbb_(_fbb) { |
6315 | start_ = fbb_.StartTable(); |
6316 | } |
6317 | ReducerOptionsBuilder &operator=(const ReducerOptionsBuilder &); |
6318 | flatbuffers::Offset<ReducerOptions> Finish() { |
6319 | const auto end = fbb_.EndTable(start_); |
6320 | auto o = flatbuffers::Offset<ReducerOptions>(end); |
6321 | return o; |
6322 | } |
6323 | }; |
6324 | |
6325 | inline flatbuffers::Offset<ReducerOptions> CreateReducerOptions( |
6326 | flatbuffers::FlatBufferBuilder &_fbb, |
6327 | bool keep_dims = false) { |
6328 | ReducerOptionsBuilder builder_(_fbb); |
6329 | builder_.add_keep_dims(keep_dims); |
6330 | return builder_.Finish(); |
6331 | } |
6332 | |
6333 | flatbuffers::Offset<ReducerOptions> CreateReducerOptions(flatbuffers::FlatBufferBuilder &_fbb, const ReducerOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6334 | |
6335 | struct SqueezeOptionsT : public flatbuffers::NativeTable { |
6336 | typedef SqueezeOptions TableType; |
6337 | std::vector<int32_t> squeeze_dims; |
6338 | SqueezeOptionsT() { |
6339 | } |
6340 | }; |
6341 | |
6342 | struct SqueezeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6343 | typedef SqueezeOptionsT NativeTableType; |
6344 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6345 | VT_SQUEEZE_DIMS = 4 |
6346 | }; |
6347 | const flatbuffers::Vector<int32_t> *squeeze_dims() const { |
6348 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_SQUEEZE_DIMS); |
6349 | } |
6350 | bool Verify(flatbuffers::Verifier &verifier) const { |
6351 | return VerifyTableStart(verifier) && |
6352 | VerifyOffset(verifier, VT_SQUEEZE_DIMS) && |
6353 | verifier.VerifyVector(squeeze_dims()) && |
6354 | verifier.EndTable(); |
6355 | } |
6356 | SqueezeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6357 | void UnPackTo(SqueezeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6358 | static flatbuffers::Offset<SqueezeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SqueezeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6359 | }; |
6360 | |
6361 | struct SqueezeOptionsBuilder { |
6362 | flatbuffers::FlatBufferBuilder &fbb_; |
6363 | flatbuffers::uoffset_t start_; |
6364 | void add_squeeze_dims(flatbuffers::Offset<flatbuffers::Vector<int32_t>> squeeze_dims) { |
6365 | fbb_.AddOffset(SqueezeOptions::VT_SQUEEZE_DIMS, squeeze_dims); |
6366 | } |
6367 | explicit SqueezeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6368 | : fbb_(_fbb) { |
6369 | start_ = fbb_.StartTable(); |
6370 | } |
6371 | SqueezeOptionsBuilder &operator=(const SqueezeOptionsBuilder &); |
6372 | flatbuffers::Offset<SqueezeOptions> Finish() { |
6373 | const auto end = fbb_.EndTable(start_); |
6374 | auto o = flatbuffers::Offset<SqueezeOptions>(end); |
6375 | return o; |
6376 | } |
6377 | }; |
6378 | |
6379 | inline flatbuffers::Offset<SqueezeOptions> CreateSqueezeOptions( |
6380 | flatbuffers::FlatBufferBuilder &_fbb, |
6381 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> squeeze_dims = 0) { |
6382 | SqueezeOptionsBuilder builder_(_fbb); |
6383 | builder_.add_squeeze_dims(squeeze_dims); |
6384 | return builder_.Finish(); |
6385 | } |
6386 | |
6387 | inline flatbuffers::Offset<SqueezeOptions> CreateSqueezeOptionsDirect( |
6388 | flatbuffers::FlatBufferBuilder &_fbb, |
6389 | const std::vector<int32_t> *squeeze_dims = nullptr) { |
6390 | auto squeeze_dims__ = squeeze_dims ? _fbb.CreateVector<int32_t>(*squeeze_dims) : 0; |
6391 | return tflite::CreateSqueezeOptions( |
6392 | _fbb, |
6393 | squeeze_dims__); |
6394 | } |
6395 | |
6396 | flatbuffers::Offset<SqueezeOptions> CreateSqueezeOptions(flatbuffers::FlatBufferBuilder &_fbb, const SqueezeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6397 | |
6398 | struct SplitOptionsT : public flatbuffers::NativeTable { |
6399 | typedef SplitOptions TableType; |
6400 | int32_t num_splits; |
6401 | SplitOptionsT() |
6402 | : num_splits(0) { |
6403 | } |
6404 | }; |
6405 | |
6406 | struct SplitOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6407 | typedef SplitOptionsT NativeTableType; |
6408 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6409 | VT_NUM_SPLITS = 4 |
6410 | }; |
6411 | int32_t num_splits() const { |
6412 | return GetField<int32_t>(VT_NUM_SPLITS, 0); |
6413 | } |
6414 | bool Verify(flatbuffers::Verifier &verifier) const { |
6415 | return VerifyTableStart(verifier) && |
6416 | VerifyField<int32_t>(verifier, VT_NUM_SPLITS) && |
6417 | verifier.EndTable(); |
6418 | } |
6419 | SplitOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6420 | void UnPackTo(SplitOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6421 | static flatbuffers::Offset<SplitOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SplitOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6422 | }; |
6423 | |
6424 | struct SplitOptionsBuilder { |
6425 | flatbuffers::FlatBufferBuilder &fbb_; |
6426 | flatbuffers::uoffset_t start_; |
6427 | void add_num_splits(int32_t num_splits) { |
6428 | fbb_.AddElement<int32_t>(SplitOptions::VT_NUM_SPLITS, num_splits, 0); |
6429 | } |
6430 | explicit SplitOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6431 | : fbb_(_fbb) { |
6432 | start_ = fbb_.StartTable(); |
6433 | } |
6434 | SplitOptionsBuilder &operator=(const SplitOptionsBuilder &); |
6435 | flatbuffers::Offset<SplitOptions> Finish() { |
6436 | const auto end = fbb_.EndTable(start_); |
6437 | auto o = flatbuffers::Offset<SplitOptions>(end); |
6438 | return o; |
6439 | } |
6440 | }; |
6441 | |
6442 | inline flatbuffers::Offset<SplitOptions> CreateSplitOptions( |
6443 | flatbuffers::FlatBufferBuilder &_fbb, |
6444 | int32_t num_splits = 0) { |
6445 | SplitOptionsBuilder builder_(_fbb); |
6446 | builder_.add_num_splits(num_splits); |
6447 | return builder_.Finish(); |
6448 | } |
6449 | |
6450 | flatbuffers::Offset<SplitOptions> CreateSplitOptions(flatbuffers::FlatBufferBuilder &_fbb, const SplitOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6451 | |
6452 | struct SplitVOptionsT : public flatbuffers::NativeTable { |
6453 | typedef SplitVOptions TableType; |
6454 | int32_t num_splits; |
6455 | SplitVOptionsT() |
6456 | : num_splits(0) { |
6457 | } |
6458 | }; |
6459 | |
6460 | struct SplitVOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6461 | typedef SplitVOptionsT NativeTableType; |
6462 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6463 | VT_NUM_SPLITS = 4 |
6464 | }; |
6465 | int32_t num_splits() const { |
6466 | return GetField<int32_t>(VT_NUM_SPLITS, 0); |
6467 | } |
6468 | bool Verify(flatbuffers::Verifier &verifier) const { |
6469 | return VerifyTableStart(verifier) && |
6470 | VerifyField<int32_t>(verifier, VT_NUM_SPLITS) && |
6471 | verifier.EndTable(); |
6472 | } |
6473 | SplitVOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6474 | void UnPackTo(SplitVOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6475 | static flatbuffers::Offset<SplitVOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SplitVOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6476 | }; |
6477 | |
6478 | struct SplitVOptionsBuilder { |
6479 | flatbuffers::FlatBufferBuilder &fbb_; |
6480 | flatbuffers::uoffset_t start_; |
6481 | void add_num_splits(int32_t num_splits) { |
6482 | fbb_.AddElement<int32_t>(SplitVOptions::VT_NUM_SPLITS, num_splits, 0); |
6483 | } |
6484 | explicit SplitVOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6485 | : fbb_(_fbb) { |
6486 | start_ = fbb_.StartTable(); |
6487 | } |
6488 | SplitVOptionsBuilder &operator=(const SplitVOptionsBuilder &); |
6489 | flatbuffers::Offset<SplitVOptions> Finish() { |
6490 | const auto end = fbb_.EndTable(start_); |
6491 | auto o = flatbuffers::Offset<SplitVOptions>(end); |
6492 | return o; |
6493 | } |
6494 | }; |
6495 | |
6496 | inline flatbuffers::Offset<SplitVOptions> CreateSplitVOptions( |
6497 | flatbuffers::FlatBufferBuilder &_fbb, |
6498 | int32_t num_splits = 0) { |
6499 | SplitVOptionsBuilder builder_(_fbb); |
6500 | builder_.add_num_splits(num_splits); |
6501 | return builder_.Finish(); |
6502 | } |
6503 | |
6504 | flatbuffers::Offset<SplitVOptions> CreateSplitVOptions(flatbuffers::FlatBufferBuilder &_fbb, const SplitVOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6505 | |
6506 | struct StridedSliceOptionsT : public flatbuffers::NativeTable { |
6507 | typedef StridedSliceOptions TableType; |
6508 | int32_t begin_mask; |
6509 | int32_t end_mask; |
6510 | int32_t ellipsis_mask; |
6511 | int32_t new_axis_mask; |
6512 | int32_t shrink_axis_mask; |
6513 | StridedSliceOptionsT() |
6514 | : begin_mask(0), |
6515 | end_mask(0), |
6516 | ellipsis_mask(0), |
6517 | new_axis_mask(0), |
6518 | shrink_axis_mask(0) { |
6519 | } |
6520 | }; |
6521 | |
6522 | struct StridedSliceOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6523 | typedef StridedSliceOptionsT NativeTableType; |
6524 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6525 | VT_BEGIN_MASK = 4, |
6526 | VT_END_MASK = 6, |
6527 | VT_ELLIPSIS_MASK = 8, |
6528 | VT_NEW_AXIS_MASK = 10, |
6529 | VT_SHRINK_AXIS_MASK = 12 |
6530 | }; |
6531 | int32_t begin_mask() const { |
6532 | return GetField<int32_t>(VT_BEGIN_MASK, 0); |
6533 | } |
6534 | int32_t end_mask() const { |
6535 | return GetField<int32_t>(VT_END_MASK, 0); |
6536 | } |
6537 | int32_t ellipsis_mask() const { |
6538 | return GetField<int32_t>(VT_ELLIPSIS_MASK, 0); |
6539 | } |
6540 | int32_t new_axis_mask() const { |
6541 | return GetField<int32_t>(VT_NEW_AXIS_MASK, 0); |
6542 | } |
6543 | int32_t shrink_axis_mask() const { |
6544 | return GetField<int32_t>(VT_SHRINK_AXIS_MASK, 0); |
6545 | } |
6546 | bool Verify(flatbuffers::Verifier &verifier) const { |
6547 | return VerifyTableStart(verifier) && |
6548 | VerifyField<int32_t>(verifier, VT_BEGIN_MASK) && |
6549 | VerifyField<int32_t>(verifier, VT_END_MASK) && |
6550 | VerifyField<int32_t>(verifier, VT_ELLIPSIS_MASK) && |
6551 | VerifyField<int32_t>(verifier, VT_NEW_AXIS_MASK) && |
6552 | VerifyField<int32_t>(verifier, VT_SHRINK_AXIS_MASK) && |
6553 | verifier.EndTable(); |
6554 | } |
6555 | StridedSliceOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6556 | void UnPackTo(StridedSliceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6557 | static flatbuffers::Offset<StridedSliceOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const StridedSliceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6558 | }; |
6559 | |
6560 | struct StridedSliceOptionsBuilder { |
6561 | flatbuffers::FlatBufferBuilder &fbb_; |
6562 | flatbuffers::uoffset_t start_; |
6563 | void add_begin_mask(int32_t begin_mask) { |
6564 | fbb_.AddElement<int32_t>(StridedSliceOptions::VT_BEGIN_MASK, begin_mask, 0); |
6565 | } |
6566 | void add_end_mask(int32_t end_mask) { |
6567 | fbb_.AddElement<int32_t>(StridedSliceOptions::VT_END_MASK, end_mask, 0); |
6568 | } |
6569 | void add_ellipsis_mask(int32_t ellipsis_mask) { |
6570 | fbb_.AddElement<int32_t>(StridedSliceOptions::VT_ELLIPSIS_MASK, ellipsis_mask, 0); |
6571 | } |
6572 | void add_new_axis_mask(int32_t new_axis_mask) { |
6573 | fbb_.AddElement<int32_t>(StridedSliceOptions::VT_NEW_AXIS_MASK, new_axis_mask, 0); |
6574 | } |
6575 | void add_shrink_axis_mask(int32_t shrink_axis_mask) { |
6576 | fbb_.AddElement<int32_t>(StridedSliceOptions::VT_SHRINK_AXIS_MASK, shrink_axis_mask, 0); |
6577 | } |
6578 | explicit StridedSliceOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6579 | : fbb_(_fbb) { |
6580 | start_ = fbb_.StartTable(); |
6581 | } |
6582 | StridedSliceOptionsBuilder &operator=(const StridedSliceOptionsBuilder &); |
6583 | flatbuffers::Offset<StridedSliceOptions> Finish() { |
6584 | const auto end = fbb_.EndTable(start_); |
6585 | auto o = flatbuffers::Offset<StridedSliceOptions>(end); |
6586 | return o; |
6587 | } |
6588 | }; |
6589 | |
6590 | inline flatbuffers::Offset<StridedSliceOptions> CreateStridedSliceOptions( |
6591 | flatbuffers::FlatBufferBuilder &_fbb, |
6592 | int32_t begin_mask = 0, |
6593 | int32_t end_mask = 0, |
6594 | int32_t ellipsis_mask = 0, |
6595 | int32_t new_axis_mask = 0, |
6596 | int32_t shrink_axis_mask = 0) { |
6597 | StridedSliceOptionsBuilder builder_(_fbb); |
6598 | builder_.add_shrink_axis_mask(shrink_axis_mask); |
6599 | builder_.add_new_axis_mask(new_axis_mask); |
6600 | builder_.add_ellipsis_mask(ellipsis_mask); |
6601 | builder_.add_end_mask(end_mask); |
6602 | builder_.add_begin_mask(begin_mask); |
6603 | return builder_.Finish(); |
6604 | } |
6605 | |
6606 | flatbuffers::Offset<StridedSliceOptions> CreateStridedSliceOptions(flatbuffers::FlatBufferBuilder &_fbb, const StridedSliceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6607 | |
6608 | struct LogSoftmaxOptionsT : public flatbuffers::NativeTable { |
6609 | typedef LogSoftmaxOptions TableType; |
6610 | LogSoftmaxOptionsT() { |
6611 | } |
6612 | }; |
6613 | |
6614 | struct LogSoftmaxOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6615 | typedef LogSoftmaxOptionsT NativeTableType; |
6616 | bool Verify(flatbuffers::Verifier &verifier) const { |
6617 | return VerifyTableStart(verifier) && |
6618 | verifier.EndTable(); |
6619 | } |
6620 | LogSoftmaxOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6621 | void UnPackTo(LogSoftmaxOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6622 | static flatbuffers::Offset<LogSoftmaxOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogSoftmaxOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6623 | }; |
6624 | |
6625 | struct LogSoftmaxOptionsBuilder { |
6626 | flatbuffers::FlatBufferBuilder &fbb_; |
6627 | flatbuffers::uoffset_t start_; |
6628 | explicit LogSoftmaxOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6629 | : fbb_(_fbb) { |
6630 | start_ = fbb_.StartTable(); |
6631 | } |
6632 | LogSoftmaxOptionsBuilder &operator=(const LogSoftmaxOptionsBuilder &); |
6633 | flatbuffers::Offset<LogSoftmaxOptions> Finish() { |
6634 | const auto end = fbb_.EndTable(start_); |
6635 | auto o = flatbuffers::Offset<LogSoftmaxOptions>(end); |
6636 | return o; |
6637 | } |
6638 | }; |
6639 | |
6640 | inline flatbuffers::Offset<LogSoftmaxOptions> CreateLogSoftmaxOptions( |
6641 | flatbuffers::FlatBufferBuilder &_fbb) { |
6642 | LogSoftmaxOptionsBuilder builder_(_fbb); |
6643 | return builder_.Finish(); |
6644 | } |
6645 | |
6646 | flatbuffers::Offset<LogSoftmaxOptions> CreateLogSoftmaxOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogSoftmaxOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6647 | |
6648 | struct CastOptionsT : public flatbuffers::NativeTable { |
6649 | typedef CastOptions TableType; |
6650 | tflite::TensorType in_data_type; |
6651 | tflite::TensorType out_data_type; |
6652 | CastOptionsT() |
6653 | : in_data_type(tflite::TensorType_FLOAT32), |
6654 | out_data_type(tflite::TensorType_FLOAT32) { |
6655 | } |
6656 | }; |
6657 | |
6658 | struct CastOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6659 | typedef CastOptionsT NativeTableType; |
6660 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6661 | VT_IN_DATA_TYPE = 4, |
6662 | VT_OUT_DATA_TYPE = 6 |
6663 | }; |
6664 | tflite::TensorType in_data_type() const { |
6665 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_IN_DATA_TYPE, 0)); |
6666 | } |
6667 | tflite::TensorType out_data_type() const { |
6668 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_OUT_DATA_TYPE, 0)); |
6669 | } |
6670 | bool Verify(flatbuffers::Verifier &verifier) const { |
6671 | return VerifyTableStart(verifier) && |
6672 | VerifyField<int8_t>(verifier, VT_IN_DATA_TYPE) && |
6673 | VerifyField<int8_t>(verifier, VT_OUT_DATA_TYPE) && |
6674 | verifier.EndTable(); |
6675 | } |
6676 | CastOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6677 | void UnPackTo(CastOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6678 | static flatbuffers::Offset<CastOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const CastOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6679 | }; |
6680 | |
6681 | struct CastOptionsBuilder { |
6682 | flatbuffers::FlatBufferBuilder &fbb_; |
6683 | flatbuffers::uoffset_t start_; |
6684 | void add_in_data_type(tflite::TensorType in_data_type) { |
6685 | fbb_.AddElement<int8_t>(CastOptions::VT_IN_DATA_TYPE, static_cast<int8_t>(in_data_type), 0); |
6686 | } |
6687 | void add_out_data_type(tflite::TensorType out_data_type) { |
6688 | fbb_.AddElement<int8_t>(CastOptions::VT_OUT_DATA_TYPE, static_cast<int8_t>(out_data_type), 0); |
6689 | } |
6690 | explicit CastOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6691 | : fbb_(_fbb) { |
6692 | start_ = fbb_.StartTable(); |
6693 | } |
6694 | CastOptionsBuilder &operator=(const CastOptionsBuilder &); |
6695 | flatbuffers::Offset<CastOptions> Finish() { |
6696 | const auto end = fbb_.EndTable(start_); |
6697 | auto o = flatbuffers::Offset<CastOptions>(end); |
6698 | return o; |
6699 | } |
6700 | }; |
6701 | |
6702 | inline flatbuffers::Offset<CastOptions> CreateCastOptions( |
6703 | flatbuffers::FlatBufferBuilder &_fbb, |
6704 | tflite::TensorType in_data_type = tflite::TensorType_FLOAT32, |
6705 | tflite::TensorType out_data_type = tflite::TensorType_FLOAT32) { |
6706 | CastOptionsBuilder builder_(_fbb); |
6707 | builder_.add_out_data_type(out_data_type); |
6708 | builder_.add_in_data_type(in_data_type); |
6709 | return builder_.Finish(); |
6710 | } |
6711 | |
6712 | flatbuffers::Offset<CastOptions> CreateCastOptions(flatbuffers::FlatBufferBuilder &_fbb, const CastOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6713 | |
6714 | struct DequantizeOptionsT : public flatbuffers::NativeTable { |
6715 | typedef DequantizeOptions TableType; |
6716 | DequantizeOptionsT() { |
6717 | } |
6718 | }; |
6719 | |
6720 | struct DequantizeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6721 | typedef DequantizeOptionsT NativeTableType; |
6722 | bool Verify(flatbuffers::Verifier &verifier) const { |
6723 | return VerifyTableStart(verifier) && |
6724 | verifier.EndTable(); |
6725 | } |
6726 | DequantizeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6727 | void UnPackTo(DequantizeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6728 | static flatbuffers::Offset<DequantizeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const DequantizeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6729 | }; |
6730 | |
6731 | struct DequantizeOptionsBuilder { |
6732 | flatbuffers::FlatBufferBuilder &fbb_; |
6733 | flatbuffers::uoffset_t start_; |
6734 | explicit DequantizeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6735 | : fbb_(_fbb) { |
6736 | start_ = fbb_.StartTable(); |
6737 | } |
6738 | DequantizeOptionsBuilder &operator=(const DequantizeOptionsBuilder &); |
6739 | flatbuffers::Offset<DequantizeOptions> Finish() { |
6740 | const auto end = fbb_.EndTable(start_); |
6741 | auto o = flatbuffers::Offset<DequantizeOptions>(end); |
6742 | return o; |
6743 | } |
6744 | }; |
6745 | |
6746 | inline flatbuffers::Offset<DequantizeOptions> CreateDequantizeOptions( |
6747 | flatbuffers::FlatBufferBuilder &_fbb) { |
6748 | DequantizeOptionsBuilder builder_(_fbb); |
6749 | return builder_.Finish(); |
6750 | } |
6751 | |
6752 | flatbuffers::Offset<DequantizeOptions> CreateDequantizeOptions(flatbuffers::FlatBufferBuilder &_fbb, const DequantizeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6753 | |
6754 | struct MaximumMinimumOptionsT : public flatbuffers::NativeTable { |
6755 | typedef MaximumMinimumOptions TableType; |
6756 | MaximumMinimumOptionsT() { |
6757 | } |
6758 | }; |
6759 | |
6760 | struct MaximumMinimumOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6761 | typedef MaximumMinimumOptionsT NativeTableType; |
6762 | bool Verify(flatbuffers::Verifier &verifier) const { |
6763 | return VerifyTableStart(verifier) && |
6764 | verifier.EndTable(); |
6765 | } |
6766 | MaximumMinimumOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6767 | void UnPackTo(MaximumMinimumOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6768 | static flatbuffers::Offset<MaximumMinimumOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const MaximumMinimumOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6769 | }; |
6770 | |
6771 | struct MaximumMinimumOptionsBuilder { |
6772 | flatbuffers::FlatBufferBuilder &fbb_; |
6773 | flatbuffers::uoffset_t start_; |
6774 | explicit MaximumMinimumOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6775 | : fbb_(_fbb) { |
6776 | start_ = fbb_.StartTable(); |
6777 | } |
6778 | MaximumMinimumOptionsBuilder &operator=(const MaximumMinimumOptionsBuilder &); |
6779 | flatbuffers::Offset<MaximumMinimumOptions> Finish() { |
6780 | const auto end = fbb_.EndTable(start_); |
6781 | auto o = flatbuffers::Offset<MaximumMinimumOptions>(end); |
6782 | return o; |
6783 | } |
6784 | }; |
6785 | |
6786 | inline flatbuffers::Offset<MaximumMinimumOptions> CreateMaximumMinimumOptions( |
6787 | flatbuffers::FlatBufferBuilder &_fbb) { |
6788 | MaximumMinimumOptionsBuilder builder_(_fbb); |
6789 | return builder_.Finish(); |
6790 | } |
6791 | |
6792 | flatbuffers::Offset<MaximumMinimumOptions> CreateMaximumMinimumOptions(flatbuffers::FlatBufferBuilder &_fbb, const MaximumMinimumOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6793 | |
6794 | struct TileOptionsT : public flatbuffers::NativeTable { |
6795 | typedef TileOptions TableType; |
6796 | TileOptionsT() { |
6797 | } |
6798 | }; |
6799 | |
6800 | struct TileOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6801 | typedef TileOptionsT NativeTableType; |
6802 | bool Verify(flatbuffers::Verifier &verifier) const { |
6803 | return VerifyTableStart(verifier) && |
6804 | verifier.EndTable(); |
6805 | } |
6806 | TileOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6807 | void UnPackTo(TileOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6808 | static flatbuffers::Offset<TileOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const TileOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6809 | }; |
6810 | |
6811 | struct TileOptionsBuilder { |
6812 | flatbuffers::FlatBufferBuilder &fbb_; |
6813 | flatbuffers::uoffset_t start_; |
6814 | explicit TileOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6815 | : fbb_(_fbb) { |
6816 | start_ = fbb_.StartTable(); |
6817 | } |
6818 | TileOptionsBuilder &operator=(const TileOptionsBuilder &); |
6819 | flatbuffers::Offset<TileOptions> Finish() { |
6820 | const auto end = fbb_.EndTable(start_); |
6821 | auto o = flatbuffers::Offset<TileOptions>(end); |
6822 | return o; |
6823 | } |
6824 | }; |
6825 | |
6826 | inline flatbuffers::Offset<TileOptions> CreateTileOptions( |
6827 | flatbuffers::FlatBufferBuilder &_fbb) { |
6828 | TileOptionsBuilder builder_(_fbb); |
6829 | return builder_.Finish(); |
6830 | } |
6831 | |
6832 | flatbuffers::Offset<TileOptions> CreateTileOptions(flatbuffers::FlatBufferBuilder &_fbb, const TileOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6833 | |
6834 | struct ArgMaxOptionsT : public flatbuffers::NativeTable { |
6835 | typedef ArgMaxOptions TableType; |
6836 | tflite::TensorType output_type; |
6837 | ArgMaxOptionsT() |
6838 | : output_type(tflite::TensorType_FLOAT32) { |
6839 | } |
6840 | }; |
6841 | |
6842 | struct ArgMaxOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6843 | typedef ArgMaxOptionsT NativeTableType; |
6844 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6845 | VT_OUTPUT_TYPE = 4 |
6846 | }; |
6847 | tflite::TensorType output_type() const { |
6848 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_OUTPUT_TYPE, 0)); |
6849 | } |
6850 | bool Verify(flatbuffers::Verifier &verifier) const { |
6851 | return VerifyTableStart(verifier) && |
6852 | VerifyField<int8_t>(verifier, VT_OUTPUT_TYPE) && |
6853 | verifier.EndTable(); |
6854 | } |
6855 | ArgMaxOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6856 | void UnPackTo(ArgMaxOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6857 | static flatbuffers::Offset<ArgMaxOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ArgMaxOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6858 | }; |
6859 | |
6860 | struct ArgMaxOptionsBuilder { |
6861 | flatbuffers::FlatBufferBuilder &fbb_; |
6862 | flatbuffers::uoffset_t start_; |
6863 | void add_output_type(tflite::TensorType output_type) { |
6864 | fbb_.AddElement<int8_t>(ArgMaxOptions::VT_OUTPUT_TYPE, static_cast<int8_t>(output_type), 0); |
6865 | } |
6866 | explicit ArgMaxOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6867 | : fbb_(_fbb) { |
6868 | start_ = fbb_.StartTable(); |
6869 | } |
6870 | ArgMaxOptionsBuilder &operator=(const ArgMaxOptionsBuilder &); |
6871 | flatbuffers::Offset<ArgMaxOptions> Finish() { |
6872 | const auto end = fbb_.EndTable(start_); |
6873 | auto o = flatbuffers::Offset<ArgMaxOptions>(end); |
6874 | return o; |
6875 | } |
6876 | }; |
6877 | |
6878 | inline flatbuffers::Offset<ArgMaxOptions> CreateArgMaxOptions( |
6879 | flatbuffers::FlatBufferBuilder &_fbb, |
6880 | tflite::TensorType output_type = tflite::TensorType_FLOAT32) { |
6881 | ArgMaxOptionsBuilder builder_(_fbb); |
6882 | builder_.add_output_type(output_type); |
6883 | return builder_.Finish(); |
6884 | } |
6885 | |
6886 | flatbuffers::Offset<ArgMaxOptions> CreateArgMaxOptions(flatbuffers::FlatBufferBuilder &_fbb, const ArgMaxOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6887 | |
6888 | struct ArgMinOptionsT : public flatbuffers::NativeTable { |
6889 | typedef ArgMinOptions TableType; |
6890 | tflite::TensorType output_type; |
6891 | ArgMinOptionsT() |
6892 | : output_type(tflite::TensorType_FLOAT32) { |
6893 | } |
6894 | }; |
6895 | |
6896 | struct ArgMinOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6897 | typedef ArgMinOptionsT NativeTableType; |
6898 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
6899 | VT_OUTPUT_TYPE = 4 |
6900 | }; |
6901 | tflite::TensorType output_type() const { |
6902 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_OUTPUT_TYPE, 0)); |
6903 | } |
6904 | bool Verify(flatbuffers::Verifier &verifier) const { |
6905 | return VerifyTableStart(verifier) && |
6906 | VerifyField<int8_t>(verifier, VT_OUTPUT_TYPE) && |
6907 | verifier.EndTable(); |
6908 | } |
6909 | ArgMinOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6910 | void UnPackTo(ArgMinOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6911 | static flatbuffers::Offset<ArgMinOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ArgMinOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6912 | }; |
6913 | |
6914 | struct ArgMinOptionsBuilder { |
6915 | flatbuffers::FlatBufferBuilder &fbb_; |
6916 | flatbuffers::uoffset_t start_; |
6917 | void add_output_type(tflite::TensorType output_type) { |
6918 | fbb_.AddElement<int8_t>(ArgMinOptions::VT_OUTPUT_TYPE, static_cast<int8_t>(output_type), 0); |
6919 | } |
6920 | explicit ArgMinOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6921 | : fbb_(_fbb) { |
6922 | start_ = fbb_.StartTable(); |
6923 | } |
6924 | ArgMinOptionsBuilder &operator=(const ArgMinOptionsBuilder &); |
6925 | flatbuffers::Offset<ArgMinOptions> Finish() { |
6926 | const auto end = fbb_.EndTable(start_); |
6927 | auto o = flatbuffers::Offset<ArgMinOptions>(end); |
6928 | return o; |
6929 | } |
6930 | }; |
6931 | |
6932 | inline flatbuffers::Offset<ArgMinOptions> CreateArgMinOptions( |
6933 | flatbuffers::FlatBufferBuilder &_fbb, |
6934 | tflite::TensorType output_type = tflite::TensorType_FLOAT32) { |
6935 | ArgMinOptionsBuilder builder_(_fbb); |
6936 | builder_.add_output_type(output_type); |
6937 | return builder_.Finish(); |
6938 | } |
6939 | |
6940 | flatbuffers::Offset<ArgMinOptions> CreateArgMinOptions(flatbuffers::FlatBufferBuilder &_fbb, const ArgMinOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6941 | |
6942 | struct GreaterOptionsT : public flatbuffers::NativeTable { |
6943 | typedef GreaterOptions TableType; |
6944 | GreaterOptionsT() { |
6945 | } |
6946 | }; |
6947 | |
6948 | struct GreaterOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6949 | typedef GreaterOptionsT NativeTableType; |
6950 | bool Verify(flatbuffers::Verifier &verifier) const { |
6951 | return VerifyTableStart(verifier) && |
6952 | verifier.EndTable(); |
6953 | } |
6954 | GreaterOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6955 | void UnPackTo(GreaterOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6956 | static flatbuffers::Offset<GreaterOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const GreaterOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6957 | }; |
6958 | |
6959 | struct GreaterOptionsBuilder { |
6960 | flatbuffers::FlatBufferBuilder &fbb_; |
6961 | flatbuffers::uoffset_t start_; |
6962 | explicit GreaterOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
6963 | : fbb_(_fbb) { |
6964 | start_ = fbb_.StartTable(); |
6965 | } |
6966 | GreaterOptionsBuilder &operator=(const GreaterOptionsBuilder &); |
6967 | flatbuffers::Offset<GreaterOptions> Finish() { |
6968 | const auto end = fbb_.EndTable(start_); |
6969 | auto o = flatbuffers::Offset<GreaterOptions>(end); |
6970 | return o; |
6971 | } |
6972 | }; |
6973 | |
6974 | inline flatbuffers::Offset<GreaterOptions> CreateGreaterOptions( |
6975 | flatbuffers::FlatBufferBuilder &_fbb) { |
6976 | GreaterOptionsBuilder builder_(_fbb); |
6977 | return builder_.Finish(); |
6978 | } |
6979 | |
6980 | flatbuffers::Offset<GreaterOptions> CreateGreaterOptions(flatbuffers::FlatBufferBuilder &_fbb, const GreaterOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6981 | |
6982 | struct GreaterEqualOptionsT : public flatbuffers::NativeTable { |
6983 | typedef GreaterEqualOptions TableType; |
6984 | GreaterEqualOptionsT() { |
6985 | } |
6986 | }; |
6987 | |
6988 | struct GreaterEqualOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
6989 | typedef GreaterEqualOptionsT NativeTableType; |
6990 | bool Verify(flatbuffers::Verifier &verifier) const { |
6991 | return VerifyTableStart(verifier) && |
6992 | verifier.EndTable(); |
6993 | } |
6994 | GreaterEqualOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6995 | void UnPackTo(GreaterEqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
6996 | static flatbuffers::Offset<GreaterEqualOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const GreaterEqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
6997 | }; |
6998 | |
6999 | struct GreaterEqualOptionsBuilder { |
7000 | flatbuffers::FlatBufferBuilder &fbb_; |
7001 | flatbuffers::uoffset_t start_; |
7002 | explicit GreaterEqualOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7003 | : fbb_(_fbb) { |
7004 | start_ = fbb_.StartTable(); |
7005 | } |
7006 | GreaterEqualOptionsBuilder &operator=(const GreaterEqualOptionsBuilder &); |
7007 | flatbuffers::Offset<GreaterEqualOptions> Finish() { |
7008 | const auto end = fbb_.EndTable(start_); |
7009 | auto o = flatbuffers::Offset<GreaterEqualOptions>(end); |
7010 | return o; |
7011 | } |
7012 | }; |
7013 | |
7014 | inline flatbuffers::Offset<GreaterEqualOptions> CreateGreaterEqualOptions( |
7015 | flatbuffers::FlatBufferBuilder &_fbb) { |
7016 | GreaterEqualOptionsBuilder builder_(_fbb); |
7017 | return builder_.Finish(); |
7018 | } |
7019 | |
7020 | flatbuffers::Offset<GreaterEqualOptions> CreateGreaterEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const GreaterEqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7021 | |
7022 | struct LessOptionsT : public flatbuffers::NativeTable { |
7023 | typedef LessOptions TableType; |
7024 | LessOptionsT() { |
7025 | } |
7026 | }; |
7027 | |
7028 | struct LessOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7029 | typedef LessOptionsT NativeTableType; |
7030 | bool Verify(flatbuffers::Verifier &verifier) const { |
7031 | return VerifyTableStart(verifier) && |
7032 | verifier.EndTable(); |
7033 | } |
7034 | LessOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7035 | void UnPackTo(LessOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7036 | static flatbuffers::Offset<LessOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LessOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7037 | }; |
7038 | |
7039 | struct LessOptionsBuilder { |
7040 | flatbuffers::FlatBufferBuilder &fbb_; |
7041 | flatbuffers::uoffset_t start_; |
7042 | explicit LessOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7043 | : fbb_(_fbb) { |
7044 | start_ = fbb_.StartTable(); |
7045 | } |
7046 | LessOptionsBuilder &operator=(const LessOptionsBuilder &); |
7047 | flatbuffers::Offset<LessOptions> Finish() { |
7048 | const auto end = fbb_.EndTable(start_); |
7049 | auto o = flatbuffers::Offset<LessOptions>(end); |
7050 | return o; |
7051 | } |
7052 | }; |
7053 | |
7054 | inline flatbuffers::Offset<LessOptions> CreateLessOptions( |
7055 | flatbuffers::FlatBufferBuilder &_fbb) { |
7056 | LessOptionsBuilder builder_(_fbb); |
7057 | return builder_.Finish(); |
7058 | } |
7059 | |
7060 | flatbuffers::Offset<LessOptions> CreateLessOptions(flatbuffers::FlatBufferBuilder &_fbb, const LessOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7061 | |
7062 | struct LessEqualOptionsT : public flatbuffers::NativeTable { |
7063 | typedef LessEqualOptions TableType; |
7064 | LessEqualOptionsT() { |
7065 | } |
7066 | }; |
7067 | |
7068 | struct LessEqualOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7069 | typedef LessEqualOptionsT NativeTableType; |
7070 | bool Verify(flatbuffers::Verifier &verifier) const { |
7071 | return VerifyTableStart(verifier) && |
7072 | verifier.EndTable(); |
7073 | } |
7074 | LessEqualOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7075 | void UnPackTo(LessEqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7076 | static flatbuffers::Offset<LessEqualOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LessEqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7077 | }; |
7078 | |
7079 | struct LessEqualOptionsBuilder { |
7080 | flatbuffers::FlatBufferBuilder &fbb_; |
7081 | flatbuffers::uoffset_t start_; |
7082 | explicit LessEqualOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7083 | : fbb_(_fbb) { |
7084 | start_ = fbb_.StartTable(); |
7085 | } |
7086 | LessEqualOptionsBuilder &operator=(const LessEqualOptionsBuilder &); |
7087 | flatbuffers::Offset<LessEqualOptions> Finish() { |
7088 | const auto end = fbb_.EndTable(start_); |
7089 | auto o = flatbuffers::Offset<LessEqualOptions>(end); |
7090 | return o; |
7091 | } |
7092 | }; |
7093 | |
7094 | inline flatbuffers::Offset<LessEqualOptions> CreateLessEqualOptions( |
7095 | flatbuffers::FlatBufferBuilder &_fbb) { |
7096 | LessEqualOptionsBuilder builder_(_fbb); |
7097 | return builder_.Finish(); |
7098 | } |
7099 | |
7100 | flatbuffers::Offset<LessEqualOptions> CreateLessEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const LessEqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7101 | |
7102 | struct NegOptionsT : public flatbuffers::NativeTable { |
7103 | typedef NegOptions TableType; |
7104 | NegOptionsT() { |
7105 | } |
7106 | }; |
7107 | |
7108 | struct NegOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7109 | typedef NegOptionsT NativeTableType; |
7110 | bool Verify(flatbuffers::Verifier &verifier) const { |
7111 | return VerifyTableStart(verifier) && |
7112 | verifier.EndTable(); |
7113 | } |
7114 | NegOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7115 | void UnPackTo(NegOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7116 | static flatbuffers::Offset<NegOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const NegOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7117 | }; |
7118 | |
7119 | struct NegOptionsBuilder { |
7120 | flatbuffers::FlatBufferBuilder &fbb_; |
7121 | flatbuffers::uoffset_t start_; |
7122 | explicit NegOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7123 | : fbb_(_fbb) { |
7124 | start_ = fbb_.StartTable(); |
7125 | } |
7126 | NegOptionsBuilder &operator=(const NegOptionsBuilder &); |
7127 | flatbuffers::Offset<NegOptions> Finish() { |
7128 | const auto end = fbb_.EndTable(start_); |
7129 | auto o = flatbuffers::Offset<NegOptions>(end); |
7130 | return o; |
7131 | } |
7132 | }; |
7133 | |
7134 | inline flatbuffers::Offset<NegOptions> CreateNegOptions( |
7135 | flatbuffers::FlatBufferBuilder &_fbb) { |
7136 | NegOptionsBuilder builder_(_fbb); |
7137 | return builder_.Finish(); |
7138 | } |
7139 | |
7140 | flatbuffers::Offset<NegOptions> CreateNegOptions(flatbuffers::FlatBufferBuilder &_fbb, const NegOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7141 | |
7142 | struct SelectOptionsT : public flatbuffers::NativeTable { |
7143 | typedef SelectOptions TableType; |
7144 | SelectOptionsT() { |
7145 | } |
7146 | }; |
7147 | |
7148 | struct SelectOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7149 | typedef SelectOptionsT NativeTableType; |
7150 | bool Verify(flatbuffers::Verifier &verifier) const { |
7151 | return VerifyTableStart(verifier) && |
7152 | verifier.EndTable(); |
7153 | } |
7154 | SelectOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7155 | void UnPackTo(SelectOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7156 | static flatbuffers::Offset<SelectOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SelectOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7157 | }; |
7158 | |
7159 | struct SelectOptionsBuilder { |
7160 | flatbuffers::FlatBufferBuilder &fbb_; |
7161 | flatbuffers::uoffset_t start_; |
7162 | explicit SelectOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7163 | : fbb_(_fbb) { |
7164 | start_ = fbb_.StartTable(); |
7165 | } |
7166 | SelectOptionsBuilder &operator=(const SelectOptionsBuilder &); |
7167 | flatbuffers::Offset<SelectOptions> Finish() { |
7168 | const auto end = fbb_.EndTable(start_); |
7169 | auto o = flatbuffers::Offset<SelectOptions>(end); |
7170 | return o; |
7171 | } |
7172 | }; |
7173 | |
7174 | inline flatbuffers::Offset<SelectOptions> CreateSelectOptions( |
7175 | flatbuffers::FlatBufferBuilder &_fbb) { |
7176 | SelectOptionsBuilder builder_(_fbb); |
7177 | return builder_.Finish(); |
7178 | } |
7179 | |
7180 | flatbuffers::Offset<SelectOptions> CreateSelectOptions(flatbuffers::FlatBufferBuilder &_fbb, const SelectOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7181 | |
7182 | struct SliceOptionsT : public flatbuffers::NativeTable { |
7183 | typedef SliceOptions TableType; |
7184 | SliceOptionsT() { |
7185 | } |
7186 | }; |
7187 | |
7188 | struct SliceOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7189 | typedef SliceOptionsT NativeTableType; |
7190 | bool Verify(flatbuffers::Verifier &verifier) const { |
7191 | return VerifyTableStart(verifier) && |
7192 | verifier.EndTable(); |
7193 | } |
7194 | SliceOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7195 | void UnPackTo(SliceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7196 | static flatbuffers::Offset<SliceOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SliceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7197 | }; |
7198 | |
7199 | struct SliceOptionsBuilder { |
7200 | flatbuffers::FlatBufferBuilder &fbb_; |
7201 | flatbuffers::uoffset_t start_; |
7202 | explicit SliceOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7203 | : fbb_(_fbb) { |
7204 | start_ = fbb_.StartTable(); |
7205 | } |
7206 | SliceOptionsBuilder &operator=(const SliceOptionsBuilder &); |
7207 | flatbuffers::Offset<SliceOptions> Finish() { |
7208 | const auto end = fbb_.EndTable(start_); |
7209 | auto o = flatbuffers::Offset<SliceOptions>(end); |
7210 | return o; |
7211 | } |
7212 | }; |
7213 | |
7214 | inline flatbuffers::Offset<SliceOptions> CreateSliceOptions( |
7215 | flatbuffers::FlatBufferBuilder &_fbb) { |
7216 | SliceOptionsBuilder builder_(_fbb); |
7217 | return builder_.Finish(); |
7218 | } |
7219 | |
7220 | flatbuffers::Offset<SliceOptions> CreateSliceOptions(flatbuffers::FlatBufferBuilder &_fbb, const SliceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7221 | |
7222 | struct TransposeConvOptionsT : public flatbuffers::NativeTable { |
7223 | typedef TransposeConvOptions TableType; |
7224 | tflite::Padding padding; |
7225 | int32_t stride_w; |
7226 | int32_t stride_h; |
7227 | TransposeConvOptionsT() |
7228 | : padding(tflite::Padding_SAME), |
7229 | stride_w(0), |
7230 | stride_h(0) { |
7231 | } |
7232 | }; |
7233 | |
7234 | struct TransposeConvOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7235 | typedef TransposeConvOptionsT NativeTableType; |
7236 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
7237 | VT_PADDING = 4, |
7238 | VT_STRIDE_W = 6, |
7239 | VT_STRIDE_H = 8 |
7240 | }; |
7241 | tflite::Padding padding() const { |
7242 | return static_cast<tflite::Padding>(GetField<int8_t>(VT_PADDING, 0)); |
7243 | } |
7244 | int32_t stride_w() const { |
7245 | return GetField<int32_t>(VT_STRIDE_W, 0); |
7246 | } |
7247 | int32_t stride_h() const { |
7248 | return GetField<int32_t>(VT_STRIDE_H, 0); |
7249 | } |
7250 | bool Verify(flatbuffers::Verifier &verifier) const { |
7251 | return VerifyTableStart(verifier) && |
7252 | VerifyField<int8_t>(verifier, VT_PADDING) && |
7253 | VerifyField<int32_t>(verifier, VT_STRIDE_W) && |
7254 | VerifyField<int32_t>(verifier, VT_STRIDE_H) && |
7255 | verifier.EndTable(); |
7256 | } |
7257 | TransposeConvOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7258 | void UnPackTo(TransposeConvOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7259 | static flatbuffers::Offset<TransposeConvOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const TransposeConvOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7260 | }; |
7261 | |
7262 | struct TransposeConvOptionsBuilder { |
7263 | flatbuffers::FlatBufferBuilder &fbb_; |
7264 | flatbuffers::uoffset_t start_; |
7265 | void add_padding(tflite::Padding padding) { |
7266 | fbb_.AddElement<int8_t>(TransposeConvOptions::VT_PADDING, static_cast<int8_t>(padding), 0); |
7267 | } |
7268 | void add_stride_w(int32_t stride_w) { |
7269 | fbb_.AddElement<int32_t>(TransposeConvOptions::VT_STRIDE_W, stride_w, 0); |
7270 | } |
7271 | void add_stride_h(int32_t stride_h) { |
7272 | fbb_.AddElement<int32_t>(TransposeConvOptions::VT_STRIDE_H, stride_h, 0); |
7273 | } |
7274 | explicit TransposeConvOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7275 | : fbb_(_fbb) { |
7276 | start_ = fbb_.StartTable(); |
7277 | } |
7278 | TransposeConvOptionsBuilder &operator=(const TransposeConvOptionsBuilder &); |
7279 | flatbuffers::Offset<TransposeConvOptions> Finish() { |
7280 | const auto end = fbb_.EndTable(start_); |
7281 | auto o = flatbuffers::Offset<TransposeConvOptions>(end); |
7282 | return o; |
7283 | } |
7284 | }; |
7285 | |
7286 | inline flatbuffers::Offset<TransposeConvOptions> CreateTransposeConvOptions( |
7287 | flatbuffers::FlatBufferBuilder &_fbb, |
7288 | tflite::Padding padding = tflite::Padding_SAME, |
7289 | int32_t stride_w = 0, |
7290 | int32_t stride_h = 0) { |
7291 | TransposeConvOptionsBuilder builder_(_fbb); |
7292 | builder_.add_stride_h(stride_h); |
7293 | builder_.add_stride_w(stride_w); |
7294 | builder_.add_padding(padding); |
7295 | return builder_.Finish(); |
7296 | } |
7297 | |
7298 | flatbuffers::Offset<TransposeConvOptions> CreateTransposeConvOptions(flatbuffers::FlatBufferBuilder &_fbb, const TransposeConvOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7299 | |
7300 | struct ExpandDimsOptionsT : public flatbuffers::NativeTable { |
7301 | typedef ExpandDimsOptions TableType; |
7302 | ExpandDimsOptionsT() { |
7303 | } |
7304 | }; |
7305 | |
7306 | struct ExpandDimsOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7307 | typedef ExpandDimsOptionsT NativeTableType; |
7308 | bool Verify(flatbuffers::Verifier &verifier) const { |
7309 | return VerifyTableStart(verifier) && |
7310 | verifier.EndTable(); |
7311 | } |
7312 | ExpandDimsOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7313 | void UnPackTo(ExpandDimsOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7314 | static flatbuffers::Offset<ExpandDimsOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ExpandDimsOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7315 | }; |
7316 | |
7317 | struct ExpandDimsOptionsBuilder { |
7318 | flatbuffers::FlatBufferBuilder &fbb_; |
7319 | flatbuffers::uoffset_t start_; |
7320 | explicit ExpandDimsOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7321 | : fbb_(_fbb) { |
7322 | start_ = fbb_.StartTable(); |
7323 | } |
7324 | ExpandDimsOptionsBuilder &operator=(const ExpandDimsOptionsBuilder &); |
7325 | flatbuffers::Offset<ExpandDimsOptions> Finish() { |
7326 | const auto end = fbb_.EndTable(start_); |
7327 | auto o = flatbuffers::Offset<ExpandDimsOptions>(end); |
7328 | return o; |
7329 | } |
7330 | }; |
7331 | |
7332 | inline flatbuffers::Offset<ExpandDimsOptions> CreateExpandDimsOptions( |
7333 | flatbuffers::FlatBufferBuilder &_fbb) { |
7334 | ExpandDimsOptionsBuilder builder_(_fbb); |
7335 | return builder_.Finish(); |
7336 | } |
7337 | |
7338 | flatbuffers::Offset<ExpandDimsOptions> CreateExpandDimsOptions(flatbuffers::FlatBufferBuilder &_fbb, const ExpandDimsOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7339 | |
7340 | struct SparseToDenseOptionsT : public flatbuffers::NativeTable { |
7341 | typedef SparseToDenseOptions TableType; |
7342 | bool validate_indices; |
7343 | SparseToDenseOptionsT() |
7344 | : validate_indices(false) { |
7345 | } |
7346 | }; |
7347 | |
7348 | struct SparseToDenseOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7349 | typedef SparseToDenseOptionsT NativeTableType; |
7350 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
7351 | VT_VALIDATE_INDICES = 4 |
7352 | }; |
7353 | bool validate_indices() const { |
7354 | return GetField<uint8_t>(VT_VALIDATE_INDICES, 0) != 0; |
7355 | } |
7356 | bool Verify(flatbuffers::Verifier &verifier) const { |
7357 | return VerifyTableStart(verifier) && |
7358 | VerifyField<uint8_t>(verifier, VT_VALIDATE_INDICES) && |
7359 | verifier.EndTable(); |
7360 | } |
7361 | SparseToDenseOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7362 | void UnPackTo(SparseToDenseOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7363 | static flatbuffers::Offset<SparseToDenseOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SparseToDenseOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7364 | }; |
7365 | |
7366 | struct SparseToDenseOptionsBuilder { |
7367 | flatbuffers::FlatBufferBuilder &fbb_; |
7368 | flatbuffers::uoffset_t start_; |
7369 | void add_validate_indices(bool validate_indices) { |
7370 | fbb_.AddElement<uint8_t>(SparseToDenseOptions::VT_VALIDATE_INDICES, static_cast<uint8_t>(validate_indices), 0); |
7371 | } |
7372 | explicit SparseToDenseOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7373 | : fbb_(_fbb) { |
7374 | start_ = fbb_.StartTable(); |
7375 | } |
7376 | SparseToDenseOptionsBuilder &operator=(const SparseToDenseOptionsBuilder &); |
7377 | flatbuffers::Offset<SparseToDenseOptions> Finish() { |
7378 | const auto end = fbb_.EndTable(start_); |
7379 | auto o = flatbuffers::Offset<SparseToDenseOptions>(end); |
7380 | return o; |
7381 | } |
7382 | }; |
7383 | |
7384 | inline flatbuffers::Offset<SparseToDenseOptions> CreateSparseToDenseOptions( |
7385 | flatbuffers::FlatBufferBuilder &_fbb, |
7386 | bool validate_indices = false) { |
7387 | SparseToDenseOptionsBuilder builder_(_fbb); |
7388 | builder_.add_validate_indices(validate_indices); |
7389 | return builder_.Finish(); |
7390 | } |
7391 | |
7392 | flatbuffers::Offset<SparseToDenseOptions> CreateSparseToDenseOptions(flatbuffers::FlatBufferBuilder &_fbb, const SparseToDenseOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7393 | |
7394 | struct EqualOptionsT : public flatbuffers::NativeTable { |
7395 | typedef EqualOptions TableType; |
7396 | EqualOptionsT() { |
7397 | } |
7398 | }; |
7399 | |
7400 | struct EqualOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7401 | typedef EqualOptionsT NativeTableType; |
7402 | bool Verify(flatbuffers::Verifier &verifier) const { |
7403 | return VerifyTableStart(verifier) && |
7404 | verifier.EndTable(); |
7405 | } |
7406 | EqualOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7407 | void UnPackTo(EqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7408 | static flatbuffers::Offset<EqualOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const EqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7409 | }; |
7410 | |
7411 | struct EqualOptionsBuilder { |
7412 | flatbuffers::FlatBufferBuilder &fbb_; |
7413 | flatbuffers::uoffset_t start_; |
7414 | explicit EqualOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7415 | : fbb_(_fbb) { |
7416 | start_ = fbb_.StartTable(); |
7417 | } |
7418 | EqualOptionsBuilder &operator=(const EqualOptionsBuilder &); |
7419 | flatbuffers::Offset<EqualOptions> Finish() { |
7420 | const auto end = fbb_.EndTable(start_); |
7421 | auto o = flatbuffers::Offset<EqualOptions>(end); |
7422 | return o; |
7423 | } |
7424 | }; |
7425 | |
7426 | inline flatbuffers::Offset<EqualOptions> CreateEqualOptions( |
7427 | flatbuffers::FlatBufferBuilder &_fbb) { |
7428 | EqualOptionsBuilder builder_(_fbb); |
7429 | return builder_.Finish(); |
7430 | } |
7431 | |
7432 | flatbuffers::Offset<EqualOptions> CreateEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const EqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7433 | |
7434 | struct NotEqualOptionsT : public flatbuffers::NativeTable { |
7435 | typedef NotEqualOptions TableType; |
7436 | NotEqualOptionsT() { |
7437 | } |
7438 | }; |
7439 | |
7440 | struct NotEqualOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7441 | typedef NotEqualOptionsT NativeTableType; |
7442 | bool Verify(flatbuffers::Verifier &verifier) const { |
7443 | return VerifyTableStart(verifier) && |
7444 | verifier.EndTable(); |
7445 | } |
7446 | NotEqualOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7447 | void UnPackTo(NotEqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7448 | static flatbuffers::Offset<NotEqualOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const NotEqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7449 | }; |
7450 | |
7451 | struct NotEqualOptionsBuilder { |
7452 | flatbuffers::FlatBufferBuilder &fbb_; |
7453 | flatbuffers::uoffset_t start_; |
7454 | explicit NotEqualOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7455 | : fbb_(_fbb) { |
7456 | start_ = fbb_.StartTable(); |
7457 | } |
7458 | NotEqualOptionsBuilder &operator=(const NotEqualOptionsBuilder &); |
7459 | flatbuffers::Offset<NotEqualOptions> Finish() { |
7460 | const auto end = fbb_.EndTable(start_); |
7461 | auto o = flatbuffers::Offset<NotEqualOptions>(end); |
7462 | return o; |
7463 | } |
7464 | }; |
7465 | |
7466 | inline flatbuffers::Offset<NotEqualOptions> CreateNotEqualOptions( |
7467 | flatbuffers::FlatBufferBuilder &_fbb) { |
7468 | NotEqualOptionsBuilder builder_(_fbb); |
7469 | return builder_.Finish(); |
7470 | } |
7471 | |
7472 | flatbuffers::Offset<NotEqualOptions> CreateNotEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const NotEqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7473 | |
7474 | struct ShapeOptionsT : public flatbuffers::NativeTable { |
7475 | typedef ShapeOptions TableType; |
7476 | tflite::TensorType out_type; |
7477 | ShapeOptionsT() |
7478 | : out_type(tflite::TensorType_FLOAT32) { |
7479 | } |
7480 | }; |
7481 | |
7482 | struct ShapeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7483 | typedef ShapeOptionsT NativeTableType; |
7484 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
7485 | VT_OUT_TYPE = 4 |
7486 | }; |
7487 | tflite::TensorType out_type() const { |
7488 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_OUT_TYPE, 0)); |
7489 | } |
7490 | bool Verify(flatbuffers::Verifier &verifier) const { |
7491 | return VerifyTableStart(verifier) && |
7492 | VerifyField<int8_t>(verifier, VT_OUT_TYPE) && |
7493 | verifier.EndTable(); |
7494 | } |
7495 | ShapeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7496 | void UnPackTo(ShapeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7497 | static flatbuffers::Offset<ShapeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ShapeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7498 | }; |
7499 | |
7500 | struct ShapeOptionsBuilder { |
7501 | flatbuffers::FlatBufferBuilder &fbb_; |
7502 | flatbuffers::uoffset_t start_; |
7503 | void add_out_type(tflite::TensorType out_type) { |
7504 | fbb_.AddElement<int8_t>(ShapeOptions::VT_OUT_TYPE, static_cast<int8_t>(out_type), 0); |
7505 | } |
7506 | explicit ShapeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7507 | : fbb_(_fbb) { |
7508 | start_ = fbb_.StartTable(); |
7509 | } |
7510 | ShapeOptionsBuilder &operator=(const ShapeOptionsBuilder &); |
7511 | flatbuffers::Offset<ShapeOptions> Finish() { |
7512 | const auto end = fbb_.EndTable(start_); |
7513 | auto o = flatbuffers::Offset<ShapeOptions>(end); |
7514 | return o; |
7515 | } |
7516 | }; |
7517 | |
7518 | inline flatbuffers::Offset<ShapeOptions> CreateShapeOptions( |
7519 | flatbuffers::FlatBufferBuilder &_fbb, |
7520 | tflite::TensorType out_type = tflite::TensorType_FLOAT32) { |
7521 | ShapeOptionsBuilder builder_(_fbb); |
7522 | builder_.add_out_type(out_type); |
7523 | return builder_.Finish(); |
7524 | } |
7525 | |
7526 | flatbuffers::Offset<ShapeOptions> CreateShapeOptions(flatbuffers::FlatBufferBuilder &_fbb, const ShapeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7527 | |
7528 | struct RankOptionsT : public flatbuffers::NativeTable { |
7529 | typedef RankOptions TableType; |
7530 | RankOptionsT() { |
7531 | } |
7532 | }; |
7533 | |
7534 | struct RankOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7535 | typedef RankOptionsT NativeTableType; |
7536 | bool Verify(flatbuffers::Verifier &verifier) const { |
7537 | return VerifyTableStart(verifier) && |
7538 | verifier.EndTable(); |
7539 | } |
7540 | RankOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7541 | void UnPackTo(RankOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7542 | static flatbuffers::Offset<RankOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const RankOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7543 | }; |
7544 | |
7545 | struct RankOptionsBuilder { |
7546 | flatbuffers::FlatBufferBuilder &fbb_; |
7547 | flatbuffers::uoffset_t start_; |
7548 | explicit RankOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7549 | : fbb_(_fbb) { |
7550 | start_ = fbb_.StartTable(); |
7551 | } |
7552 | RankOptionsBuilder &operator=(const RankOptionsBuilder &); |
7553 | flatbuffers::Offset<RankOptions> Finish() { |
7554 | const auto end = fbb_.EndTable(start_); |
7555 | auto o = flatbuffers::Offset<RankOptions>(end); |
7556 | return o; |
7557 | } |
7558 | }; |
7559 | |
7560 | inline flatbuffers::Offset<RankOptions> CreateRankOptions( |
7561 | flatbuffers::FlatBufferBuilder &_fbb) { |
7562 | RankOptionsBuilder builder_(_fbb); |
7563 | return builder_.Finish(); |
7564 | } |
7565 | |
7566 | flatbuffers::Offset<RankOptions> CreateRankOptions(flatbuffers::FlatBufferBuilder &_fbb, const RankOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7567 | |
7568 | struct PowOptionsT : public flatbuffers::NativeTable { |
7569 | typedef PowOptions TableType; |
7570 | PowOptionsT() { |
7571 | } |
7572 | }; |
7573 | |
7574 | struct PowOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7575 | typedef PowOptionsT NativeTableType; |
7576 | bool Verify(flatbuffers::Verifier &verifier) const { |
7577 | return VerifyTableStart(verifier) && |
7578 | verifier.EndTable(); |
7579 | } |
7580 | PowOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7581 | void UnPackTo(PowOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7582 | static flatbuffers::Offset<PowOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const PowOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7583 | }; |
7584 | |
7585 | struct PowOptionsBuilder { |
7586 | flatbuffers::FlatBufferBuilder &fbb_; |
7587 | flatbuffers::uoffset_t start_; |
7588 | explicit PowOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7589 | : fbb_(_fbb) { |
7590 | start_ = fbb_.StartTable(); |
7591 | } |
7592 | PowOptionsBuilder &operator=(const PowOptionsBuilder &); |
7593 | flatbuffers::Offset<PowOptions> Finish() { |
7594 | const auto end = fbb_.EndTable(start_); |
7595 | auto o = flatbuffers::Offset<PowOptions>(end); |
7596 | return o; |
7597 | } |
7598 | }; |
7599 | |
7600 | inline flatbuffers::Offset<PowOptions> CreatePowOptions( |
7601 | flatbuffers::FlatBufferBuilder &_fbb) { |
7602 | PowOptionsBuilder builder_(_fbb); |
7603 | return builder_.Finish(); |
7604 | } |
7605 | |
7606 | flatbuffers::Offset<PowOptions> CreatePowOptions(flatbuffers::FlatBufferBuilder &_fbb, const PowOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7607 | |
7608 | struct FakeQuantOptionsT : public flatbuffers::NativeTable { |
7609 | typedef FakeQuantOptions TableType; |
7610 | float min; |
7611 | float max; |
7612 | int32_t num_bits; |
7613 | bool narrow_range; |
7614 | FakeQuantOptionsT() |
7615 | : min(0.0f), |
7616 | max(0.0f), |
7617 | num_bits(0), |
7618 | narrow_range(false) { |
7619 | } |
7620 | }; |
7621 | |
7622 | struct FakeQuantOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7623 | typedef FakeQuantOptionsT NativeTableType; |
7624 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
7625 | VT_MIN = 4, |
7626 | VT_MAX = 6, |
7627 | VT_NUM_BITS = 8, |
7628 | VT_NARROW_RANGE = 10 |
7629 | }; |
7630 | float min() const { |
7631 | return GetField<float>(VT_MIN, 0.0f); |
7632 | } |
7633 | float max() const { |
7634 | return GetField<float>(VT_MAX, 0.0f); |
7635 | } |
7636 | int32_t num_bits() const { |
7637 | return GetField<int32_t>(VT_NUM_BITS, 0); |
7638 | } |
7639 | bool narrow_range() const { |
7640 | return GetField<uint8_t>(VT_NARROW_RANGE, 0) != 0; |
7641 | } |
7642 | bool Verify(flatbuffers::Verifier &verifier) const { |
7643 | return VerifyTableStart(verifier) && |
7644 | VerifyField<float>(verifier, VT_MIN) && |
7645 | VerifyField<float>(verifier, VT_MAX) && |
7646 | VerifyField<int32_t>(verifier, VT_NUM_BITS) && |
7647 | VerifyField<uint8_t>(verifier, VT_NARROW_RANGE) && |
7648 | verifier.EndTable(); |
7649 | } |
7650 | FakeQuantOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7651 | void UnPackTo(FakeQuantOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7652 | static flatbuffers::Offset<FakeQuantOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const FakeQuantOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7653 | }; |
7654 | |
7655 | struct FakeQuantOptionsBuilder { |
7656 | flatbuffers::FlatBufferBuilder &fbb_; |
7657 | flatbuffers::uoffset_t start_; |
7658 | void add_min(float min) { |
7659 | fbb_.AddElement<float>(FakeQuantOptions::VT_MIN, min, 0.0f); |
7660 | } |
7661 | void add_max(float max) { |
7662 | fbb_.AddElement<float>(FakeQuantOptions::VT_MAX, max, 0.0f); |
7663 | } |
7664 | void add_num_bits(int32_t num_bits) { |
7665 | fbb_.AddElement<int32_t>(FakeQuantOptions::VT_NUM_BITS, num_bits, 0); |
7666 | } |
7667 | void add_narrow_range(bool narrow_range) { |
7668 | fbb_.AddElement<uint8_t>(FakeQuantOptions::VT_NARROW_RANGE, static_cast<uint8_t>(narrow_range), 0); |
7669 | } |
7670 | explicit FakeQuantOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7671 | : fbb_(_fbb) { |
7672 | start_ = fbb_.StartTable(); |
7673 | } |
7674 | FakeQuantOptionsBuilder &operator=(const FakeQuantOptionsBuilder &); |
7675 | flatbuffers::Offset<FakeQuantOptions> Finish() { |
7676 | const auto end = fbb_.EndTable(start_); |
7677 | auto o = flatbuffers::Offset<FakeQuantOptions>(end); |
7678 | return o; |
7679 | } |
7680 | }; |
7681 | |
7682 | inline flatbuffers::Offset<FakeQuantOptions> CreateFakeQuantOptions( |
7683 | flatbuffers::FlatBufferBuilder &_fbb, |
7684 | float min = 0.0f, |
7685 | float max = 0.0f, |
7686 | int32_t num_bits = 0, |
7687 | bool narrow_range = false) { |
7688 | FakeQuantOptionsBuilder builder_(_fbb); |
7689 | builder_.add_num_bits(num_bits); |
7690 | builder_.add_max(max); |
7691 | builder_.add_min(min); |
7692 | builder_.add_narrow_range(narrow_range); |
7693 | return builder_.Finish(); |
7694 | } |
7695 | |
7696 | flatbuffers::Offset<FakeQuantOptions> CreateFakeQuantOptions(flatbuffers::FlatBufferBuilder &_fbb, const FakeQuantOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7697 | |
7698 | struct PackOptionsT : public flatbuffers::NativeTable { |
7699 | typedef PackOptions TableType; |
7700 | int32_t values_count; |
7701 | int32_t axis; |
7702 | PackOptionsT() |
7703 | : values_count(0), |
7704 | axis(0) { |
7705 | } |
7706 | }; |
7707 | |
7708 | struct PackOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7709 | typedef PackOptionsT NativeTableType; |
7710 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
7711 | VT_VALUES_COUNT = 4, |
7712 | VT_AXIS = 6 |
7713 | }; |
7714 | int32_t values_count() const { |
7715 | return GetField<int32_t>(VT_VALUES_COUNT, 0); |
7716 | } |
7717 | int32_t axis() const { |
7718 | return GetField<int32_t>(VT_AXIS, 0); |
7719 | } |
7720 | bool Verify(flatbuffers::Verifier &verifier) const { |
7721 | return VerifyTableStart(verifier) && |
7722 | VerifyField<int32_t>(verifier, VT_VALUES_COUNT) && |
7723 | VerifyField<int32_t>(verifier, VT_AXIS) && |
7724 | verifier.EndTable(); |
7725 | } |
7726 | PackOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7727 | void UnPackTo(PackOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7728 | static flatbuffers::Offset<PackOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const PackOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7729 | }; |
7730 | |
7731 | struct PackOptionsBuilder { |
7732 | flatbuffers::FlatBufferBuilder &fbb_; |
7733 | flatbuffers::uoffset_t start_; |
7734 | void add_values_count(int32_t values_count) { |
7735 | fbb_.AddElement<int32_t>(PackOptions::VT_VALUES_COUNT, values_count, 0); |
7736 | } |
7737 | void add_axis(int32_t axis) { |
7738 | fbb_.AddElement<int32_t>(PackOptions::VT_AXIS, axis, 0); |
7739 | } |
7740 | explicit PackOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7741 | : fbb_(_fbb) { |
7742 | start_ = fbb_.StartTable(); |
7743 | } |
7744 | PackOptionsBuilder &operator=(const PackOptionsBuilder &); |
7745 | flatbuffers::Offset<PackOptions> Finish() { |
7746 | const auto end = fbb_.EndTable(start_); |
7747 | auto o = flatbuffers::Offset<PackOptions>(end); |
7748 | return o; |
7749 | } |
7750 | }; |
7751 | |
7752 | inline flatbuffers::Offset<PackOptions> CreatePackOptions( |
7753 | flatbuffers::FlatBufferBuilder &_fbb, |
7754 | int32_t values_count = 0, |
7755 | int32_t axis = 0) { |
7756 | PackOptionsBuilder builder_(_fbb); |
7757 | builder_.add_axis(axis); |
7758 | builder_.add_values_count(values_count); |
7759 | return builder_.Finish(); |
7760 | } |
7761 | |
7762 | flatbuffers::Offset<PackOptions> CreatePackOptions(flatbuffers::FlatBufferBuilder &_fbb, const PackOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7763 | |
7764 | struct LogicalOrOptionsT : public flatbuffers::NativeTable { |
7765 | typedef LogicalOrOptions TableType; |
7766 | LogicalOrOptionsT() { |
7767 | } |
7768 | }; |
7769 | |
7770 | struct LogicalOrOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7771 | typedef LogicalOrOptionsT NativeTableType; |
7772 | bool Verify(flatbuffers::Verifier &verifier) const { |
7773 | return VerifyTableStart(verifier) && |
7774 | verifier.EndTable(); |
7775 | } |
7776 | LogicalOrOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7777 | void UnPackTo(LogicalOrOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7778 | static flatbuffers::Offset<LogicalOrOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogicalOrOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7779 | }; |
7780 | |
7781 | struct LogicalOrOptionsBuilder { |
7782 | flatbuffers::FlatBufferBuilder &fbb_; |
7783 | flatbuffers::uoffset_t start_; |
7784 | explicit LogicalOrOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7785 | : fbb_(_fbb) { |
7786 | start_ = fbb_.StartTable(); |
7787 | } |
7788 | LogicalOrOptionsBuilder &operator=(const LogicalOrOptionsBuilder &); |
7789 | flatbuffers::Offset<LogicalOrOptions> Finish() { |
7790 | const auto end = fbb_.EndTable(start_); |
7791 | auto o = flatbuffers::Offset<LogicalOrOptions>(end); |
7792 | return o; |
7793 | } |
7794 | }; |
7795 | |
7796 | inline flatbuffers::Offset<LogicalOrOptions> CreateLogicalOrOptions( |
7797 | flatbuffers::FlatBufferBuilder &_fbb) { |
7798 | LogicalOrOptionsBuilder builder_(_fbb); |
7799 | return builder_.Finish(); |
7800 | } |
7801 | |
7802 | flatbuffers::Offset<LogicalOrOptions> CreateLogicalOrOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogicalOrOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7803 | |
7804 | struct OneHotOptionsT : public flatbuffers::NativeTable { |
7805 | typedef OneHotOptions TableType; |
7806 | int32_t axis; |
7807 | OneHotOptionsT() |
7808 | : axis(0) { |
7809 | } |
7810 | }; |
7811 | |
7812 | struct OneHotOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7813 | typedef OneHotOptionsT NativeTableType; |
7814 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
7815 | VT_AXIS = 4 |
7816 | }; |
7817 | int32_t axis() const { |
7818 | return GetField<int32_t>(VT_AXIS, 0); |
7819 | } |
7820 | bool Verify(flatbuffers::Verifier &verifier) const { |
7821 | return VerifyTableStart(verifier) && |
7822 | VerifyField<int32_t>(verifier, VT_AXIS) && |
7823 | verifier.EndTable(); |
7824 | } |
7825 | OneHotOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7826 | void UnPackTo(OneHotOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7827 | static flatbuffers::Offset<OneHotOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const OneHotOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7828 | }; |
7829 | |
7830 | struct OneHotOptionsBuilder { |
7831 | flatbuffers::FlatBufferBuilder &fbb_; |
7832 | flatbuffers::uoffset_t start_; |
7833 | void add_axis(int32_t axis) { |
7834 | fbb_.AddElement<int32_t>(OneHotOptions::VT_AXIS, axis, 0); |
7835 | } |
7836 | explicit OneHotOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7837 | : fbb_(_fbb) { |
7838 | start_ = fbb_.StartTable(); |
7839 | } |
7840 | OneHotOptionsBuilder &operator=(const OneHotOptionsBuilder &); |
7841 | flatbuffers::Offset<OneHotOptions> Finish() { |
7842 | const auto end = fbb_.EndTable(start_); |
7843 | auto o = flatbuffers::Offset<OneHotOptions>(end); |
7844 | return o; |
7845 | } |
7846 | }; |
7847 | |
7848 | inline flatbuffers::Offset<OneHotOptions> CreateOneHotOptions( |
7849 | flatbuffers::FlatBufferBuilder &_fbb, |
7850 | int32_t axis = 0) { |
7851 | OneHotOptionsBuilder builder_(_fbb); |
7852 | builder_.add_axis(axis); |
7853 | return builder_.Finish(); |
7854 | } |
7855 | |
7856 | flatbuffers::Offset<OneHotOptions> CreateOneHotOptions(flatbuffers::FlatBufferBuilder &_fbb, const OneHotOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7857 | |
7858 | struct AbsOptionsT : public flatbuffers::NativeTable { |
7859 | typedef AbsOptions TableType; |
7860 | AbsOptionsT() { |
7861 | } |
7862 | }; |
7863 | |
7864 | struct AbsOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7865 | typedef AbsOptionsT NativeTableType; |
7866 | bool Verify(flatbuffers::Verifier &verifier) const { |
7867 | return VerifyTableStart(verifier) && |
7868 | verifier.EndTable(); |
7869 | } |
7870 | AbsOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7871 | void UnPackTo(AbsOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7872 | static flatbuffers::Offset<AbsOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AbsOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7873 | }; |
7874 | |
7875 | struct AbsOptionsBuilder { |
7876 | flatbuffers::FlatBufferBuilder &fbb_; |
7877 | flatbuffers::uoffset_t start_; |
7878 | explicit AbsOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7879 | : fbb_(_fbb) { |
7880 | start_ = fbb_.StartTable(); |
7881 | } |
7882 | AbsOptionsBuilder &operator=(const AbsOptionsBuilder &); |
7883 | flatbuffers::Offset<AbsOptions> Finish() { |
7884 | const auto end = fbb_.EndTable(start_); |
7885 | auto o = flatbuffers::Offset<AbsOptions>(end); |
7886 | return o; |
7887 | } |
7888 | }; |
7889 | |
7890 | inline flatbuffers::Offset<AbsOptions> CreateAbsOptions( |
7891 | flatbuffers::FlatBufferBuilder &_fbb) { |
7892 | AbsOptionsBuilder builder_(_fbb); |
7893 | return builder_.Finish(); |
7894 | } |
7895 | |
7896 | flatbuffers::Offset<AbsOptions> CreateAbsOptions(flatbuffers::FlatBufferBuilder &_fbb, const AbsOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7897 | |
7898 | struct HardSwishOptionsT : public flatbuffers::NativeTable { |
7899 | typedef HardSwishOptions TableType; |
7900 | HardSwishOptionsT() { |
7901 | } |
7902 | }; |
7903 | |
7904 | struct HardSwishOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7905 | typedef HardSwishOptionsT NativeTableType; |
7906 | bool Verify(flatbuffers::Verifier &verifier) const { |
7907 | return VerifyTableStart(verifier) && |
7908 | verifier.EndTable(); |
7909 | } |
7910 | HardSwishOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7911 | void UnPackTo(HardSwishOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7912 | static flatbuffers::Offset<HardSwishOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const HardSwishOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7913 | }; |
7914 | |
7915 | struct HardSwishOptionsBuilder { |
7916 | flatbuffers::FlatBufferBuilder &fbb_; |
7917 | flatbuffers::uoffset_t start_; |
7918 | explicit HardSwishOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7919 | : fbb_(_fbb) { |
7920 | start_ = fbb_.StartTable(); |
7921 | } |
7922 | HardSwishOptionsBuilder &operator=(const HardSwishOptionsBuilder &); |
7923 | flatbuffers::Offset<HardSwishOptions> Finish() { |
7924 | const auto end = fbb_.EndTable(start_); |
7925 | auto o = flatbuffers::Offset<HardSwishOptions>(end); |
7926 | return o; |
7927 | } |
7928 | }; |
7929 | |
7930 | inline flatbuffers::Offset<HardSwishOptions> CreateHardSwishOptions( |
7931 | flatbuffers::FlatBufferBuilder &_fbb) { |
7932 | HardSwishOptionsBuilder builder_(_fbb); |
7933 | return builder_.Finish(); |
7934 | } |
7935 | |
7936 | flatbuffers::Offset<HardSwishOptions> CreateHardSwishOptions(flatbuffers::FlatBufferBuilder &_fbb, const HardSwishOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7937 | |
7938 | struct LogicalAndOptionsT : public flatbuffers::NativeTable { |
7939 | typedef LogicalAndOptions TableType; |
7940 | LogicalAndOptionsT() { |
7941 | } |
7942 | }; |
7943 | |
7944 | struct LogicalAndOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7945 | typedef LogicalAndOptionsT NativeTableType; |
7946 | bool Verify(flatbuffers::Verifier &verifier) const { |
7947 | return VerifyTableStart(verifier) && |
7948 | verifier.EndTable(); |
7949 | } |
7950 | LogicalAndOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7951 | void UnPackTo(LogicalAndOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7952 | static flatbuffers::Offset<LogicalAndOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogicalAndOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7953 | }; |
7954 | |
7955 | struct LogicalAndOptionsBuilder { |
7956 | flatbuffers::FlatBufferBuilder &fbb_; |
7957 | flatbuffers::uoffset_t start_; |
7958 | explicit LogicalAndOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7959 | : fbb_(_fbb) { |
7960 | start_ = fbb_.StartTable(); |
7961 | } |
7962 | LogicalAndOptionsBuilder &operator=(const LogicalAndOptionsBuilder &); |
7963 | flatbuffers::Offset<LogicalAndOptions> Finish() { |
7964 | const auto end = fbb_.EndTable(start_); |
7965 | auto o = flatbuffers::Offset<LogicalAndOptions>(end); |
7966 | return o; |
7967 | } |
7968 | }; |
7969 | |
7970 | inline flatbuffers::Offset<LogicalAndOptions> CreateLogicalAndOptions( |
7971 | flatbuffers::FlatBufferBuilder &_fbb) { |
7972 | LogicalAndOptionsBuilder builder_(_fbb); |
7973 | return builder_.Finish(); |
7974 | } |
7975 | |
7976 | flatbuffers::Offset<LogicalAndOptions> CreateLogicalAndOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogicalAndOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7977 | |
7978 | struct LogicalNotOptionsT : public flatbuffers::NativeTable { |
7979 | typedef LogicalNotOptions TableType; |
7980 | LogicalNotOptionsT() { |
7981 | } |
7982 | }; |
7983 | |
7984 | struct LogicalNotOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
7985 | typedef LogicalNotOptionsT NativeTableType; |
7986 | bool Verify(flatbuffers::Verifier &verifier) const { |
7987 | return VerifyTableStart(verifier) && |
7988 | verifier.EndTable(); |
7989 | } |
7990 | LogicalNotOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7991 | void UnPackTo(LogicalNotOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
7992 | static flatbuffers::Offset<LogicalNotOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogicalNotOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
7993 | }; |
7994 | |
7995 | struct LogicalNotOptionsBuilder { |
7996 | flatbuffers::FlatBufferBuilder &fbb_; |
7997 | flatbuffers::uoffset_t start_; |
7998 | explicit LogicalNotOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
7999 | : fbb_(_fbb) { |
8000 | start_ = fbb_.StartTable(); |
8001 | } |
8002 | LogicalNotOptionsBuilder &operator=(const LogicalNotOptionsBuilder &); |
8003 | flatbuffers::Offset<LogicalNotOptions> Finish() { |
8004 | const auto end = fbb_.EndTable(start_); |
8005 | auto o = flatbuffers::Offset<LogicalNotOptions>(end); |
8006 | return o; |
8007 | } |
8008 | }; |
8009 | |
8010 | inline flatbuffers::Offset<LogicalNotOptions> CreateLogicalNotOptions( |
8011 | flatbuffers::FlatBufferBuilder &_fbb) { |
8012 | LogicalNotOptionsBuilder builder_(_fbb); |
8013 | return builder_.Finish(); |
8014 | } |
8015 | |
8016 | flatbuffers::Offset<LogicalNotOptions> CreateLogicalNotOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogicalNotOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8017 | |
8018 | struct UnpackOptionsT : public flatbuffers::NativeTable { |
8019 | typedef UnpackOptions TableType; |
8020 | int32_t num; |
8021 | int32_t axis; |
8022 | UnpackOptionsT() |
8023 | : num(0), |
8024 | axis(0) { |
8025 | } |
8026 | }; |
8027 | |
8028 | struct UnpackOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8029 | typedef UnpackOptionsT NativeTableType; |
8030 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8031 | VT_NUM = 4, |
8032 | VT_AXIS = 6 |
8033 | }; |
8034 | int32_t num() const { |
8035 | return GetField<int32_t>(VT_NUM, 0); |
8036 | } |
8037 | int32_t axis() const { |
8038 | return GetField<int32_t>(VT_AXIS, 0); |
8039 | } |
8040 | bool Verify(flatbuffers::Verifier &verifier) const { |
8041 | return VerifyTableStart(verifier) && |
8042 | VerifyField<int32_t>(verifier, VT_NUM) && |
8043 | VerifyField<int32_t>(verifier, VT_AXIS) && |
8044 | verifier.EndTable(); |
8045 | } |
8046 | UnpackOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8047 | void UnPackTo(UnpackOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8048 | static flatbuffers::Offset<UnpackOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const UnpackOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8049 | }; |
8050 | |
8051 | struct UnpackOptionsBuilder { |
8052 | flatbuffers::FlatBufferBuilder &fbb_; |
8053 | flatbuffers::uoffset_t start_; |
8054 | void add_num(int32_t num) { |
8055 | fbb_.AddElement<int32_t>(UnpackOptions::VT_NUM, num, 0); |
8056 | } |
8057 | void add_axis(int32_t axis) { |
8058 | fbb_.AddElement<int32_t>(UnpackOptions::VT_AXIS, axis, 0); |
8059 | } |
8060 | explicit UnpackOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8061 | : fbb_(_fbb) { |
8062 | start_ = fbb_.StartTable(); |
8063 | } |
8064 | UnpackOptionsBuilder &operator=(const UnpackOptionsBuilder &); |
8065 | flatbuffers::Offset<UnpackOptions> Finish() { |
8066 | const auto end = fbb_.EndTable(start_); |
8067 | auto o = flatbuffers::Offset<UnpackOptions>(end); |
8068 | return o; |
8069 | } |
8070 | }; |
8071 | |
8072 | inline flatbuffers::Offset<UnpackOptions> CreateUnpackOptions( |
8073 | flatbuffers::FlatBufferBuilder &_fbb, |
8074 | int32_t num = 0, |
8075 | int32_t axis = 0) { |
8076 | UnpackOptionsBuilder builder_(_fbb); |
8077 | builder_.add_axis(axis); |
8078 | builder_.add_num(num); |
8079 | return builder_.Finish(); |
8080 | } |
8081 | |
8082 | flatbuffers::Offset<UnpackOptions> CreateUnpackOptions(flatbuffers::FlatBufferBuilder &_fbb, const UnpackOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8083 | |
8084 | struct FloorDivOptionsT : public flatbuffers::NativeTable { |
8085 | typedef FloorDivOptions TableType; |
8086 | FloorDivOptionsT() { |
8087 | } |
8088 | }; |
8089 | |
8090 | struct FloorDivOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8091 | typedef FloorDivOptionsT NativeTableType; |
8092 | bool Verify(flatbuffers::Verifier &verifier) const { |
8093 | return VerifyTableStart(verifier) && |
8094 | verifier.EndTable(); |
8095 | } |
8096 | FloorDivOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8097 | void UnPackTo(FloorDivOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8098 | static flatbuffers::Offset<FloorDivOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const FloorDivOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8099 | }; |
8100 | |
8101 | struct FloorDivOptionsBuilder { |
8102 | flatbuffers::FlatBufferBuilder &fbb_; |
8103 | flatbuffers::uoffset_t start_; |
8104 | explicit FloorDivOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8105 | : fbb_(_fbb) { |
8106 | start_ = fbb_.StartTable(); |
8107 | } |
8108 | FloorDivOptionsBuilder &operator=(const FloorDivOptionsBuilder &); |
8109 | flatbuffers::Offset<FloorDivOptions> Finish() { |
8110 | const auto end = fbb_.EndTable(start_); |
8111 | auto o = flatbuffers::Offset<FloorDivOptions>(end); |
8112 | return o; |
8113 | } |
8114 | }; |
8115 | |
8116 | inline flatbuffers::Offset<FloorDivOptions> CreateFloorDivOptions( |
8117 | flatbuffers::FlatBufferBuilder &_fbb) { |
8118 | FloorDivOptionsBuilder builder_(_fbb); |
8119 | return builder_.Finish(); |
8120 | } |
8121 | |
8122 | flatbuffers::Offset<FloorDivOptions> CreateFloorDivOptions(flatbuffers::FlatBufferBuilder &_fbb, const FloorDivOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8123 | |
8124 | struct SquareOptionsT : public flatbuffers::NativeTable { |
8125 | typedef SquareOptions TableType; |
8126 | SquareOptionsT() { |
8127 | } |
8128 | }; |
8129 | |
8130 | struct SquareOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8131 | typedef SquareOptionsT NativeTableType; |
8132 | bool Verify(flatbuffers::Verifier &verifier) const { |
8133 | return VerifyTableStart(verifier) && |
8134 | verifier.EndTable(); |
8135 | } |
8136 | SquareOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8137 | void UnPackTo(SquareOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8138 | static flatbuffers::Offset<SquareOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SquareOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8139 | }; |
8140 | |
8141 | struct SquareOptionsBuilder { |
8142 | flatbuffers::FlatBufferBuilder &fbb_; |
8143 | flatbuffers::uoffset_t start_; |
8144 | explicit SquareOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8145 | : fbb_(_fbb) { |
8146 | start_ = fbb_.StartTable(); |
8147 | } |
8148 | SquareOptionsBuilder &operator=(const SquareOptionsBuilder &); |
8149 | flatbuffers::Offset<SquareOptions> Finish() { |
8150 | const auto end = fbb_.EndTable(start_); |
8151 | auto o = flatbuffers::Offset<SquareOptions>(end); |
8152 | return o; |
8153 | } |
8154 | }; |
8155 | |
8156 | inline flatbuffers::Offset<SquareOptions> CreateSquareOptions( |
8157 | flatbuffers::FlatBufferBuilder &_fbb) { |
8158 | SquareOptionsBuilder builder_(_fbb); |
8159 | return builder_.Finish(); |
8160 | } |
8161 | |
8162 | flatbuffers::Offset<SquareOptions> CreateSquareOptions(flatbuffers::FlatBufferBuilder &_fbb, const SquareOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8163 | |
8164 | struct ZerosLikeOptionsT : public flatbuffers::NativeTable { |
8165 | typedef ZerosLikeOptions TableType; |
8166 | ZerosLikeOptionsT() { |
8167 | } |
8168 | }; |
8169 | |
8170 | struct ZerosLikeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8171 | typedef ZerosLikeOptionsT NativeTableType; |
8172 | bool Verify(flatbuffers::Verifier &verifier) const { |
8173 | return VerifyTableStart(verifier) && |
8174 | verifier.EndTable(); |
8175 | } |
8176 | ZerosLikeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8177 | void UnPackTo(ZerosLikeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8178 | static flatbuffers::Offset<ZerosLikeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ZerosLikeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8179 | }; |
8180 | |
8181 | struct ZerosLikeOptionsBuilder { |
8182 | flatbuffers::FlatBufferBuilder &fbb_; |
8183 | flatbuffers::uoffset_t start_; |
8184 | explicit ZerosLikeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8185 | : fbb_(_fbb) { |
8186 | start_ = fbb_.StartTable(); |
8187 | } |
8188 | ZerosLikeOptionsBuilder &operator=(const ZerosLikeOptionsBuilder &); |
8189 | flatbuffers::Offset<ZerosLikeOptions> Finish() { |
8190 | const auto end = fbb_.EndTable(start_); |
8191 | auto o = flatbuffers::Offset<ZerosLikeOptions>(end); |
8192 | return o; |
8193 | } |
8194 | }; |
8195 | |
8196 | inline flatbuffers::Offset<ZerosLikeOptions> CreateZerosLikeOptions( |
8197 | flatbuffers::FlatBufferBuilder &_fbb) { |
8198 | ZerosLikeOptionsBuilder builder_(_fbb); |
8199 | return builder_.Finish(); |
8200 | } |
8201 | |
8202 | flatbuffers::Offset<ZerosLikeOptions> CreateZerosLikeOptions(flatbuffers::FlatBufferBuilder &_fbb, const ZerosLikeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8203 | |
8204 | struct FillOptionsT : public flatbuffers::NativeTable { |
8205 | typedef FillOptions TableType; |
8206 | FillOptionsT() { |
8207 | } |
8208 | }; |
8209 | |
8210 | struct FillOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8211 | typedef FillOptionsT NativeTableType; |
8212 | bool Verify(flatbuffers::Verifier &verifier) const { |
8213 | return VerifyTableStart(verifier) && |
8214 | verifier.EndTable(); |
8215 | } |
8216 | FillOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8217 | void UnPackTo(FillOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8218 | static flatbuffers::Offset<FillOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const FillOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8219 | }; |
8220 | |
8221 | struct FillOptionsBuilder { |
8222 | flatbuffers::FlatBufferBuilder &fbb_; |
8223 | flatbuffers::uoffset_t start_; |
8224 | explicit FillOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8225 | : fbb_(_fbb) { |
8226 | start_ = fbb_.StartTable(); |
8227 | } |
8228 | FillOptionsBuilder &operator=(const FillOptionsBuilder &); |
8229 | flatbuffers::Offset<FillOptions> Finish() { |
8230 | const auto end = fbb_.EndTable(start_); |
8231 | auto o = flatbuffers::Offset<FillOptions>(end); |
8232 | return o; |
8233 | } |
8234 | }; |
8235 | |
8236 | inline flatbuffers::Offset<FillOptions> CreateFillOptions( |
8237 | flatbuffers::FlatBufferBuilder &_fbb) { |
8238 | FillOptionsBuilder builder_(_fbb); |
8239 | return builder_.Finish(); |
8240 | } |
8241 | |
8242 | flatbuffers::Offset<FillOptions> CreateFillOptions(flatbuffers::FlatBufferBuilder &_fbb, const FillOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8243 | |
8244 | struct FloorModOptionsT : public flatbuffers::NativeTable { |
8245 | typedef FloorModOptions TableType; |
8246 | FloorModOptionsT() { |
8247 | } |
8248 | }; |
8249 | |
8250 | struct FloorModOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8251 | typedef FloorModOptionsT NativeTableType; |
8252 | bool Verify(flatbuffers::Verifier &verifier) const { |
8253 | return VerifyTableStart(verifier) && |
8254 | verifier.EndTable(); |
8255 | } |
8256 | FloorModOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8257 | void UnPackTo(FloorModOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8258 | static flatbuffers::Offset<FloorModOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const FloorModOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8259 | }; |
8260 | |
8261 | struct FloorModOptionsBuilder { |
8262 | flatbuffers::FlatBufferBuilder &fbb_; |
8263 | flatbuffers::uoffset_t start_; |
8264 | explicit FloorModOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8265 | : fbb_(_fbb) { |
8266 | start_ = fbb_.StartTable(); |
8267 | } |
8268 | FloorModOptionsBuilder &operator=(const FloorModOptionsBuilder &); |
8269 | flatbuffers::Offset<FloorModOptions> Finish() { |
8270 | const auto end = fbb_.EndTable(start_); |
8271 | auto o = flatbuffers::Offset<FloorModOptions>(end); |
8272 | return o; |
8273 | } |
8274 | }; |
8275 | |
8276 | inline flatbuffers::Offset<FloorModOptions> CreateFloorModOptions( |
8277 | flatbuffers::FlatBufferBuilder &_fbb) { |
8278 | FloorModOptionsBuilder builder_(_fbb); |
8279 | return builder_.Finish(); |
8280 | } |
8281 | |
8282 | flatbuffers::Offset<FloorModOptions> CreateFloorModOptions(flatbuffers::FlatBufferBuilder &_fbb, const FloorModOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8283 | |
8284 | struct RangeOptionsT : public flatbuffers::NativeTable { |
8285 | typedef RangeOptions TableType; |
8286 | RangeOptionsT() { |
8287 | } |
8288 | }; |
8289 | |
8290 | struct RangeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8291 | typedef RangeOptionsT NativeTableType; |
8292 | bool Verify(flatbuffers::Verifier &verifier) const { |
8293 | return VerifyTableStart(verifier) && |
8294 | verifier.EndTable(); |
8295 | } |
8296 | RangeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8297 | void UnPackTo(RangeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8298 | static flatbuffers::Offset<RangeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const RangeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8299 | }; |
8300 | |
8301 | struct RangeOptionsBuilder { |
8302 | flatbuffers::FlatBufferBuilder &fbb_; |
8303 | flatbuffers::uoffset_t start_; |
8304 | explicit RangeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8305 | : fbb_(_fbb) { |
8306 | start_ = fbb_.StartTable(); |
8307 | } |
8308 | RangeOptionsBuilder &operator=(const RangeOptionsBuilder &); |
8309 | flatbuffers::Offset<RangeOptions> Finish() { |
8310 | const auto end = fbb_.EndTable(start_); |
8311 | auto o = flatbuffers::Offset<RangeOptions>(end); |
8312 | return o; |
8313 | } |
8314 | }; |
8315 | |
8316 | inline flatbuffers::Offset<RangeOptions> CreateRangeOptions( |
8317 | flatbuffers::FlatBufferBuilder &_fbb) { |
8318 | RangeOptionsBuilder builder_(_fbb); |
8319 | return builder_.Finish(); |
8320 | } |
8321 | |
8322 | flatbuffers::Offset<RangeOptions> CreateRangeOptions(flatbuffers::FlatBufferBuilder &_fbb, const RangeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8323 | |
8324 | struct LeakyReluOptionsT : public flatbuffers::NativeTable { |
8325 | typedef LeakyReluOptions TableType; |
8326 | float alpha; |
8327 | LeakyReluOptionsT() |
8328 | : alpha(0.0f) { |
8329 | } |
8330 | }; |
8331 | |
8332 | struct LeakyReluOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8333 | typedef LeakyReluOptionsT NativeTableType; |
8334 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8335 | VT_ALPHA = 4 |
8336 | }; |
8337 | float alpha() const { |
8338 | return GetField<float>(VT_ALPHA, 0.0f); |
8339 | } |
8340 | bool Verify(flatbuffers::Verifier &verifier) const { |
8341 | return VerifyTableStart(verifier) && |
8342 | VerifyField<float>(verifier, VT_ALPHA) && |
8343 | verifier.EndTable(); |
8344 | } |
8345 | LeakyReluOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8346 | void UnPackTo(LeakyReluOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8347 | static flatbuffers::Offset<LeakyReluOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const LeakyReluOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8348 | }; |
8349 | |
8350 | struct LeakyReluOptionsBuilder { |
8351 | flatbuffers::FlatBufferBuilder &fbb_; |
8352 | flatbuffers::uoffset_t start_; |
8353 | void add_alpha(float alpha) { |
8354 | fbb_.AddElement<float>(LeakyReluOptions::VT_ALPHA, alpha, 0.0f); |
8355 | } |
8356 | explicit LeakyReluOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8357 | : fbb_(_fbb) { |
8358 | start_ = fbb_.StartTable(); |
8359 | } |
8360 | LeakyReluOptionsBuilder &operator=(const LeakyReluOptionsBuilder &); |
8361 | flatbuffers::Offset<LeakyReluOptions> Finish() { |
8362 | const auto end = fbb_.EndTable(start_); |
8363 | auto o = flatbuffers::Offset<LeakyReluOptions>(end); |
8364 | return o; |
8365 | } |
8366 | }; |
8367 | |
8368 | inline flatbuffers::Offset<LeakyReluOptions> CreateLeakyReluOptions( |
8369 | flatbuffers::FlatBufferBuilder &_fbb, |
8370 | float alpha = 0.0f) { |
8371 | LeakyReluOptionsBuilder builder_(_fbb); |
8372 | builder_.add_alpha(alpha); |
8373 | return builder_.Finish(); |
8374 | } |
8375 | |
8376 | flatbuffers::Offset<LeakyReluOptions> CreateLeakyReluOptions(flatbuffers::FlatBufferBuilder &_fbb, const LeakyReluOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8377 | |
8378 | struct SquaredDifferenceOptionsT : public flatbuffers::NativeTable { |
8379 | typedef SquaredDifferenceOptions TableType; |
8380 | SquaredDifferenceOptionsT() { |
8381 | } |
8382 | }; |
8383 | |
8384 | struct SquaredDifferenceOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8385 | typedef SquaredDifferenceOptionsT NativeTableType; |
8386 | bool Verify(flatbuffers::Verifier &verifier) const { |
8387 | return VerifyTableStart(verifier) && |
8388 | verifier.EndTable(); |
8389 | } |
8390 | SquaredDifferenceOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8391 | void UnPackTo(SquaredDifferenceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8392 | static flatbuffers::Offset<SquaredDifferenceOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SquaredDifferenceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8393 | }; |
8394 | |
8395 | struct SquaredDifferenceOptionsBuilder { |
8396 | flatbuffers::FlatBufferBuilder &fbb_; |
8397 | flatbuffers::uoffset_t start_; |
8398 | explicit SquaredDifferenceOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8399 | : fbb_(_fbb) { |
8400 | start_ = fbb_.StartTable(); |
8401 | } |
8402 | SquaredDifferenceOptionsBuilder &operator=(const SquaredDifferenceOptionsBuilder &); |
8403 | flatbuffers::Offset<SquaredDifferenceOptions> Finish() { |
8404 | const auto end = fbb_.EndTable(start_); |
8405 | auto o = flatbuffers::Offset<SquaredDifferenceOptions>(end); |
8406 | return o; |
8407 | } |
8408 | }; |
8409 | |
8410 | inline flatbuffers::Offset<SquaredDifferenceOptions> CreateSquaredDifferenceOptions( |
8411 | flatbuffers::FlatBufferBuilder &_fbb) { |
8412 | SquaredDifferenceOptionsBuilder builder_(_fbb); |
8413 | return builder_.Finish(); |
8414 | } |
8415 | |
8416 | flatbuffers::Offset<SquaredDifferenceOptions> CreateSquaredDifferenceOptions(flatbuffers::FlatBufferBuilder &_fbb, const SquaredDifferenceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8417 | |
8418 | struct MirrorPadOptionsT : public flatbuffers::NativeTable { |
8419 | typedef MirrorPadOptions TableType; |
8420 | tflite::MirrorPadMode mode; |
8421 | MirrorPadOptionsT() |
8422 | : mode(tflite::MirrorPadMode_REFLECT) { |
8423 | } |
8424 | }; |
8425 | |
8426 | struct MirrorPadOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8427 | typedef MirrorPadOptionsT NativeTableType; |
8428 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8429 | VT_MODE = 4 |
8430 | }; |
8431 | tflite::MirrorPadMode mode() const { |
8432 | return static_cast<tflite::MirrorPadMode>(GetField<int8_t>(VT_MODE, 0)); |
8433 | } |
8434 | bool Verify(flatbuffers::Verifier &verifier) const { |
8435 | return VerifyTableStart(verifier) && |
8436 | VerifyField<int8_t>(verifier, VT_MODE) && |
8437 | verifier.EndTable(); |
8438 | } |
8439 | MirrorPadOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8440 | void UnPackTo(MirrorPadOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8441 | static flatbuffers::Offset<MirrorPadOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const MirrorPadOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8442 | }; |
8443 | |
8444 | struct MirrorPadOptionsBuilder { |
8445 | flatbuffers::FlatBufferBuilder &fbb_; |
8446 | flatbuffers::uoffset_t start_; |
8447 | void add_mode(tflite::MirrorPadMode mode) { |
8448 | fbb_.AddElement<int8_t>(MirrorPadOptions::VT_MODE, static_cast<int8_t>(mode), 0); |
8449 | } |
8450 | explicit MirrorPadOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8451 | : fbb_(_fbb) { |
8452 | start_ = fbb_.StartTable(); |
8453 | } |
8454 | MirrorPadOptionsBuilder &operator=(const MirrorPadOptionsBuilder &); |
8455 | flatbuffers::Offset<MirrorPadOptions> Finish() { |
8456 | const auto end = fbb_.EndTable(start_); |
8457 | auto o = flatbuffers::Offset<MirrorPadOptions>(end); |
8458 | return o; |
8459 | } |
8460 | }; |
8461 | |
8462 | inline flatbuffers::Offset<MirrorPadOptions> CreateMirrorPadOptions( |
8463 | flatbuffers::FlatBufferBuilder &_fbb, |
8464 | tflite::MirrorPadMode mode = tflite::MirrorPadMode_REFLECT) { |
8465 | MirrorPadOptionsBuilder builder_(_fbb); |
8466 | builder_.add_mode(mode); |
8467 | return builder_.Finish(); |
8468 | } |
8469 | |
8470 | flatbuffers::Offset<MirrorPadOptions> CreateMirrorPadOptions(flatbuffers::FlatBufferBuilder &_fbb, const MirrorPadOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8471 | |
8472 | struct UniqueOptionsT : public flatbuffers::NativeTable { |
8473 | typedef UniqueOptions TableType; |
8474 | tflite::TensorType idx_out_type; |
8475 | UniqueOptionsT() |
8476 | : idx_out_type(tflite::TensorType_INT32) { |
8477 | } |
8478 | }; |
8479 | |
8480 | struct UniqueOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8481 | typedef UniqueOptionsT NativeTableType; |
8482 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8483 | VT_IDX_OUT_TYPE = 4 |
8484 | }; |
8485 | tflite::TensorType idx_out_type() const { |
8486 | return static_cast<tflite::TensorType>(GetField<int8_t>(VT_IDX_OUT_TYPE, 2)); |
8487 | } |
8488 | bool Verify(flatbuffers::Verifier &verifier) const { |
8489 | return VerifyTableStart(verifier) && |
8490 | VerifyField<int8_t>(verifier, VT_IDX_OUT_TYPE) && |
8491 | verifier.EndTable(); |
8492 | } |
8493 | UniqueOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8494 | void UnPackTo(UniqueOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8495 | static flatbuffers::Offset<UniqueOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const UniqueOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8496 | }; |
8497 | |
8498 | struct UniqueOptionsBuilder { |
8499 | flatbuffers::FlatBufferBuilder &fbb_; |
8500 | flatbuffers::uoffset_t start_; |
8501 | void add_idx_out_type(tflite::TensorType idx_out_type) { |
8502 | fbb_.AddElement<int8_t>(UniqueOptions::VT_IDX_OUT_TYPE, static_cast<int8_t>(idx_out_type), 2); |
8503 | } |
8504 | explicit UniqueOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8505 | : fbb_(_fbb) { |
8506 | start_ = fbb_.StartTable(); |
8507 | } |
8508 | UniqueOptionsBuilder &operator=(const UniqueOptionsBuilder &); |
8509 | flatbuffers::Offset<UniqueOptions> Finish() { |
8510 | const auto end = fbb_.EndTable(start_); |
8511 | auto o = flatbuffers::Offset<UniqueOptions>(end); |
8512 | return o; |
8513 | } |
8514 | }; |
8515 | |
8516 | inline flatbuffers::Offset<UniqueOptions> CreateUniqueOptions( |
8517 | flatbuffers::FlatBufferBuilder &_fbb, |
8518 | tflite::TensorType idx_out_type = tflite::TensorType_INT32) { |
8519 | UniqueOptionsBuilder builder_(_fbb); |
8520 | builder_.add_idx_out_type(idx_out_type); |
8521 | return builder_.Finish(); |
8522 | } |
8523 | |
8524 | flatbuffers::Offset<UniqueOptions> CreateUniqueOptions(flatbuffers::FlatBufferBuilder &_fbb, const UniqueOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8525 | |
8526 | struct ReverseV2OptionsT : public flatbuffers::NativeTable { |
8527 | typedef ReverseV2Options TableType; |
8528 | ReverseV2OptionsT() { |
8529 | } |
8530 | }; |
8531 | |
8532 | struct ReverseV2Options FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8533 | typedef ReverseV2OptionsT NativeTableType; |
8534 | bool Verify(flatbuffers::Verifier &verifier) const { |
8535 | return VerifyTableStart(verifier) && |
8536 | verifier.EndTable(); |
8537 | } |
8538 | ReverseV2OptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8539 | void UnPackTo(ReverseV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8540 | static flatbuffers::Offset<ReverseV2Options> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReverseV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8541 | }; |
8542 | |
8543 | struct ReverseV2OptionsBuilder { |
8544 | flatbuffers::FlatBufferBuilder &fbb_; |
8545 | flatbuffers::uoffset_t start_; |
8546 | explicit ReverseV2OptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8547 | : fbb_(_fbb) { |
8548 | start_ = fbb_.StartTable(); |
8549 | } |
8550 | ReverseV2OptionsBuilder &operator=(const ReverseV2OptionsBuilder &); |
8551 | flatbuffers::Offset<ReverseV2Options> Finish() { |
8552 | const auto end = fbb_.EndTable(start_); |
8553 | auto o = flatbuffers::Offset<ReverseV2Options>(end); |
8554 | return o; |
8555 | } |
8556 | }; |
8557 | |
8558 | inline flatbuffers::Offset<ReverseV2Options> CreateReverseV2Options( |
8559 | flatbuffers::FlatBufferBuilder &_fbb) { |
8560 | ReverseV2OptionsBuilder builder_(_fbb); |
8561 | return builder_.Finish(); |
8562 | } |
8563 | |
8564 | flatbuffers::Offset<ReverseV2Options> CreateReverseV2Options(flatbuffers::FlatBufferBuilder &_fbb, const ReverseV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8565 | |
8566 | struct AddNOptionsT : public flatbuffers::NativeTable { |
8567 | typedef AddNOptions TableType; |
8568 | AddNOptionsT() { |
8569 | } |
8570 | }; |
8571 | |
8572 | struct AddNOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8573 | typedef AddNOptionsT NativeTableType; |
8574 | bool Verify(flatbuffers::Verifier &verifier) const { |
8575 | return VerifyTableStart(verifier) && |
8576 | verifier.EndTable(); |
8577 | } |
8578 | AddNOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8579 | void UnPackTo(AddNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8580 | static flatbuffers::Offset<AddNOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AddNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8581 | }; |
8582 | |
8583 | struct AddNOptionsBuilder { |
8584 | flatbuffers::FlatBufferBuilder &fbb_; |
8585 | flatbuffers::uoffset_t start_; |
8586 | explicit AddNOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8587 | : fbb_(_fbb) { |
8588 | start_ = fbb_.StartTable(); |
8589 | } |
8590 | AddNOptionsBuilder &operator=(const AddNOptionsBuilder &); |
8591 | flatbuffers::Offset<AddNOptions> Finish() { |
8592 | const auto end = fbb_.EndTable(start_); |
8593 | auto o = flatbuffers::Offset<AddNOptions>(end); |
8594 | return o; |
8595 | } |
8596 | }; |
8597 | |
8598 | inline flatbuffers::Offset<AddNOptions> CreateAddNOptions( |
8599 | flatbuffers::FlatBufferBuilder &_fbb) { |
8600 | AddNOptionsBuilder builder_(_fbb); |
8601 | return builder_.Finish(); |
8602 | } |
8603 | |
8604 | flatbuffers::Offset<AddNOptions> CreateAddNOptions(flatbuffers::FlatBufferBuilder &_fbb, const AddNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8605 | |
8606 | struct GatherNdOptionsT : public flatbuffers::NativeTable { |
8607 | typedef GatherNdOptions TableType; |
8608 | GatherNdOptionsT() { |
8609 | } |
8610 | }; |
8611 | |
8612 | struct GatherNdOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8613 | typedef GatherNdOptionsT NativeTableType; |
8614 | bool Verify(flatbuffers::Verifier &verifier) const { |
8615 | return VerifyTableStart(verifier) && |
8616 | verifier.EndTable(); |
8617 | } |
8618 | GatherNdOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8619 | void UnPackTo(GatherNdOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8620 | static flatbuffers::Offset<GatherNdOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const GatherNdOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8621 | }; |
8622 | |
8623 | struct GatherNdOptionsBuilder { |
8624 | flatbuffers::FlatBufferBuilder &fbb_; |
8625 | flatbuffers::uoffset_t start_; |
8626 | explicit GatherNdOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8627 | : fbb_(_fbb) { |
8628 | start_ = fbb_.StartTable(); |
8629 | } |
8630 | GatherNdOptionsBuilder &operator=(const GatherNdOptionsBuilder &); |
8631 | flatbuffers::Offset<GatherNdOptions> Finish() { |
8632 | const auto end = fbb_.EndTable(start_); |
8633 | auto o = flatbuffers::Offset<GatherNdOptions>(end); |
8634 | return o; |
8635 | } |
8636 | }; |
8637 | |
8638 | inline flatbuffers::Offset<GatherNdOptions> CreateGatherNdOptions( |
8639 | flatbuffers::FlatBufferBuilder &_fbb) { |
8640 | GatherNdOptionsBuilder builder_(_fbb); |
8641 | return builder_.Finish(); |
8642 | } |
8643 | |
8644 | flatbuffers::Offset<GatherNdOptions> CreateGatherNdOptions(flatbuffers::FlatBufferBuilder &_fbb, const GatherNdOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8645 | |
8646 | struct WhereOptionsT : public flatbuffers::NativeTable { |
8647 | typedef WhereOptions TableType; |
8648 | WhereOptionsT() { |
8649 | } |
8650 | }; |
8651 | |
8652 | struct WhereOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8653 | typedef WhereOptionsT NativeTableType; |
8654 | bool Verify(flatbuffers::Verifier &verifier) const { |
8655 | return VerifyTableStart(verifier) && |
8656 | verifier.EndTable(); |
8657 | } |
8658 | WhereOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8659 | void UnPackTo(WhereOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8660 | static flatbuffers::Offset<WhereOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const WhereOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8661 | }; |
8662 | |
8663 | struct WhereOptionsBuilder { |
8664 | flatbuffers::FlatBufferBuilder &fbb_; |
8665 | flatbuffers::uoffset_t start_; |
8666 | explicit WhereOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8667 | : fbb_(_fbb) { |
8668 | start_ = fbb_.StartTable(); |
8669 | } |
8670 | WhereOptionsBuilder &operator=(const WhereOptionsBuilder &); |
8671 | flatbuffers::Offset<WhereOptions> Finish() { |
8672 | const auto end = fbb_.EndTable(start_); |
8673 | auto o = flatbuffers::Offset<WhereOptions>(end); |
8674 | return o; |
8675 | } |
8676 | }; |
8677 | |
8678 | inline flatbuffers::Offset<WhereOptions> CreateWhereOptions( |
8679 | flatbuffers::FlatBufferBuilder &_fbb) { |
8680 | WhereOptionsBuilder builder_(_fbb); |
8681 | return builder_.Finish(); |
8682 | } |
8683 | |
8684 | flatbuffers::Offset<WhereOptions> CreateWhereOptions(flatbuffers::FlatBufferBuilder &_fbb, const WhereOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8685 | |
8686 | struct ReverseSequenceOptionsT : public flatbuffers::NativeTable { |
8687 | typedef ReverseSequenceOptions TableType; |
8688 | int32_t seq_dim; |
8689 | int32_t batch_dim; |
8690 | ReverseSequenceOptionsT() |
8691 | : seq_dim(0), |
8692 | batch_dim(0) { |
8693 | } |
8694 | }; |
8695 | |
8696 | struct ReverseSequenceOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8697 | typedef ReverseSequenceOptionsT NativeTableType; |
8698 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8699 | VT_SEQ_DIM = 4, |
8700 | VT_BATCH_DIM = 6 |
8701 | }; |
8702 | int32_t seq_dim() const { |
8703 | return GetField<int32_t>(VT_SEQ_DIM, 0); |
8704 | } |
8705 | int32_t batch_dim() const { |
8706 | return GetField<int32_t>(VT_BATCH_DIM, 0); |
8707 | } |
8708 | bool Verify(flatbuffers::Verifier &verifier) const { |
8709 | return VerifyTableStart(verifier) && |
8710 | VerifyField<int32_t>(verifier, VT_SEQ_DIM) && |
8711 | VerifyField<int32_t>(verifier, VT_BATCH_DIM) && |
8712 | verifier.EndTable(); |
8713 | } |
8714 | ReverseSequenceOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8715 | void UnPackTo(ReverseSequenceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8716 | static flatbuffers::Offset<ReverseSequenceOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReverseSequenceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8717 | }; |
8718 | |
8719 | struct ReverseSequenceOptionsBuilder { |
8720 | flatbuffers::FlatBufferBuilder &fbb_; |
8721 | flatbuffers::uoffset_t start_; |
8722 | void add_seq_dim(int32_t seq_dim) { |
8723 | fbb_.AddElement<int32_t>(ReverseSequenceOptions::VT_SEQ_DIM, seq_dim, 0); |
8724 | } |
8725 | void add_batch_dim(int32_t batch_dim) { |
8726 | fbb_.AddElement<int32_t>(ReverseSequenceOptions::VT_BATCH_DIM, batch_dim, 0); |
8727 | } |
8728 | explicit ReverseSequenceOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8729 | : fbb_(_fbb) { |
8730 | start_ = fbb_.StartTable(); |
8731 | } |
8732 | ReverseSequenceOptionsBuilder &operator=(const ReverseSequenceOptionsBuilder &); |
8733 | flatbuffers::Offset<ReverseSequenceOptions> Finish() { |
8734 | const auto end = fbb_.EndTable(start_); |
8735 | auto o = flatbuffers::Offset<ReverseSequenceOptions>(end); |
8736 | return o; |
8737 | } |
8738 | }; |
8739 | |
8740 | inline flatbuffers::Offset<ReverseSequenceOptions> CreateReverseSequenceOptions( |
8741 | flatbuffers::FlatBufferBuilder &_fbb, |
8742 | int32_t seq_dim = 0, |
8743 | int32_t batch_dim = 0) { |
8744 | ReverseSequenceOptionsBuilder builder_(_fbb); |
8745 | builder_.add_batch_dim(batch_dim); |
8746 | builder_.add_seq_dim(seq_dim); |
8747 | return builder_.Finish(); |
8748 | } |
8749 | |
8750 | flatbuffers::Offset<ReverseSequenceOptions> CreateReverseSequenceOptions(flatbuffers::FlatBufferBuilder &_fbb, const ReverseSequenceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8751 | |
8752 | struct MatrixDiagOptionsT : public flatbuffers::NativeTable { |
8753 | typedef MatrixDiagOptions TableType; |
8754 | MatrixDiagOptionsT() { |
8755 | } |
8756 | }; |
8757 | |
8758 | struct MatrixDiagOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8759 | typedef MatrixDiagOptionsT NativeTableType; |
8760 | bool Verify(flatbuffers::Verifier &verifier) const { |
8761 | return VerifyTableStart(verifier) && |
8762 | verifier.EndTable(); |
8763 | } |
8764 | MatrixDiagOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8765 | void UnPackTo(MatrixDiagOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8766 | static flatbuffers::Offset<MatrixDiagOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const MatrixDiagOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8767 | }; |
8768 | |
8769 | struct MatrixDiagOptionsBuilder { |
8770 | flatbuffers::FlatBufferBuilder &fbb_; |
8771 | flatbuffers::uoffset_t start_; |
8772 | explicit MatrixDiagOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8773 | : fbb_(_fbb) { |
8774 | start_ = fbb_.StartTable(); |
8775 | } |
8776 | MatrixDiagOptionsBuilder &operator=(const MatrixDiagOptionsBuilder &); |
8777 | flatbuffers::Offset<MatrixDiagOptions> Finish() { |
8778 | const auto end = fbb_.EndTable(start_); |
8779 | auto o = flatbuffers::Offset<MatrixDiagOptions>(end); |
8780 | return o; |
8781 | } |
8782 | }; |
8783 | |
8784 | inline flatbuffers::Offset<MatrixDiagOptions> CreateMatrixDiagOptions( |
8785 | flatbuffers::FlatBufferBuilder &_fbb) { |
8786 | MatrixDiagOptionsBuilder builder_(_fbb); |
8787 | return builder_.Finish(); |
8788 | } |
8789 | |
8790 | flatbuffers::Offset<MatrixDiagOptions> CreateMatrixDiagOptions(flatbuffers::FlatBufferBuilder &_fbb, const MatrixDiagOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8791 | |
8792 | struct QuantizeOptionsT : public flatbuffers::NativeTable { |
8793 | typedef QuantizeOptions TableType; |
8794 | QuantizeOptionsT() { |
8795 | } |
8796 | }; |
8797 | |
8798 | struct QuantizeOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8799 | typedef QuantizeOptionsT NativeTableType; |
8800 | bool Verify(flatbuffers::Verifier &verifier) const { |
8801 | return VerifyTableStart(verifier) && |
8802 | verifier.EndTable(); |
8803 | } |
8804 | QuantizeOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8805 | void UnPackTo(QuantizeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8806 | static flatbuffers::Offset<QuantizeOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const QuantizeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8807 | }; |
8808 | |
8809 | struct QuantizeOptionsBuilder { |
8810 | flatbuffers::FlatBufferBuilder &fbb_; |
8811 | flatbuffers::uoffset_t start_; |
8812 | explicit QuantizeOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8813 | : fbb_(_fbb) { |
8814 | start_ = fbb_.StartTable(); |
8815 | } |
8816 | QuantizeOptionsBuilder &operator=(const QuantizeOptionsBuilder &); |
8817 | flatbuffers::Offset<QuantizeOptions> Finish() { |
8818 | const auto end = fbb_.EndTable(start_); |
8819 | auto o = flatbuffers::Offset<QuantizeOptions>(end); |
8820 | return o; |
8821 | } |
8822 | }; |
8823 | |
8824 | inline flatbuffers::Offset<QuantizeOptions> CreateQuantizeOptions( |
8825 | flatbuffers::FlatBufferBuilder &_fbb) { |
8826 | QuantizeOptionsBuilder builder_(_fbb); |
8827 | return builder_.Finish(); |
8828 | } |
8829 | |
8830 | flatbuffers::Offset<QuantizeOptions> CreateQuantizeOptions(flatbuffers::FlatBufferBuilder &_fbb, const QuantizeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8831 | |
8832 | struct MatrixSetDiagOptionsT : public flatbuffers::NativeTable { |
8833 | typedef MatrixSetDiagOptions TableType; |
8834 | MatrixSetDiagOptionsT() { |
8835 | } |
8836 | }; |
8837 | |
8838 | struct MatrixSetDiagOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8839 | typedef MatrixSetDiagOptionsT NativeTableType; |
8840 | bool Verify(flatbuffers::Verifier &verifier) const { |
8841 | return VerifyTableStart(verifier) && |
8842 | verifier.EndTable(); |
8843 | } |
8844 | MatrixSetDiagOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8845 | void UnPackTo(MatrixSetDiagOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8846 | static flatbuffers::Offset<MatrixSetDiagOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const MatrixSetDiagOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8847 | }; |
8848 | |
8849 | struct MatrixSetDiagOptionsBuilder { |
8850 | flatbuffers::FlatBufferBuilder &fbb_; |
8851 | flatbuffers::uoffset_t start_; |
8852 | explicit MatrixSetDiagOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8853 | : fbb_(_fbb) { |
8854 | start_ = fbb_.StartTable(); |
8855 | } |
8856 | MatrixSetDiagOptionsBuilder &operator=(const MatrixSetDiagOptionsBuilder &); |
8857 | flatbuffers::Offset<MatrixSetDiagOptions> Finish() { |
8858 | const auto end = fbb_.EndTable(start_); |
8859 | auto o = flatbuffers::Offset<MatrixSetDiagOptions>(end); |
8860 | return o; |
8861 | } |
8862 | }; |
8863 | |
8864 | inline flatbuffers::Offset<MatrixSetDiagOptions> CreateMatrixSetDiagOptions( |
8865 | flatbuffers::FlatBufferBuilder &_fbb) { |
8866 | MatrixSetDiagOptionsBuilder builder_(_fbb); |
8867 | return builder_.Finish(); |
8868 | } |
8869 | |
8870 | flatbuffers::Offset<MatrixSetDiagOptions> CreateMatrixSetDiagOptions(flatbuffers::FlatBufferBuilder &_fbb, const MatrixSetDiagOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8871 | |
8872 | struct IfOptionsT : public flatbuffers::NativeTable { |
8873 | typedef IfOptions TableType; |
8874 | int32_t then_subgraph_index; |
8875 | int32_t else_subgraph_index; |
8876 | IfOptionsT() |
8877 | : then_subgraph_index(0), |
8878 | else_subgraph_index(0) { |
8879 | } |
8880 | }; |
8881 | |
8882 | struct IfOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8883 | typedef IfOptionsT NativeTableType; |
8884 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8885 | VT_THEN_SUBGRAPH_INDEX = 4, |
8886 | VT_ELSE_SUBGRAPH_INDEX = 6 |
8887 | }; |
8888 | int32_t then_subgraph_index() const { |
8889 | return GetField<int32_t>(VT_THEN_SUBGRAPH_INDEX, 0); |
8890 | } |
8891 | int32_t else_subgraph_index() const { |
8892 | return GetField<int32_t>(VT_ELSE_SUBGRAPH_INDEX, 0); |
8893 | } |
8894 | bool Verify(flatbuffers::Verifier &verifier) const { |
8895 | return VerifyTableStart(verifier) && |
8896 | VerifyField<int32_t>(verifier, VT_THEN_SUBGRAPH_INDEX) && |
8897 | VerifyField<int32_t>(verifier, VT_ELSE_SUBGRAPH_INDEX) && |
8898 | verifier.EndTable(); |
8899 | } |
8900 | IfOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8901 | void UnPackTo(IfOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8902 | static flatbuffers::Offset<IfOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const IfOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8903 | }; |
8904 | |
8905 | struct IfOptionsBuilder { |
8906 | flatbuffers::FlatBufferBuilder &fbb_; |
8907 | flatbuffers::uoffset_t start_; |
8908 | void add_then_subgraph_index(int32_t then_subgraph_index) { |
8909 | fbb_.AddElement<int32_t>(IfOptions::VT_THEN_SUBGRAPH_INDEX, then_subgraph_index, 0); |
8910 | } |
8911 | void add_else_subgraph_index(int32_t else_subgraph_index) { |
8912 | fbb_.AddElement<int32_t>(IfOptions::VT_ELSE_SUBGRAPH_INDEX, else_subgraph_index, 0); |
8913 | } |
8914 | explicit IfOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8915 | : fbb_(_fbb) { |
8916 | start_ = fbb_.StartTable(); |
8917 | } |
8918 | IfOptionsBuilder &operator=(const IfOptionsBuilder &); |
8919 | flatbuffers::Offset<IfOptions> Finish() { |
8920 | const auto end = fbb_.EndTable(start_); |
8921 | auto o = flatbuffers::Offset<IfOptions>(end); |
8922 | return o; |
8923 | } |
8924 | }; |
8925 | |
8926 | inline flatbuffers::Offset<IfOptions> CreateIfOptions( |
8927 | flatbuffers::FlatBufferBuilder &_fbb, |
8928 | int32_t then_subgraph_index = 0, |
8929 | int32_t else_subgraph_index = 0) { |
8930 | IfOptionsBuilder builder_(_fbb); |
8931 | builder_.add_else_subgraph_index(else_subgraph_index); |
8932 | builder_.add_then_subgraph_index(then_subgraph_index); |
8933 | return builder_.Finish(); |
8934 | } |
8935 | |
8936 | flatbuffers::Offset<IfOptions> CreateIfOptions(flatbuffers::FlatBufferBuilder &_fbb, const IfOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8937 | |
8938 | struct WhileOptionsT : public flatbuffers::NativeTable { |
8939 | typedef WhileOptions TableType; |
8940 | int32_t cond_subgraph_index; |
8941 | int32_t body_subgraph_index; |
8942 | WhileOptionsT() |
8943 | : cond_subgraph_index(0), |
8944 | body_subgraph_index(0) { |
8945 | } |
8946 | }; |
8947 | |
8948 | struct WhileOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
8949 | typedef WhileOptionsT NativeTableType; |
8950 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
8951 | VT_COND_SUBGRAPH_INDEX = 4, |
8952 | VT_BODY_SUBGRAPH_INDEX = 6 |
8953 | }; |
8954 | int32_t cond_subgraph_index() const { |
8955 | return GetField<int32_t>(VT_COND_SUBGRAPH_INDEX, 0); |
8956 | } |
8957 | int32_t body_subgraph_index() const { |
8958 | return GetField<int32_t>(VT_BODY_SUBGRAPH_INDEX, 0); |
8959 | } |
8960 | bool Verify(flatbuffers::Verifier &verifier) const { |
8961 | return VerifyTableStart(verifier) && |
8962 | VerifyField<int32_t>(verifier, VT_COND_SUBGRAPH_INDEX) && |
8963 | VerifyField<int32_t>(verifier, VT_BODY_SUBGRAPH_INDEX) && |
8964 | verifier.EndTable(); |
8965 | } |
8966 | WhileOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8967 | void UnPackTo(WhileOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
8968 | static flatbuffers::Offset<WhileOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const WhileOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
8969 | }; |
8970 | |
8971 | struct WhileOptionsBuilder { |
8972 | flatbuffers::FlatBufferBuilder &fbb_; |
8973 | flatbuffers::uoffset_t start_; |
8974 | void add_cond_subgraph_index(int32_t cond_subgraph_index) { |
8975 | fbb_.AddElement<int32_t>(WhileOptions::VT_COND_SUBGRAPH_INDEX, cond_subgraph_index, 0); |
8976 | } |
8977 | void add_body_subgraph_index(int32_t body_subgraph_index) { |
8978 | fbb_.AddElement<int32_t>(WhileOptions::VT_BODY_SUBGRAPH_INDEX, body_subgraph_index, 0); |
8979 | } |
8980 | explicit WhileOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
8981 | : fbb_(_fbb) { |
8982 | start_ = fbb_.StartTable(); |
8983 | } |
8984 | WhileOptionsBuilder &operator=(const WhileOptionsBuilder &); |
8985 | flatbuffers::Offset<WhileOptions> Finish() { |
8986 | const auto end = fbb_.EndTable(start_); |
8987 | auto o = flatbuffers::Offset<WhileOptions>(end); |
8988 | return o; |
8989 | } |
8990 | }; |
8991 | |
8992 | inline flatbuffers::Offset<WhileOptions> CreateWhileOptions( |
8993 | flatbuffers::FlatBufferBuilder &_fbb, |
8994 | int32_t cond_subgraph_index = 0, |
8995 | int32_t body_subgraph_index = 0) { |
8996 | WhileOptionsBuilder builder_(_fbb); |
8997 | builder_.add_body_subgraph_index(body_subgraph_index); |
8998 | builder_.add_cond_subgraph_index(cond_subgraph_index); |
8999 | return builder_.Finish(); |
9000 | } |
9001 | |
9002 | flatbuffers::Offset<WhileOptions> CreateWhileOptions(flatbuffers::FlatBufferBuilder &_fbb, const WhileOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9003 | |
9004 | struct NonMaxSuppressionV4OptionsT : public flatbuffers::NativeTable { |
9005 | typedef NonMaxSuppressionV4Options TableType; |
9006 | NonMaxSuppressionV4OptionsT() { |
9007 | } |
9008 | }; |
9009 | |
9010 | struct NonMaxSuppressionV4Options FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9011 | typedef NonMaxSuppressionV4OptionsT NativeTableType; |
9012 | bool Verify(flatbuffers::Verifier &verifier) const { |
9013 | return VerifyTableStart(verifier) && |
9014 | verifier.EndTable(); |
9015 | } |
9016 | NonMaxSuppressionV4OptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9017 | void UnPackTo(NonMaxSuppressionV4OptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9018 | static flatbuffers::Offset<NonMaxSuppressionV4Options> Pack(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV4OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9019 | }; |
9020 | |
9021 | struct NonMaxSuppressionV4OptionsBuilder { |
9022 | flatbuffers::FlatBufferBuilder &fbb_; |
9023 | flatbuffers::uoffset_t start_; |
9024 | explicit NonMaxSuppressionV4OptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9025 | : fbb_(_fbb) { |
9026 | start_ = fbb_.StartTable(); |
9027 | } |
9028 | NonMaxSuppressionV4OptionsBuilder &operator=(const NonMaxSuppressionV4OptionsBuilder &); |
9029 | flatbuffers::Offset<NonMaxSuppressionV4Options> Finish() { |
9030 | const auto end = fbb_.EndTable(start_); |
9031 | auto o = flatbuffers::Offset<NonMaxSuppressionV4Options>(end); |
9032 | return o; |
9033 | } |
9034 | }; |
9035 | |
9036 | inline flatbuffers::Offset<NonMaxSuppressionV4Options> CreateNonMaxSuppressionV4Options( |
9037 | flatbuffers::FlatBufferBuilder &_fbb) { |
9038 | NonMaxSuppressionV4OptionsBuilder builder_(_fbb); |
9039 | return builder_.Finish(); |
9040 | } |
9041 | |
9042 | flatbuffers::Offset<NonMaxSuppressionV4Options> CreateNonMaxSuppressionV4Options(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV4OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9043 | |
9044 | struct NonMaxSuppressionV5OptionsT : public flatbuffers::NativeTable { |
9045 | typedef NonMaxSuppressionV5Options TableType; |
9046 | NonMaxSuppressionV5OptionsT() { |
9047 | } |
9048 | }; |
9049 | |
9050 | struct NonMaxSuppressionV5Options FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9051 | typedef NonMaxSuppressionV5OptionsT NativeTableType; |
9052 | bool Verify(flatbuffers::Verifier &verifier) const { |
9053 | return VerifyTableStart(verifier) && |
9054 | verifier.EndTable(); |
9055 | } |
9056 | NonMaxSuppressionV5OptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9057 | void UnPackTo(NonMaxSuppressionV5OptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9058 | static flatbuffers::Offset<NonMaxSuppressionV5Options> Pack(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV5OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9059 | }; |
9060 | |
9061 | struct NonMaxSuppressionV5OptionsBuilder { |
9062 | flatbuffers::FlatBufferBuilder &fbb_; |
9063 | flatbuffers::uoffset_t start_; |
9064 | explicit NonMaxSuppressionV5OptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9065 | : fbb_(_fbb) { |
9066 | start_ = fbb_.StartTable(); |
9067 | } |
9068 | NonMaxSuppressionV5OptionsBuilder &operator=(const NonMaxSuppressionV5OptionsBuilder &); |
9069 | flatbuffers::Offset<NonMaxSuppressionV5Options> Finish() { |
9070 | const auto end = fbb_.EndTable(start_); |
9071 | auto o = flatbuffers::Offset<NonMaxSuppressionV5Options>(end); |
9072 | return o; |
9073 | } |
9074 | }; |
9075 | |
9076 | inline flatbuffers::Offset<NonMaxSuppressionV5Options> CreateNonMaxSuppressionV5Options( |
9077 | flatbuffers::FlatBufferBuilder &_fbb) { |
9078 | NonMaxSuppressionV5OptionsBuilder builder_(_fbb); |
9079 | return builder_.Finish(); |
9080 | } |
9081 | |
9082 | flatbuffers::Offset<NonMaxSuppressionV5Options> CreateNonMaxSuppressionV5Options(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV5OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9083 | |
9084 | struct ScatterNdOptionsT : public flatbuffers::NativeTable { |
9085 | typedef ScatterNdOptions TableType; |
9086 | ScatterNdOptionsT() { |
9087 | } |
9088 | }; |
9089 | |
9090 | struct ScatterNdOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9091 | typedef ScatterNdOptionsT NativeTableType; |
9092 | bool Verify(flatbuffers::Verifier &verifier) const { |
9093 | return VerifyTableStart(verifier) && |
9094 | verifier.EndTable(); |
9095 | } |
9096 | ScatterNdOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9097 | void UnPackTo(ScatterNdOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9098 | static flatbuffers::Offset<ScatterNdOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ScatterNdOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9099 | }; |
9100 | |
9101 | struct ScatterNdOptionsBuilder { |
9102 | flatbuffers::FlatBufferBuilder &fbb_; |
9103 | flatbuffers::uoffset_t start_; |
9104 | explicit ScatterNdOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9105 | : fbb_(_fbb) { |
9106 | start_ = fbb_.StartTable(); |
9107 | } |
9108 | ScatterNdOptionsBuilder &operator=(const ScatterNdOptionsBuilder &); |
9109 | flatbuffers::Offset<ScatterNdOptions> Finish() { |
9110 | const auto end = fbb_.EndTable(start_); |
9111 | auto o = flatbuffers::Offset<ScatterNdOptions>(end); |
9112 | return o; |
9113 | } |
9114 | }; |
9115 | |
9116 | inline flatbuffers::Offset<ScatterNdOptions> CreateScatterNdOptions( |
9117 | flatbuffers::FlatBufferBuilder &_fbb) { |
9118 | ScatterNdOptionsBuilder builder_(_fbb); |
9119 | return builder_.Finish(); |
9120 | } |
9121 | |
9122 | flatbuffers::Offset<ScatterNdOptions> CreateScatterNdOptions(flatbuffers::FlatBufferBuilder &_fbb, const ScatterNdOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9123 | |
9124 | struct SelectV2OptionsT : public flatbuffers::NativeTable { |
9125 | typedef SelectV2Options TableType; |
9126 | SelectV2OptionsT() { |
9127 | } |
9128 | }; |
9129 | |
9130 | struct SelectV2Options FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9131 | typedef SelectV2OptionsT NativeTableType; |
9132 | bool Verify(flatbuffers::Verifier &verifier) const { |
9133 | return VerifyTableStart(verifier) && |
9134 | verifier.EndTable(); |
9135 | } |
9136 | SelectV2OptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9137 | void UnPackTo(SelectV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9138 | static flatbuffers::Offset<SelectV2Options> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SelectV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9139 | }; |
9140 | |
9141 | struct SelectV2OptionsBuilder { |
9142 | flatbuffers::FlatBufferBuilder &fbb_; |
9143 | flatbuffers::uoffset_t start_; |
9144 | explicit SelectV2OptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9145 | : fbb_(_fbb) { |
9146 | start_ = fbb_.StartTable(); |
9147 | } |
9148 | SelectV2OptionsBuilder &operator=(const SelectV2OptionsBuilder &); |
9149 | flatbuffers::Offset<SelectV2Options> Finish() { |
9150 | const auto end = fbb_.EndTable(start_); |
9151 | auto o = flatbuffers::Offset<SelectV2Options>(end); |
9152 | return o; |
9153 | } |
9154 | }; |
9155 | |
9156 | inline flatbuffers::Offset<SelectV2Options> CreateSelectV2Options( |
9157 | flatbuffers::FlatBufferBuilder &_fbb) { |
9158 | SelectV2OptionsBuilder builder_(_fbb); |
9159 | return builder_.Finish(); |
9160 | } |
9161 | |
9162 | flatbuffers::Offset<SelectV2Options> CreateSelectV2Options(flatbuffers::FlatBufferBuilder &_fbb, const SelectV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9163 | |
9164 | struct DensifyOptionsT : public flatbuffers::NativeTable { |
9165 | typedef DensifyOptions TableType; |
9166 | DensifyOptionsT() { |
9167 | } |
9168 | }; |
9169 | |
9170 | struct DensifyOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9171 | typedef DensifyOptionsT NativeTableType; |
9172 | bool Verify(flatbuffers::Verifier &verifier) const { |
9173 | return VerifyTableStart(verifier) && |
9174 | verifier.EndTable(); |
9175 | } |
9176 | DensifyOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9177 | void UnPackTo(DensifyOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9178 | static flatbuffers::Offset<DensifyOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const DensifyOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9179 | }; |
9180 | |
9181 | struct DensifyOptionsBuilder { |
9182 | flatbuffers::FlatBufferBuilder &fbb_; |
9183 | flatbuffers::uoffset_t start_; |
9184 | explicit DensifyOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9185 | : fbb_(_fbb) { |
9186 | start_ = fbb_.StartTable(); |
9187 | } |
9188 | DensifyOptionsBuilder &operator=(const DensifyOptionsBuilder &); |
9189 | flatbuffers::Offset<DensifyOptions> Finish() { |
9190 | const auto end = fbb_.EndTable(start_); |
9191 | auto o = flatbuffers::Offset<DensifyOptions>(end); |
9192 | return o; |
9193 | } |
9194 | }; |
9195 | |
9196 | inline flatbuffers::Offset<DensifyOptions> CreateDensifyOptions( |
9197 | flatbuffers::FlatBufferBuilder &_fbb) { |
9198 | DensifyOptionsBuilder builder_(_fbb); |
9199 | return builder_.Finish(); |
9200 | } |
9201 | |
9202 | flatbuffers::Offset<DensifyOptions> CreateDensifyOptions(flatbuffers::FlatBufferBuilder &_fbb, const DensifyOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9203 | |
9204 | struct SegmentSumOptionsT : public flatbuffers::NativeTable { |
9205 | typedef SegmentSumOptions TableType; |
9206 | SegmentSumOptionsT() { |
9207 | } |
9208 | }; |
9209 | |
9210 | struct SegmentSumOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9211 | typedef SegmentSumOptionsT NativeTableType; |
9212 | bool Verify(flatbuffers::Verifier &verifier) const { |
9213 | return VerifyTableStart(verifier) && |
9214 | verifier.EndTable(); |
9215 | } |
9216 | SegmentSumOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9217 | void UnPackTo(SegmentSumOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9218 | static flatbuffers::Offset<SegmentSumOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SegmentSumOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9219 | }; |
9220 | |
9221 | struct SegmentSumOptionsBuilder { |
9222 | flatbuffers::FlatBufferBuilder &fbb_; |
9223 | flatbuffers::uoffset_t start_; |
9224 | explicit SegmentSumOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9225 | : fbb_(_fbb) { |
9226 | start_ = fbb_.StartTable(); |
9227 | } |
9228 | SegmentSumOptionsBuilder &operator=(const SegmentSumOptionsBuilder &); |
9229 | flatbuffers::Offset<SegmentSumOptions> Finish() { |
9230 | const auto end = fbb_.EndTable(start_); |
9231 | auto o = flatbuffers::Offset<SegmentSumOptions>(end); |
9232 | return o; |
9233 | } |
9234 | }; |
9235 | |
9236 | inline flatbuffers::Offset<SegmentSumOptions> CreateSegmentSumOptions( |
9237 | flatbuffers::FlatBufferBuilder &_fbb) { |
9238 | SegmentSumOptionsBuilder builder_(_fbb); |
9239 | return builder_.Finish(); |
9240 | } |
9241 | |
9242 | flatbuffers::Offset<SegmentSumOptions> CreateSegmentSumOptions(flatbuffers::FlatBufferBuilder &_fbb, const SegmentSumOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9243 | |
9244 | struct BatchMatMulOptionsT : public flatbuffers::NativeTable { |
9245 | typedef BatchMatMulOptions TableType; |
9246 | bool adj_x; |
9247 | bool adj_y; |
9248 | BatchMatMulOptionsT() |
9249 | : adj_x(false), |
9250 | adj_y(false) { |
9251 | } |
9252 | }; |
9253 | |
9254 | struct BatchMatMulOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9255 | typedef BatchMatMulOptionsT NativeTableType; |
9256 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
9257 | VT_ADJ_X = 4, |
9258 | VT_ADJ_Y = 6 |
9259 | }; |
9260 | bool adj_x() const { |
9261 | return GetField<uint8_t>(VT_ADJ_X, 0) != 0; |
9262 | } |
9263 | bool adj_y() const { |
9264 | return GetField<uint8_t>(VT_ADJ_Y, 0) != 0; |
9265 | } |
9266 | bool Verify(flatbuffers::Verifier &verifier) const { |
9267 | return VerifyTableStart(verifier) && |
9268 | VerifyField<uint8_t>(verifier, VT_ADJ_X) && |
9269 | VerifyField<uint8_t>(verifier, VT_ADJ_Y) && |
9270 | verifier.EndTable(); |
9271 | } |
9272 | BatchMatMulOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9273 | void UnPackTo(BatchMatMulOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9274 | static flatbuffers::Offset<BatchMatMulOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const BatchMatMulOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9275 | }; |
9276 | |
9277 | struct BatchMatMulOptionsBuilder { |
9278 | flatbuffers::FlatBufferBuilder &fbb_; |
9279 | flatbuffers::uoffset_t start_; |
9280 | void add_adj_x(bool adj_x) { |
9281 | fbb_.AddElement<uint8_t>(BatchMatMulOptions::VT_ADJ_X, static_cast<uint8_t>(adj_x), 0); |
9282 | } |
9283 | void add_adj_y(bool adj_y) { |
9284 | fbb_.AddElement<uint8_t>(BatchMatMulOptions::VT_ADJ_Y, static_cast<uint8_t>(adj_y), 0); |
9285 | } |
9286 | explicit BatchMatMulOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9287 | : fbb_(_fbb) { |
9288 | start_ = fbb_.StartTable(); |
9289 | } |
9290 | BatchMatMulOptionsBuilder &operator=(const BatchMatMulOptionsBuilder &); |
9291 | flatbuffers::Offset<BatchMatMulOptions> Finish() { |
9292 | const auto end = fbb_.EndTable(start_); |
9293 | auto o = flatbuffers::Offset<BatchMatMulOptions>(end); |
9294 | return o; |
9295 | } |
9296 | }; |
9297 | |
9298 | inline flatbuffers::Offset<BatchMatMulOptions> CreateBatchMatMulOptions( |
9299 | flatbuffers::FlatBufferBuilder &_fbb, |
9300 | bool adj_x = false, |
9301 | bool adj_y = false) { |
9302 | BatchMatMulOptionsBuilder builder_(_fbb); |
9303 | builder_.add_adj_y(adj_y); |
9304 | builder_.add_adj_x(adj_x); |
9305 | return builder_.Finish(); |
9306 | } |
9307 | |
9308 | flatbuffers::Offset<BatchMatMulOptions> CreateBatchMatMulOptions(flatbuffers::FlatBufferBuilder &_fbb, const BatchMatMulOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9309 | |
9310 | struct OperatorCodeT : public flatbuffers::NativeTable { |
9311 | typedef OperatorCode TableType; |
9312 | tflite::BuiltinOperator builtin_code; |
9313 | std::string custom_code; |
9314 | int32_t version; |
9315 | OperatorCodeT() |
9316 | : builtin_code(tflite::BuiltinOperator_ADD), |
9317 | version(1) { |
9318 | } |
9319 | }; |
9320 | |
9321 | struct OperatorCode FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9322 | typedef OperatorCodeT NativeTableType; |
9323 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
9324 | VT_BUILTIN_CODE = 4, |
9325 | VT_CUSTOM_CODE = 6, |
9326 | VT_VERSION = 8 |
9327 | }; |
9328 | tflite::BuiltinOperator builtin_code() const { |
9329 | return static_cast<tflite::BuiltinOperator>(GetField<int8_t>(VT_BUILTIN_CODE, 0)); |
9330 | } |
9331 | const flatbuffers::String *custom_code() const { |
9332 | return GetPointer<const flatbuffers::String *>(VT_CUSTOM_CODE); |
9333 | } |
9334 | int32_t version() const { |
9335 | return GetField<int32_t>(VT_VERSION, 1); |
9336 | } |
9337 | bool Verify(flatbuffers::Verifier &verifier) const { |
9338 | return VerifyTableStart(verifier) && |
9339 | VerifyField<int8_t>(verifier, VT_BUILTIN_CODE) && |
9340 | VerifyOffset(verifier, VT_CUSTOM_CODE) && |
9341 | verifier.VerifyString(custom_code()) && |
9342 | VerifyField<int32_t>(verifier, VT_VERSION) && |
9343 | verifier.EndTable(); |
9344 | } |
9345 | OperatorCodeT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9346 | void UnPackTo(OperatorCodeT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9347 | static flatbuffers::Offset<OperatorCode> Pack(flatbuffers::FlatBufferBuilder &_fbb, const OperatorCodeT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9348 | }; |
9349 | |
9350 | struct OperatorCodeBuilder { |
9351 | flatbuffers::FlatBufferBuilder &fbb_; |
9352 | flatbuffers::uoffset_t start_; |
9353 | void add_builtin_code(tflite::BuiltinOperator builtin_code) { |
9354 | fbb_.AddElement<int8_t>(OperatorCode::VT_BUILTIN_CODE, static_cast<int8_t>(builtin_code), 0); |
9355 | } |
9356 | void add_custom_code(flatbuffers::Offset<flatbuffers::String> custom_code) { |
9357 | fbb_.AddOffset(OperatorCode::VT_CUSTOM_CODE, custom_code); |
9358 | } |
9359 | void add_version(int32_t version) { |
9360 | fbb_.AddElement<int32_t>(OperatorCode::VT_VERSION, version, 1); |
9361 | } |
9362 | explicit OperatorCodeBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
9363 | : fbb_(_fbb) { |
9364 | start_ = fbb_.StartTable(); |
9365 | } |
9366 | OperatorCodeBuilder &operator=(const OperatorCodeBuilder &); |
9367 | flatbuffers::Offset<OperatorCode> Finish() { |
9368 | const auto end = fbb_.EndTable(start_); |
9369 | auto o = flatbuffers::Offset<OperatorCode>(end); |
9370 | return o; |
9371 | } |
9372 | }; |
9373 | |
9374 | inline flatbuffers::Offset<OperatorCode> CreateOperatorCode( |
9375 | flatbuffers::FlatBufferBuilder &_fbb, |
9376 | tflite::BuiltinOperator builtin_code = tflite::BuiltinOperator_ADD, |
9377 | flatbuffers::Offset<flatbuffers::String> custom_code = 0, |
9378 | int32_t version = 1) { |
9379 | OperatorCodeBuilder builder_(_fbb); |
9380 | builder_.add_version(version); |
9381 | builder_.add_custom_code(custom_code); |
9382 | builder_.add_builtin_code(builtin_code); |
9383 | return builder_.Finish(); |
9384 | } |
9385 | |
9386 | inline flatbuffers::Offset<OperatorCode> CreateOperatorCodeDirect( |
9387 | flatbuffers::FlatBufferBuilder &_fbb, |
9388 | tflite::BuiltinOperator builtin_code = tflite::BuiltinOperator_ADD, |
9389 | const char *custom_code = nullptr, |
9390 | int32_t version = 1) { |
9391 | auto custom_code__ = custom_code ? _fbb.CreateString(custom_code) : 0; |
9392 | return tflite::CreateOperatorCode( |
9393 | _fbb, |
9394 | builtin_code, |
9395 | custom_code__, |
9396 | version); |
9397 | } |
9398 | |
9399 | flatbuffers::Offset<OperatorCode> CreateOperatorCode(flatbuffers::FlatBufferBuilder &_fbb, const OperatorCodeT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9400 | |
9401 | struct OperatorT : public flatbuffers::NativeTable { |
9402 | typedef Operator TableType; |
9403 | uint32_t opcode_index; |
9404 | std::vector<int32_t> inputs; |
9405 | std::vector<int32_t> outputs; |
9406 | tflite::BuiltinOptionsUnion builtin_options; |
9407 | std::vector<uint8_t> custom_options; |
9408 | tflite::CustomOptionsFormat custom_options_format; |
9409 | std::vector<bool> mutating_variable_inputs; |
9410 | std::vector<int32_t> intermediates; |
9411 | OperatorT() |
9412 | : opcode_index(0), |
9413 | custom_options_format(tflite::CustomOptionsFormat_FLEXBUFFERS) { |
9414 | } |
9415 | }; |
9416 | |
9417 | struct Operator FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
9418 | typedef OperatorT NativeTableType; |
9419 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
9420 | VT_OPCODE_INDEX = 4, |
9421 | VT_INPUTS = 6, |
9422 | VT_OUTPUTS = 8, |
9423 | VT_BUILTIN_OPTIONS_TYPE = 10, |
9424 | VT_BUILTIN_OPTIONS = 12, |
9425 | VT_CUSTOM_OPTIONS = 14, |
9426 | VT_CUSTOM_OPTIONS_FORMAT = 16, |
9427 | VT_MUTATING_VARIABLE_INPUTS = 18, |
9428 | VT_INTERMEDIATES = 20 |
9429 | }; |
9430 | uint32_t opcode_index() const { |
9431 | return GetField<uint32_t>(VT_OPCODE_INDEX, 0); |
9432 | } |
9433 | const flatbuffers::Vector<int32_t> *inputs() const { |
9434 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_INPUTS); |
9435 | } |
9436 | const flatbuffers::Vector<int32_t> *outputs() const { |
9437 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_OUTPUTS); |
9438 | } |
9439 | tflite::BuiltinOptions builtin_options_type() const { |
9440 | return static_cast<tflite::BuiltinOptions>(GetField<uint8_t>(VT_BUILTIN_OPTIONS_TYPE, 0)); |
9441 | } |
9442 | const void *builtin_options() const { |
9443 | return GetPointer<const void *>(VT_BUILTIN_OPTIONS); |
9444 | } |
9445 | template<typename T> const T *builtin_options_as() const; |
9446 | const tflite::Conv2DOptions *builtin_options_as_Conv2DOptions() const { |
9447 | return builtin_options_type() == tflite::BuiltinOptions_Conv2DOptions ? static_cast<const tflite::Conv2DOptions *>(builtin_options()) : nullptr; |
9448 | } |
9449 | const tflite::DepthwiseConv2DOptions *builtin_options_as_DepthwiseConv2DOptions() const { |
9450 | return builtin_options_type() == tflite::BuiltinOptions_DepthwiseConv2DOptions ? static_cast<const tflite::DepthwiseConv2DOptions *>(builtin_options()) : nullptr; |
9451 | } |
9452 | const tflite::ConcatEmbeddingsOptions *builtin_options_as_ConcatEmbeddingsOptions() const { |
9453 | return builtin_options_type() == tflite::BuiltinOptions_ConcatEmbeddingsOptions ? static_cast<const tflite::ConcatEmbeddingsOptions *>(builtin_options()) : nullptr; |
9454 | } |
9455 | const tflite::LSHProjectionOptions *builtin_options_as_LSHProjectionOptions() const { |
9456 | return builtin_options_type() == tflite::BuiltinOptions_LSHProjectionOptions ? static_cast<const tflite::LSHProjectionOptions *>(builtin_options()) : nullptr; |
9457 | } |
9458 | const tflite::Pool2DOptions *builtin_options_as_Pool2DOptions() const { |
9459 | return builtin_options_type() == tflite::BuiltinOptions_Pool2DOptions ? static_cast<const tflite::Pool2DOptions *>(builtin_options()) : nullptr; |
9460 | } |
9461 | const tflite::SVDFOptions *builtin_options_as_SVDFOptions() const { |
9462 | return builtin_options_type() == tflite::BuiltinOptions_SVDFOptions ? static_cast<const tflite::SVDFOptions *>(builtin_options()) : nullptr; |
9463 | } |
9464 | const tflite::RNNOptions *builtin_options_as_RNNOptions() const { |
9465 | return builtin_options_type() == tflite::BuiltinOptions_RNNOptions ? static_cast<const tflite::RNNOptions *>(builtin_options()) : nullptr; |
9466 | } |
9467 | const tflite::FullyConnectedOptions *builtin_options_as_FullyConnectedOptions() const { |
9468 | return builtin_options_type() == tflite::BuiltinOptions_FullyConnectedOptions ? static_cast<const tflite::FullyConnectedOptions *>(builtin_options()) : nullptr; |
9469 | } |
9470 | const tflite::SoftmaxOptions *builtin_options_as_SoftmaxOptions() const { |
9471 | return builtin_options_type() == tflite::BuiltinOptions_SoftmaxOptions ? static_cast<const tflite::SoftmaxOptions *>(builtin_options()) : nullptr; |
9472 | } |
9473 | const tflite::ConcatenationOptions *builtin_options_as_ConcatenationOptions() const { |
9474 | return builtin_options_type() == tflite::BuiltinOptions_ConcatenationOptions ? static_cast<const tflite::ConcatenationOptions *>(builtin_options()) : nullptr; |
9475 | } |
9476 | const tflite::AddOptions *builtin_options_as_AddOptions() const { |
9477 | return builtin_options_type() == tflite::BuiltinOptions_AddOptions ? static_cast<const tflite::AddOptions *>(builtin_options()) : nullptr; |
9478 | } |
9479 | const tflite::L2NormOptions *builtin_options_as_L2NormOptions() const { |
9480 | return builtin_options_type() == tflite::BuiltinOptions_L2NormOptions ? static_cast<const tflite::L2NormOptions *>(builtin_options()) : nullptr; |
9481 | } |
9482 | const tflite::LocalResponseNormalizationOptions *builtin_options_as_LocalResponseNormalizationOptions() const { |
9483 | return builtin_options_type() == tflite::BuiltinOptions_LocalResponseNormalizationOptions ? static_cast<const tflite::LocalResponseNormalizationOptions *>(builtin_options()) : nullptr; |
9484 | } |
9485 | const tflite::LSTMOptions *builtin_options_as_LSTMOptions() const { |
9486 | return builtin_options_type() == tflite::BuiltinOptions_LSTMOptions ? static_cast<const tflite::LSTMOptions *>(builtin_options()) : nullptr; |
9487 | } |
9488 | const tflite::ResizeBilinearOptions *builtin_options_as_ResizeBilinearOptions() const { |
9489 | return builtin_options_type() == tflite::BuiltinOptions_ResizeBilinearOptions ? static_cast<const tflite::ResizeBilinearOptions *>(builtin_options()) : nullptr; |
9490 | } |
9491 | const tflite::CallOptions *builtin_options_as_CallOptions() const { |
9492 | return builtin_options_type() == tflite::BuiltinOptions_CallOptions ? static_cast<const tflite::CallOptions *>(builtin_options()) : nullptr; |
9493 | } |
9494 | const tflite::ReshapeOptions *builtin_options_as_ReshapeOptions() const { |
9495 | return builtin_options_type() == tflite::BuiltinOptions_ReshapeOptions ? static_cast<const tflite::ReshapeOptions *>(builtin_options()) : nullptr; |
9496 | } |
9497 | const tflite::SkipGramOptions *builtin_options_as_SkipGramOptions() const { |
9498 | return builtin_options_type() == tflite::BuiltinOptions_SkipGramOptions ? static_cast<const tflite::SkipGramOptions *>(builtin_options()) : nullptr; |
9499 | } |
9500 | const tflite::SpaceToDepthOptions *builtin_options_as_SpaceToDepthOptions() const { |
9501 | return builtin_options_type() == tflite::BuiltinOptions_SpaceToDepthOptions ? static_cast<const tflite::SpaceToDepthOptions *>(builtin_options()) : nullptr; |
9502 | } |
9503 | const tflite::EmbeddingLookupSparseOptions *builtin_options_as_EmbeddingLookupSparseOptions() const { |
9504 | return builtin_options_type() == tflite::BuiltinOptions_EmbeddingLookupSparseOptions ? static_cast<const tflite::EmbeddingLookupSparseOptions *>(builtin_options()) : nullptr; |
9505 | } |
9506 | const tflite::MulOptions *builtin_options_as_MulOptions() const { |
9507 | return builtin_options_type() == tflite::BuiltinOptions_MulOptions ? static_cast<const tflite::MulOptions *>(builtin_options()) : nullptr; |
9508 | } |
9509 | const tflite::PadOptions *builtin_options_as_PadOptions() const { |
9510 | return builtin_options_type() == tflite::BuiltinOptions_PadOptions ? static_cast<const tflite::PadOptions *>(builtin_options()) : nullptr; |
9511 | } |
9512 | const tflite::GatherOptions *builtin_options_as_GatherOptions() const { |
9513 | return builtin_options_type() == tflite::BuiltinOptions_GatherOptions ? static_cast<const tflite::GatherOptions *>(builtin_options()) : nullptr; |
9514 | } |
9515 | const tflite::BatchToSpaceNDOptions *builtin_options_as_BatchToSpaceNDOptions() const { |
9516 | return builtin_options_type() == tflite::BuiltinOptions_BatchToSpaceNDOptions ? static_cast<const tflite::BatchToSpaceNDOptions *>(builtin_options()) : nullptr; |
9517 | } |
9518 | const tflite::SpaceToBatchNDOptions *builtin_options_as_SpaceToBatchNDOptions() const { |
9519 | return builtin_options_type() == tflite::BuiltinOptions_SpaceToBatchNDOptions ? static_cast<const tflite::SpaceToBatchNDOptions *>(builtin_options()) : nullptr; |
9520 | } |
9521 | const tflite::TransposeOptions *builtin_options_as_TransposeOptions() const { |
9522 | return builtin_options_type() == tflite::BuiltinOptions_TransposeOptions ? static_cast<const tflite::TransposeOptions *>(builtin_options()) : nullptr; |
9523 | } |
9524 | const tflite::ReducerOptions *builtin_options_as_ReducerOptions() const { |
9525 | return builtin_options_type() == tflite::BuiltinOptions_ReducerOptions ? static_cast<const tflite::ReducerOptions *>(builtin_options()) : nullptr; |
9526 | } |
9527 | const tflite::SubOptions *builtin_options_as_SubOptions() const { |
9528 | return builtin_options_type() == tflite::BuiltinOptions_SubOptions ? static_cast<const tflite::SubOptions *>(builtin_options()) : nullptr; |
9529 | } |
9530 | const tflite::DivOptions *builtin_options_as_DivOptions() const { |
9531 | return builtin_options_type() == tflite::BuiltinOptions_DivOptions ? static_cast<const tflite::DivOptions *>(builtin_options()) : nullptr; |
9532 | } |
9533 | const tflite::SqueezeOptions *builtin_options_as_SqueezeOptions() const { |
9534 | return builtin_options_type() == tflite::BuiltinOptions_SqueezeOptions ? static_cast<const tflite::SqueezeOptions *>(builtin_options()) : nullptr; |
9535 | } |
9536 | const tflite::SequenceRNNOptions *builtin_options_as_SequenceRNNOptions() const { |
9537 | return builtin_options_type() == tflite::BuiltinOptions_SequenceRNNOptions ? static_cast<const tflite::SequenceRNNOptions *>(builtin_options()) : nullptr; |
9538 | } |
9539 | const tflite::StridedSliceOptions *builtin_options_as_StridedSliceOptions() const { |
9540 | return builtin_options_type() == tflite::BuiltinOptions_StridedSliceOptions ? static_cast<const tflite::StridedSliceOptions *>(builtin_options()) : nullptr; |
9541 | } |
9542 | const tflite::ExpOptions *builtin_options_as_ExpOptions() const { |
9543 | return builtin_options_type() == tflite::BuiltinOptions_ExpOptions ? static_cast<const tflite::ExpOptions *>(builtin_options()) : nullptr; |
9544 | } |
9545 | const tflite::TopKV2Options *builtin_options_as_TopKV2Options() const { |
9546 | return builtin_options_type() == tflite::BuiltinOptions_TopKV2Options ? static_cast<const tflite::TopKV2Options *>(builtin_options()) : nullptr; |
9547 | } |
9548 | const tflite::SplitOptions *builtin_options_as_SplitOptions() const { |
9549 | return builtin_options_type() == tflite::BuiltinOptions_SplitOptions ? static_cast<const tflite::SplitOptions *>(builtin_options()) : nullptr; |
9550 | } |
9551 | const tflite::LogSoftmaxOptions *builtin_options_as_LogSoftmaxOptions() const { |
9552 | return builtin_options_type() == tflite::BuiltinOptions_LogSoftmaxOptions ? static_cast<const tflite::LogSoftmaxOptions *>(builtin_options()) : nullptr; |
9553 | } |
9554 | const tflite::CastOptions *builtin_options_as_CastOptions() const { |
9555 | return builtin_options_type() == tflite::BuiltinOptions_CastOptions ? static_cast<const tflite::CastOptions *>(builtin_options()) : nullptr; |
9556 | } |
9557 | const tflite::DequantizeOptions *builtin_options_as_DequantizeOptions() const { |
9558 | return builtin_options_type() == tflite::BuiltinOptions_DequantizeOptions ? static_cast<const tflite::DequantizeOptions *>(builtin_options()) : nullptr; |
9559 | } |
9560 | const tflite::MaximumMinimumOptions *builtin_options_as_MaximumMinimumOptions() const { |
9561 | return builtin_options_type() == tflite::BuiltinOptions_MaximumMinimumOptions ? static_cast<const tflite::MaximumMinimumOptions *>(builtin_options()) : nullptr; |
9562 | } |
9563 | const tflite::ArgMaxOptions *builtin_options_as_ArgMaxOptions() const { |
9564 | return builtin_options_type() == tflite::BuiltinOptions_ArgMaxOptions ? static_cast<const tflite::ArgMaxOptions *>(builtin_options()) : nullptr; |
9565 | } |
9566 | const tflite::LessOptions *builtin_options_as_LessOptions() const { |
9567 | return builtin_options_type() == tflite::BuiltinOptions_LessOptions ? static_cast<const tflite::LessOptions *>(builtin_options()) : nullptr; |
9568 | } |
9569 | const tflite::NegOptions *builtin_options_as_NegOptions() const { |
9570 | return builtin_options_type() == tflite::BuiltinOptions_NegOptions ? static_cast<const tflite::NegOptions *>(builtin_options()) : nullptr; |
9571 | } |
9572 | const tflite::PadV2Options *builtin_options_as_PadV2Options() const { |
9573 | return builtin_options_type() == tflite::BuiltinOptions_PadV2Options ? static_cast<const tflite::PadV2Options *>(builtin_options()) : nullptr; |
9574 | } |
9575 | const tflite::GreaterOptions *builtin_options_as_GreaterOptions() const { |
9576 | return builtin_options_type() == tflite::BuiltinOptions_GreaterOptions ? static_cast<const tflite::GreaterOptions *>(builtin_options()) : nullptr; |
9577 | } |
9578 | const tflite::GreaterEqualOptions *builtin_options_as_GreaterEqualOptions() const { |
9579 | return builtin_options_type() == tflite::BuiltinOptions_GreaterEqualOptions ? static_cast<const tflite::GreaterEqualOptions *>(builtin_options()) : nullptr; |
9580 | } |
9581 | const tflite::LessEqualOptions *builtin_options_as_LessEqualOptions() const { |
9582 | return builtin_options_type() == tflite::BuiltinOptions_LessEqualOptions ? static_cast<const tflite::LessEqualOptions *>(builtin_options()) : nullptr; |
9583 | } |
9584 | const tflite::SelectOptions *builtin_options_as_SelectOptions() const { |
9585 | return builtin_options_type() == tflite::BuiltinOptions_SelectOptions ? static_cast<const tflite::SelectOptions *>(builtin_options()) : nullptr; |
9586 | } |
9587 | const tflite::SliceOptions *builtin_options_as_SliceOptions() const { |
9588 | return builtin_options_type() == tflite::BuiltinOptions_SliceOptions ? static_cast<const tflite::SliceOptions *>(builtin_options()) : nullptr; |
9589 | } |
9590 | const tflite::TransposeConvOptions *builtin_options_as_TransposeConvOptions() const { |
9591 | return builtin_options_type() == tflite::BuiltinOptions_TransposeConvOptions ? static_cast<const tflite::TransposeConvOptions *>(builtin_options()) : nullptr; |
9592 | } |
9593 | const tflite::SparseToDenseOptions *builtin_options_as_SparseToDenseOptions() const { |
9594 | return builtin_options_type() == tflite::BuiltinOptions_SparseToDenseOptions ? static_cast<const tflite::SparseToDenseOptions *>(builtin_options()) : nullptr; |
9595 | } |
9596 | const tflite::TileOptions *builtin_options_as_TileOptions() const { |
9597 | return builtin_options_type() == tflite::BuiltinOptions_TileOptions ? static_cast<const tflite::TileOptions *>(builtin_options()) : nullptr; |
9598 | } |
9599 | const tflite::ExpandDimsOptions *builtin_options_as_ExpandDimsOptions() const { |
9600 | return builtin_options_type() == tflite::BuiltinOptions_ExpandDimsOptions ? static_cast<const tflite::ExpandDimsOptions *>(builtin_options()) : nullptr; |
9601 | } |
9602 | const tflite::EqualOptions *builtin_options_as_EqualOptions() const { |
9603 | return builtin_options_type() == tflite::BuiltinOptions_EqualOptions ? static_cast<const tflite::EqualOptions *>(builtin_options()) : nullptr; |
9604 | } |
9605 | const tflite::NotEqualOptions *builtin_options_as_NotEqualOptions() const { |
9606 | return builtin_options_type() == tflite::BuiltinOptions_NotEqualOptions ? static_cast<const tflite::NotEqualOptions *>(builtin_options()) : nullptr; |
9607 | } |
9608 | const tflite::ShapeOptions *builtin_options_as_ShapeOptions() const { |
9609 | return builtin_options_type() == tflite::BuiltinOptions_ShapeOptions ? static_cast<const tflite::ShapeOptions *>(builtin_options()) : nullptr; |
9610 | } |
9611 | const tflite::PowOptions *builtin_options_as_PowOptions() const { |
9612 | return builtin_options_type() == tflite::BuiltinOptions_PowOptions ? static_cast<const tflite::PowOptions *>(builtin_options()) : nullptr; |
9613 | } |
9614 | const tflite::ArgMinOptions *builtin_options_as_ArgMinOptions() const { |
9615 | return builtin_options_type() == tflite::BuiltinOptions_ArgMinOptions ? static_cast<const tflite::ArgMinOptions *>(builtin_options()) : nullptr; |
9616 | } |
9617 | const tflite::FakeQuantOptions *builtin_options_as_FakeQuantOptions() const { |
9618 | return builtin_options_type() == tflite::BuiltinOptions_FakeQuantOptions ? static_cast<const tflite::FakeQuantOptions *>(builtin_options()) : nullptr; |
9619 | } |
9620 | const tflite::PackOptions *builtin_options_as_PackOptions() const { |
9621 | return builtin_options_type() == tflite::BuiltinOptions_PackOptions ? static_cast<const tflite::PackOptions *>(builtin_options()) : nullptr; |
9622 | } |
9623 | const tflite::LogicalOrOptions *builtin_options_as_LogicalOrOptions() const { |
9624 | return builtin_options_type() == tflite::BuiltinOptions_LogicalOrOptions ? static_cast<const tflite::LogicalOrOptions *>(builtin_options()) : nullptr; |
9625 | } |
9626 | const tflite::OneHotOptions *builtin_options_as_OneHotOptions() const { |
9627 | return builtin_options_type() == tflite::BuiltinOptions_OneHotOptions ? static_cast<const tflite::OneHotOptions *>(builtin_options()) : nullptr; |
9628 | } |
9629 | const tflite::LogicalAndOptions *builtin_options_as_LogicalAndOptions() const { |
9630 | return builtin_options_type() == tflite::BuiltinOptions_LogicalAndOptions ? static_cast<const tflite::LogicalAndOptions *>(builtin_options()) : nullptr; |
9631 | } |
9632 | const tflite::LogicalNotOptions *builtin_options_as_LogicalNotOptions() const { |
9633 | return builtin_options_type() == tflite::BuiltinOptions_LogicalNotOptions ? static_cast<const tflite::LogicalNotOptions *>(builtin_options()) : nullptr; |
9634 | } |
9635 | const tflite::UnpackOptions *builtin_options_as_UnpackOptions() const { |
9636 | return builtin_options_type() == tflite::BuiltinOptions_UnpackOptions ? static_cast<const tflite::UnpackOptions *>(builtin_options()) : nullptr; |
9637 | } |
9638 | const tflite::FloorDivOptions *builtin_options_as_FloorDivOptions() const { |
9639 | return builtin_options_type() == tflite::BuiltinOptions_FloorDivOptions ? static_cast<const tflite::FloorDivOptions *>(builtin_options()) : nullptr; |
9640 | } |
9641 | const tflite::SquareOptions *builtin_options_as_SquareOptions() const { |
9642 | return builtin_options_type() == tflite::BuiltinOptions_SquareOptions ? static_cast<const tflite::SquareOptions *>(builtin_options()) : nullptr; |
9643 | } |
9644 | const tflite::ZerosLikeOptions *builtin_options_as_ZerosLikeOptions() const { |
9645 | return builtin_options_type() == tflite::BuiltinOptions_ZerosLikeOptions ? static_cast<const tflite::ZerosLikeOptions *>(builtin_options()) : nullptr; |
9646 | } |
9647 | const tflite::FillOptions *builtin_options_as_FillOptions() const { |
9648 | return builtin_options_type() == tflite::BuiltinOptions_FillOptions ? static_cast<const tflite::FillOptions *>(builtin_options()) : nullptr; |
9649 | } |
9650 | const tflite::BidirectionalSequenceLSTMOptions *builtin_options_as_BidirectionalSequenceLSTMOptions() const { |
9651 | return builtin_options_type() == tflite::BuiltinOptions_BidirectionalSequenceLSTMOptions ? static_cast<const tflite::BidirectionalSequenceLSTMOptions *>(builtin_options()) : nullptr; |
9652 | } |
9653 | const tflite::BidirectionalSequenceRNNOptions *builtin_options_as_BidirectionalSequenceRNNOptions() const { |
9654 | return builtin_options_type() == tflite::BuiltinOptions_BidirectionalSequenceRNNOptions ? static_cast<const tflite::BidirectionalSequenceRNNOptions *>(builtin_options()) : nullptr; |
9655 | } |
9656 | const tflite::UnidirectionalSequenceLSTMOptions *builtin_options_as_UnidirectionalSequenceLSTMOptions() const { |
9657 | return builtin_options_type() == tflite::BuiltinOptions_UnidirectionalSequenceLSTMOptions ? static_cast<const tflite::UnidirectionalSequenceLSTMOptions *>(builtin_options()) : nullptr; |
9658 | } |
9659 | const tflite::FloorModOptions *builtin_options_as_FloorModOptions() const { |
9660 | return builtin_options_type() == tflite::BuiltinOptions_FloorModOptions ? static_cast<const tflite::FloorModOptions *>(builtin_options()) : nullptr; |
9661 | } |
9662 | const tflite::RangeOptions *builtin_options_as_RangeOptions() const { |
9663 | return builtin_options_type() == tflite::BuiltinOptions_RangeOptions ? static_cast<const tflite::RangeOptions *>(builtin_options()) : nullptr; |
9664 | } |
9665 | const tflite::ResizeNearestNeighborOptions *builtin_options_as_ResizeNearestNeighborOptions() const { |
9666 | return builtin_options_type() == tflite::BuiltinOptions_ResizeNearestNeighborOptions ? static_cast<const tflite::ResizeNearestNeighborOptions *>(builtin_options()) : nullptr; |
9667 | } |
9668 | const tflite::LeakyReluOptions *builtin_options_as_LeakyReluOptions() const { |
9669 | return builtin_options_type() == tflite::BuiltinOptions_LeakyReluOptions ? static_cast<const tflite::LeakyReluOptions *>(builtin_options()) : nullptr; |
9670 | } |
9671 | const tflite::SquaredDifferenceOptions *builtin_options_as_SquaredDifferenceOptions() const { |
9672 | return builtin_options_type() == tflite::BuiltinOptions_SquaredDifferenceOptions ? static_cast<const tflite::SquaredDifferenceOptions *>(builtin_options()) : nullptr; |
9673 | } |
9674 | const tflite::MirrorPadOptions *builtin_options_as_MirrorPadOptions() const { |
9675 | return builtin_options_type() == tflite::BuiltinOptions_MirrorPadOptions ? static_cast<const tflite::MirrorPadOptions *>(builtin_options()) : nullptr; |
9676 | } |
9677 | const tflite::AbsOptions *builtin_options_as_AbsOptions() const { |
9678 | return builtin_options_type() == tflite::BuiltinOptions_AbsOptions ? static_cast<const tflite::AbsOptions *>(builtin_options()) : nullptr; |
9679 | } |
9680 | const tflite::SplitVOptions *builtin_options_as_SplitVOptions() const { |
9681 | return builtin_options_type() == tflite::BuiltinOptions_SplitVOptions ? static_cast<const tflite::SplitVOptions *>(builtin_options()) : nullptr; |
9682 | } |
9683 | const tflite::UniqueOptions *builtin_options_as_UniqueOptions() const { |
9684 | return builtin_options_type() == tflite::BuiltinOptions_UniqueOptions ? static_cast<const tflite::UniqueOptions *>(builtin_options()) : nullptr; |
9685 | } |
9686 | const tflite::ReverseV2Options *builtin_options_as_ReverseV2Options() const { |
9687 | return builtin_options_type() == tflite::BuiltinOptions_ReverseV2Options ? static_cast<const tflite::ReverseV2Options *>(builtin_options()) : nullptr; |
9688 | } |
9689 | const tflite::AddNOptions *builtin_options_as_AddNOptions() const { |
9690 | return builtin_options_type() == tflite::BuiltinOptions_AddNOptions ? static_cast<const tflite::AddNOptions *>(builtin_options()) : nullptr; |
9691 | } |
9692 | const tflite::GatherNdOptions *builtin_options_as_GatherNdOptions() const { |
9693 | return builtin_options_type() == tflite::BuiltinOptions_GatherNdOptions ? static_cast<const tflite::GatherNdOptions *>(builtin_options()) : nullptr; |
9694 | } |
9695 | const tflite::CosOptions *builtin_options_as_CosOptions() const { |
9696 | return builtin_options_type() == tflite::BuiltinOptions_CosOptions ? static_cast<const tflite::CosOptions *>(builtin_options()) : nullptr; |
9697 | } |
9698 | const tflite::WhereOptions *builtin_options_as_WhereOptions() const { |
9699 | return builtin_options_type() == tflite::BuiltinOptions_WhereOptions ? static_cast<const tflite::WhereOptions *>(builtin_options()) : nullptr; |
9700 | } |
9701 | const tflite::RankOptions *builtin_options_as_RankOptions() const { |
9702 | return builtin_options_type() == tflite::BuiltinOptions_RankOptions ? static_cast<const tflite::RankOptions *>(builtin_options()) : nullptr; |
9703 | } |
9704 | const tflite::ReverseSequenceOptions *builtin_options_as_ReverseSequenceOptions() const { |
9705 | return builtin_options_type() == tflite::BuiltinOptions_ReverseSequenceOptions ? static_cast<const tflite::ReverseSequenceOptions *>(builtin_options()) : nullptr; |
9706 | } |
9707 | const tflite::MatrixDiagOptions *builtin_options_as_MatrixDiagOptions() const { |
9708 | return builtin_options_type() == tflite::BuiltinOptions_MatrixDiagOptions ? static_cast<const tflite::MatrixDiagOptions *>(builtin_options()) : nullptr; |
9709 | } |
9710 | const tflite::QuantizeOptions *builtin_options_as_QuantizeOptions() const { |
9711 | return builtin_options_type() == tflite::BuiltinOptions_QuantizeOptions ? static_cast<const tflite::QuantizeOptions *>(builtin_options()) : nullptr; |
9712 | } |
9713 | const tflite::MatrixSetDiagOptions *builtin_options_as_MatrixSetDiagOptions() const { |
9714 | return builtin_options_type() == tflite::BuiltinOptions_MatrixSetDiagOptions ? static_cast<const tflite::MatrixSetDiagOptions *>(builtin_options()) : nullptr; |
9715 | } |
9716 | const tflite::HardSwishOptions *builtin_options_as_HardSwishOptions() const { |
9717 | return builtin_options_type() == tflite::BuiltinOptions_HardSwishOptions ? static_cast<const tflite::HardSwishOptions *>(builtin_options()) : nullptr; |
9718 | } |
9719 | const tflite::IfOptions *builtin_options_as_IfOptions() const { |
9720 | return builtin_options_type() == tflite::BuiltinOptions_IfOptions ? static_cast<const tflite::IfOptions *>(builtin_options()) : nullptr; |
9721 | } |
9722 | const tflite::WhileOptions *builtin_options_as_WhileOptions() const { |
9723 | return builtin_options_type() == tflite::BuiltinOptions_WhileOptions ? static_cast<const tflite::WhileOptions *>(builtin_options()) : nullptr; |
9724 | } |
9725 | const tflite::DepthToSpaceOptions *builtin_options_as_DepthToSpaceOptions() const { |
9726 | return builtin_options_type() == tflite::BuiltinOptions_DepthToSpaceOptions ? static_cast<const tflite::DepthToSpaceOptions *>(builtin_options()) : nullptr; |
9727 | } |
9728 | const tflite::NonMaxSuppressionV4Options *builtin_options_as_NonMaxSuppressionV4Options() const { |
9729 | return builtin_options_type() == tflite::BuiltinOptions_NonMaxSuppressionV4Options ? static_cast<const tflite::NonMaxSuppressionV4Options *>(builtin_options()) : nullptr; |
9730 | } |
9731 | const tflite::NonMaxSuppressionV5Options *builtin_options_as_NonMaxSuppressionV5Options() const { |
9732 | return builtin_options_type() == tflite::BuiltinOptions_NonMaxSuppressionV5Options ? static_cast<const tflite::NonMaxSuppressionV5Options *>(builtin_options()) : nullptr; |
9733 | } |
9734 | const tflite::ScatterNdOptions *builtin_options_as_ScatterNdOptions() const { |
9735 | return builtin_options_type() == tflite::BuiltinOptions_ScatterNdOptions ? static_cast<const tflite::ScatterNdOptions *>(builtin_options()) : nullptr; |
9736 | } |
9737 | const tflite::SelectV2Options *builtin_options_as_SelectV2Options() const { |
9738 | return builtin_options_type() == tflite::BuiltinOptions_SelectV2Options ? static_cast<const tflite::SelectV2Options *>(builtin_options()) : nullptr; |
9739 | } |
9740 | const tflite::DensifyOptions *builtin_options_as_DensifyOptions() const { |
9741 | return builtin_options_type() == tflite::BuiltinOptions_DensifyOptions ? static_cast<const tflite::DensifyOptions *>(builtin_options()) : nullptr; |
9742 | } |
9743 | const tflite::SegmentSumOptions *builtin_options_as_SegmentSumOptions() const { |
9744 | return builtin_options_type() == tflite::BuiltinOptions_SegmentSumOptions ? static_cast<const tflite::SegmentSumOptions *>(builtin_options()) : nullptr; |
9745 | } |
9746 | const tflite::BatchMatMulOptions *builtin_options_as_BatchMatMulOptions() const { |
9747 | return builtin_options_type() == tflite::BuiltinOptions_BatchMatMulOptions ? static_cast<const tflite::BatchMatMulOptions *>(builtin_options()) : nullptr; |
9748 | } |
9749 | const flatbuffers::Vector<uint8_t> *custom_options() const { |
9750 | return GetPointer<const flatbuffers::Vector<uint8_t> *>(VT_CUSTOM_OPTIONS); |
9751 | } |
9752 | tflite::CustomOptionsFormat custom_options_format() const { |
9753 | return static_cast<tflite::CustomOptionsFormat>(GetField<int8_t>(VT_CUSTOM_OPTIONS_FORMAT, 0)); |
9754 | } |
9755 | const flatbuffers::Vector<uint8_t> *mutating_variable_inputs() const { |
9756 | return GetPointer<const flatbuffers::Vector<uint8_t> *>(VT_MUTATING_VARIABLE_INPUTS); |
9757 | } |
9758 | const flatbuffers::Vector<int32_t> *intermediates() const { |
9759 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_INTERMEDIATES); |
9760 | } |
9761 | bool Verify(flatbuffers::Verifier &verifier) const { |
9762 | return VerifyTableStart(verifier) && |
9763 | VerifyField<uint32_t>(verifier, VT_OPCODE_INDEX) && |
9764 | VerifyOffset(verifier, VT_INPUTS) && |
9765 | verifier.VerifyVector(inputs()) && |
9766 | VerifyOffset(verifier, VT_OUTPUTS) && |
9767 | verifier.VerifyVector(outputs()) && |
9768 | VerifyField<uint8_t>(verifier, VT_BUILTIN_OPTIONS_TYPE) && |
9769 | VerifyOffset(verifier, VT_BUILTIN_OPTIONS) && |
9770 | VerifyBuiltinOptions(verifier, builtin_options(), builtin_options_type()) && |
9771 | VerifyOffset(verifier, VT_CUSTOM_OPTIONS) && |
9772 | verifier.VerifyVector(custom_options()) && |
9773 | VerifyField<int8_t>(verifier, VT_CUSTOM_OPTIONS_FORMAT) && |
9774 | VerifyOffset(verifier, VT_MUTATING_VARIABLE_INPUTS) && |
9775 | verifier.VerifyVector(mutating_variable_inputs()) && |
9776 | VerifyOffset(verifier, VT_INTERMEDIATES) && |
9777 | verifier.VerifyVector(intermediates()) && |
9778 | verifier.EndTable(); |
9779 | } |
9780 | OperatorT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9781 | void UnPackTo(OperatorT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
9782 | static flatbuffers::Offset<Operator> Pack(flatbuffers::FlatBufferBuilder &_fbb, const OperatorT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
9783 | }; |
9784 | |
9785 | template<> inline const tflite::Conv2DOptions *Operator::builtin_options_as<tflite::Conv2DOptions>() const { |
9786 | return builtin_options_as_Conv2DOptions(); |
9787 | } |
9788 | |
9789 | template<> inline const tflite::DepthwiseConv2DOptions *Operator::builtin_options_as<tflite::DepthwiseConv2DOptions>() const { |
9790 | return builtin_options_as_DepthwiseConv2DOptions(); |
9791 | } |
9792 | |
9793 | template<> inline const tflite::ConcatEmbeddingsOptions *Operator::builtin_options_as<tflite::ConcatEmbeddingsOptions>() const { |
9794 | return builtin_options_as_ConcatEmbeddingsOptions(); |
9795 | } |
9796 | |
9797 | template<> inline const tflite::LSHProjectionOptions *Operator::builtin_options_as<tflite::LSHProjectionOptions>() const { |
9798 | return builtin_options_as_LSHProjectionOptions(); |
9799 | } |
9800 | |
9801 | template<> inline const tflite::Pool2DOptions *Operator::builtin_options_as<tflite::Pool2DOptions>() const { |
9802 | return builtin_options_as_Pool2DOptions(); |
9803 | } |
9804 | |
9805 | template<> inline const tflite::SVDFOptions *Operator::builtin_options_as<tflite::SVDFOptions>() const { |
9806 | return builtin_options_as_SVDFOptions(); |
9807 | } |
9808 | |
9809 | template<> inline const tflite::RNNOptions *Operator::builtin_options_as<tflite::RNNOptions>() const { |
9810 | return builtin_options_as_RNNOptions(); |
9811 | } |
9812 | |
9813 | template<> inline const tflite::FullyConnectedOptions *Operator::builtin_options_as<tflite::FullyConnectedOptions>() const { |
9814 | return builtin_options_as_FullyConnectedOptions(); |
9815 | } |
9816 | |
9817 | template<> inline const tflite::SoftmaxOptions *Operator::builtin_options_as<tflite::SoftmaxOptions>() const { |
9818 | return builtin_options_as_SoftmaxOptions(); |
9819 | } |
9820 | |
9821 | template<> inline const tflite::ConcatenationOptions *Operator::builtin_options_as<tflite::ConcatenationOptions>() const { |
9822 | return builtin_options_as_ConcatenationOptions(); |
9823 | } |
9824 | |
9825 | template<> inline const tflite::AddOptions *Operator::builtin_options_as<tflite::AddOptions>() const { |
9826 | return builtin_options_as_AddOptions(); |
9827 | } |
9828 | |
9829 | template<> inline const tflite::L2NormOptions *Operator::builtin_options_as<tflite::L2NormOptions>() const { |
9830 | return builtin_options_as_L2NormOptions(); |
9831 | } |
9832 | |
9833 | template<> inline const tflite::LocalResponseNormalizationOptions *Operator::builtin_options_as<tflite::LocalResponseNormalizationOptions>() const { |
9834 | return builtin_options_as_LocalResponseNormalizationOptions(); |
9835 | } |
9836 | |
9837 | template<> inline const tflite::LSTMOptions *Operator::builtin_options_as<tflite::LSTMOptions>() const { |
9838 | return builtin_options_as_LSTMOptions(); |
9839 | } |
9840 | |
9841 | template<> inline const tflite::ResizeBilinearOptions *Operator::builtin_options_as<tflite::ResizeBilinearOptions>() const { |
9842 | return builtin_options_as_ResizeBilinearOptions(); |
9843 | } |
9844 | |
9845 | template<> inline const tflite::CallOptions *Operator::builtin_options_as<tflite::CallOptions>() const { |
9846 | return builtin_options_as_CallOptions(); |
9847 | } |
9848 | |
9849 | template<> inline const tflite::ReshapeOptions *Operator::builtin_options_as<tflite::ReshapeOptions>() const { |
9850 | return builtin_options_as_ReshapeOptions(); |
9851 | } |
9852 | |
9853 | template<> inline const tflite::SkipGramOptions *Operator::builtin_options_as<tflite::SkipGramOptions>() const { |
9854 | return builtin_options_as_SkipGramOptions(); |
9855 | } |
9856 | |
9857 | template<> inline const tflite::SpaceToDepthOptions *Operator::builtin_options_as<tflite::SpaceToDepthOptions>() const { |
9858 | return builtin_options_as_SpaceToDepthOptions(); |
9859 | } |
9860 | |
9861 | template<> inline const tflite::EmbeddingLookupSparseOptions *Operator::builtin_options_as<tflite::EmbeddingLookupSparseOptions>() const { |
9862 | return builtin_options_as_EmbeddingLookupSparseOptions(); |
9863 | } |
9864 | |
9865 | template<> inline const tflite::MulOptions *Operator::builtin_options_as<tflite::MulOptions>() const { |
9866 | return builtin_options_as_MulOptions(); |
9867 | } |
9868 | |
9869 | template<> inline const tflite::PadOptions *Operator::builtin_options_as<tflite::PadOptions>() const { |
9870 | return builtin_options_as_PadOptions(); |
9871 | } |
9872 | |
9873 | template<> inline const tflite::GatherOptions *Operator::builtin_options_as<tflite::GatherOptions>() const { |
9874 | return builtin_options_as_GatherOptions(); |
9875 | } |
9876 | |
9877 | template<> inline const tflite::BatchToSpaceNDOptions *Operator::builtin_options_as<tflite::BatchToSpaceNDOptions>() const { |
9878 | return builtin_options_as_BatchToSpaceNDOptions(); |
9879 | } |
9880 | |
9881 | template<> inline const tflite::SpaceToBatchNDOptions *Operator::builtin_options_as<tflite::SpaceToBatchNDOptions>() const { |
9882 | return builtin_options_as_SpaceToBatchNDOptions(); |
9883 | } |
9884 | |
9885 | template<> inline const tflite::TransposeOptions *Operator::builtin_options_as<tflite::TransposeOptions>() const { |
9886 | return builtin_options_as_TransposeOptions(); |
9887 | } |
9888 | |
9889 | template<> inline const tflite::ReducerOptions *Operator::builtin_options_as<tflite::ReducerOptions>() const { |
9890 | return builtin_options_as_ReducerOptions(); |
9891 | } |
9892 | |
9893 | template<> inline const tflite::SubOptions *Operator::builtin_options_as<tflite::SubOptions>() const { |
9894 | return builtin_options_as_SubOptions(); |
9895 | } |
9896 | |
9897 | template<> inline const tflite::DivOptions *Operator::builtin_options_as<tflite::DivOptions>() const { |
9898 | return builtin_options_as_DivOptions(); |
9899 | } |
9900 | |
9901 | template<> inline const tflite::SqueezeOptions *Operator::builtin_options_as<tflite::SqueezeOptions>() const { |
9902 | return builtin_options_as_SqueezeOptions(); |
9903 | } |
9904 | |
9905 | template<> inline const tflite::SequenceRNNOptions *Operator::builtin_options_as<tflite::SequenceRNNOptions>() const { |
9906 | return builtin_options_as_SequenceRNNOptions(); |
9907 | } |
9908 | |
9909 | template<> inline const tflite::StridedSliceOptions *Operator::builtin_options_as<tflite::StridedSliceOptions>() const { |
9910 | return builtin_options_as_StridedSliceOptions(); |
9911 | } |
9912 | |
9913 | template<> inline const tflite::ExpOptions *Operator::builtin_options_as<tflite::ExpOptions>() const { |
9914 | return builtin_options_as_ExpOptions(); |
9915 | } |
9916 | |
9917 | template<> inline const tflite::TopKV2Options *Operator::builtin_options_as<tflite::TopKV2Options>() const { |
9918 | return builtin_options_as_TopKV2Options(); |
9919 | } |
9920 | |
9921 | template<> inline const tflite::SplitOptions *Operator::builtin_options_as<tflite::SplitOptions>() const { |
9922 | return builtin_options_as_SplitOptions(); |
9923 | } |
9924 | |
9925 | template<> inline const tflite::LogSoftmaxOptions *Operator::builtin_options_as<tflite::LogSoftmaxOptions>() const { |
9926 | return builtin_options_as_LogSoftmaxOptions(); |
9927 | } |
9928 | |
9929 | template<> inline const tflite::CastOptions *Operator::builtin_options_as<tflite::CastOptions>() const { |
9930 | return builtin_options_as_CastOptions(); |
9931 | } |
9932 | |
9933 | template<> inline const tflite::DequantizeOptions *Operator::builtin_options_as<tflite::DequantizeOptions>() const { |
9934 | return builtin_options_as_DequantizeOptions(); |
9935 | } |
9936 | |
9937 | template<> inline const tflite::MaximumMinimumOptions *Operator::builtin_options_as<tflite::MaximumMinimumOptions>() const { |
9938 | return builtin_options_as_MaximumMinimumOptions(); |
9939 | } |
9940 | |
9941 | template<> inline const tflite::ArgMaxOptions *Operator::builtin_options_as<tflite::ArgMaxOptions>() const { |
9942 | return builtin_options_as_ArgMaxOptions(); |
9943 | } |
9944 | |
9945 | template<> inline const tflite::LessOptions *Operator::builtin_options_as<tflite::LessOptions>() const { |
9946 | return builtin_options_as_LessOptions(); |
9947 | } |
9948 | |
9949 | template<> inline const tflite::NegOptions *Operator::builtin_options_as<tflite::NegOptions>() const { |
9950 | return builtin_options_as_NegOptions(); |
9951 | } |
9952 | |
9953 | template<> inline const tflite::PadV2Options *Operator::builtin_options_as<tflite::PadV2Options>() const { |
9954 | return builtin_options_as_PadV2Options(); |
9955 | } |
9956 | |
9957 | template<> inline const tflite::GreaterOptions *Operator::builtin_options_as<tflite::GreaterOptions>() const { |
9958 | return builtin_options_as_GreaterOptions(); |
9959 | } |
9960 | |
9961 | template<> inline const tflite::GreaterEqualOptions *Operator::builtin_options_as<tflite::GreaterEqualOptions>() const { |
9962 | return builtin_options_as_GreaterEqualOptions(); |
9963 | } |
9964 | |
9965 | template<> inline const tflite::LessEqualOptions *Operator::builtin_options_as<tflite::LessEqualOptions>() const { |
9966 | return builtin_options_as_LessEqualOptions(); |
9967 | } |
9968 | |
9969 | template<> inline const tflite::SelectOptions *Operator::builtin_options_as<tflite::SelectOptions>() const { |
9970 | return builtin_options_as_SelectOptions(); |
9971 | } |
9972 | |
9973 | template<> inline const tflite::SliceOptions *Operator::builtin_options_as<tflite::SliceOptions>() const { |
9974 | return builtin_options_as_SliceOptions(); |
9975 | } |
9976 | |
9977 | template<> inline const tflite::TransposeConvOptions *Operator::builtin_options_as<tflite::TransposeConvOptions>() const { |
9978 | return builtin_options_as_TransposeConvOptions(); |
9979 | } |
9980 | |
9981 | template<> inline const tflite::SparseToDenseOptions *Operator::builtin_options_as<tflite::SparseToDenseOptions>() const { |
9982 | return builtin_options_as_SparseToDenseOptions(); |
9983 | } |
9984 | |
9985 | template<> inline const tflite::TileOptions *Operator::builtin_options_as<tflite::TileOptions>() const { |
9986 | return builtin_options_as_TileOptions(); |
9987 | } |
9988 | |
9989 | template<> inline const tflite::ExpandDimsOptions *Operator::builtin_options_as<tflite::ExpandDimsOptions>() const { |
9990 | return builtin_options_as_ExpandDimsOptions(); |
9991 | } |
9992 | |
9993 | template<> inline const tflite::EqualOptions *Operator::builtin_options_as<tflite::EqualOptions>() const { |
9994 | return builtin_options_as_EqualOptions(); |
9995 | } |
9996 | |
9997 | template<> inline const tflite::NotEqualOptions *Operator::builtin_options_as<tflite::NotEqualOptions>() const { |
9998 | return builtin_options_as_NotEqualOptions(); |
9999 | } |
10000 | |
10001 | template<> inline const tflite::ShapeOptions *Operator::builtin_options_as<tflite::ShapeOptions>() const { |
10002 | return builtin_options_as_ShapeOptions(); |
10003 | } |
10004 | |
10005 | template<> inline const tflite::PowOptions *Operator::builtin_options_as<tflite::PowOptions>() const { |
10006 | return builtin_options_as_PowOptions(); |
10007 | } |
10008 | |
10009 | template<> inline const tflite::ArgMinOptions *Operator::builtin_options_as<tflite::ArgMinOptions>() const { |
10010 | return builtin_options_as_ArgMinOptions(); |
10011 | } |
10012 | |
10013 | template<> inline const tflite::FakeQuantOptions *Operator::builtin_options_as<tflite::FakeQuantOptions>() const { |
10014 | return builtin_options_as_FakeQuantOptions(); |
10015 | } |
10016 | |
10017 | template<> inline const tflite::PackOptions *Operator::builtin_options_as<tflite::PackOptions>() const { |
10018 | return builtin_options_as_PackOptions(); |
10019 | } |
10020 | |
10021 | template<> inline const tflite::LogicalOrOptions *Operator::builtin_options_as<tflite::LogicalOrOptions>() const { |
10022 | return builtin_options_as_LogicalOrOptions(); |
10023 | } |
10024 | |
10025 | template<> inline const tflite::OneHotOptions *Operator::builtin_options_as<tflite::OneHotOptions>() const { |
10026 | return builtin_options_as_OneHotOptions(); |
10027 | } |
10028 | |
10029 | template<> inline const tflite::LogicalAndOptions *Operator::builtin_options_as<tflite::LogicalAndOptions>() const { |
10030 | return builtin_options_as_LogicalAndOptions(); |
10031 | } |
10032 | |
10033 | template<> inline const tflite::LogicalNotOptions *Operator::builtin_options_as<tflite::LogicalNotOptions>() const { |
10034 | return builtin_options_as_LogicalNotOptions(); |
10035 | } |
10036 | |
10037 | template<> inline const tflite::UnpackOptions *Operator::builtin_options_as<tflite::UnpackOptions>() const { |
10038 | return builtin_options_as_UnpackOptions(); |
10039 | } |
10040 | |
10041 | template<> inline const tflite::FloorDivOptions *Operator::builtin_options_as<tflite::FloorDivOptions>() const { |
10042 | return builtin_options_as_FloorDivOptions(); |
10043 | } |
10044 | |
10045 | template<> inline const tflite::SquareOptions *Operator::builtin_options_as<tflite::SquareOptions>() const { |
10046 | return builtin_options_as_SquareOptions(); |
10047 | } |
10048 | |
10049 | template<> inline const tflite::ZerosLikeOptions *Operator::builtin_options_as<tflite::ZerosLikeOptions>() const { |
10050 | return builtin_options_as_ZerosLikeOptions(); |
10051 | } |
10052 | |
10053 | template<> inline const tflite::FillOptions *Operator::builtin_options_as<tflite::FillOptions>() const { |
10054 | return builtin_options_as_FillOptions(); |
10055 | } |
10056 | |
10057 | template<> inline const tflite::BidirectionalSequenceLSTMOptions *Operator::builtin_options_as<tflite::BidirectionalSequenceLSTMOptions>() const { |
10058 | return builtin_options_as_BidirectionalSequenceLSTMOptions(); |
10059 | } |
10060 | |
10061 | template<> inline const tflite::BidirectionalSequenceRNNOptions *Operator::builtin_options_as<tflite::BidirectionalSequenceRNNOptions>() const { |
10062 | return builtin_options_as_BidirectionalSequenceRNNOptions(); |
10063 | } |
10064 | |
10065 | template<> inline const tflite::UnidirectionalSequenceLSTMOptions *Operator::builtin_options_as<tflite::UnidirectionalSequenceLSTMOptions>() const { |
10066 | return builtin_options_as_UnidirectionalSequenceLSTMOptions(); |
10067 | } |
10068 | |
10069 | template<> inline const tflite::FloorModOptions *Operator::builtin_options_as<tflite::FloorModOptions>() const { |
10070 | return builtin_options_as_FloorModOptions(); |
10071 | } |
10072 | |
10073 | template<> inline const tflite::RangeOptions *Operator::builtin_options_as<tflite::RangeOptions>() const { |
10074 | return builtin_options_as_RangeOptions(); |
10075 | } |
10076 | |
10077 | template<> inline const tflite::ResizeNearestNeighborOptions *Operator::builtin_options_as<tflite::ResizeNearestNeighborOptions>() const { |
10078 | return builtin_options_as_ResizeNearestNeighborOptions(); |
10079 | } |
10080 | |
10081 | template<> inline const tflite::LeakyReluOptions *Operator::builtin_options_as<tflite::LeakyReluOptions>() const { |
10082 | return builtin_options_as_LeakyReluOptions(); |
10083 | } |
10084 | |
10085 | template<> inline const tflite::SquaredDifferenceOptions *Operator::builtin_options_as<tflite::SquaredDifferenceOptions>() const { |
10086 | return builtin_options_as_SquaredDifferenceOptions(); |
10087 | } |
10088 | |
10089 | template<> inline const tflite::MirrorPadOptions *Operator::builtin_options_as<tflite::MirrorPadOptions>() const { |
10090 | return builtin_options_as_MirrorPadOptions(); |
10091 | } |
10092 | |
10093 | template<> inline const tflite::AbsOptions *Operator::builtin_options_as<tflite::AbsOptions>() const { |
10094 | return builtin_options_as_AbsOptions(); |
10095 | } |
10096 | |
10097 | template<> inline const tflite::SplitVOptions *Operator::builtin_options_as<tflite::SplitVOptions>() const { |
10098 | return builtin_options_as_SplitVOptions(); |
10099 | } |
10100 | |
10101 | template<> inline const tflite::UniqueOptions *Operator::builtin_options_as<tflite::UniqueOptions>() const { |
10102 | return builtin_options_as_UniqueOptions(); |
10103 | } |
10104 | |
10105 | template<> inline const tflite::ReverseV2Options *Operator::builtin_options_as<tflite::ReverseV2Options>() const { |
10106 | return builtin_options_as_ReverseV2Options(); |
10107 | } |
10108 | |
10109 | template<> inline const tflite::AddNOptions *Operator::builtin_options_as<tflite::AddNOptions>() const { |
10110 | return builtin_options_as_AddNOptions(); |
10111 | } |
10112 | |
10113 | template<> inline const tflite::GatherNdOptions *Operator::builtin_options_as<tflite::GatherNdOptions>() const { |
10114 | return builtin_options_as_GatherNdOptions(); |
10115 | } |
10116 | |
10117 | template<> inline const tflite::CosOptions *Operator::builtin_options_as<tflite::CosOptions>() const { |
10118 | return builtin_options_as_CosOptions(); |
10119 | } |
10120 | |
10121 | template<> inline const tflite::WhereOptions *Operator::builtin_options_as<tflite::WhereOptions>() const { |
10122 | return builtin_options_as_WhereOptions(); |
10123 | } |
10124 | |
10125 | template<> inline const tflite::RankOptions *Operator::builtin_options_as<tflite::RankOptions>() const { |
10126 | return builtin_options_as_RankOptions(); |
10127 | } |
10128 | |
10129 | template<> inline const tflite::ReverseSequenceOptions *Operator::builtin_options_as<tflite::ReverseSequenceOptions>() const { |
10130 | return builtin_options_as_ReverseSequenceOptions(); |
10131 | } |
10132 | |
10133 | template<> inline const tflite::MatrixDiagOptions *Operator::builtin_options_as<tflite::MatrixDiagOptions>() const { |
10134 | return builtin_options_as_MatrixDiagOptions(); |
10135 | } |
10136 | |
10137 | template<> inline const tflite::QuantizeOptions *Operator::builtin_options_as<tflite::QuantizeOptions>() const { |
10138 | return builtin_options_as_QuantizeOptions(); |
10139 | } |
10140 | |
10141 | template<> inline const tflite::MatrixSetDiagOptions *Operator::builtin_options_as<tflite::MatrixSetDiagOptions>() const { |
10142 | return builtin_options_as_MatrixSetDiagOptions(); |
10143 | } |
10144 | |
10145 | template<> inline const tflite::HardSwishOptions *Operator::builtin_options_as<tflite::HardSwishOptions>() const { |
10146 | return builtin_options_as_HardSwishOptions(); |
10147 | } |
10148 | |
10149 | template<> inline const tflite::IfOptions *Operator::builtin_options_as<tflite::IfOptions>() const { |
10150 | return builtin_options_as_IfOptions(); |
10151 | } |
10152 | |
10153 | template<> inline const tflite::WhileOptions *Operator::builtin_options_as<tflite::WhileOptions>() const { |
10154 | return builtin_options_as_WhileOptions(); |
10155 | } |
10156 | |
10157 | template<> inline const tflite::DepthToSpaceOptions *Operator::builtin_options_as<tflite::DepthToSpaceOptions>() const { |
10158 | return builtin_options_as_DepthToSpaceOptions(); |
10159 | } |
10160 | |
10161 | template<> inline const tflite::NonMaxSuppressionV4Options *Operator::builtin_options_as<tflite::NonMaxSuppressionV4Options>() const { |
10162 | return builtin_options_as_NonMaxSuppressionV4Options(); |
10163 | } |
10164 | |
10165 | template<> inline const tflite::NonMaxSuppressionV5Options *Operator::builtin_options_as<tflite::NonMaxSuppressionV5Options>() const { |
10166 | return builtin_options_as_NonMaxSuppressionV5Options(); |
10167 | } |
10168 | |
10169 | template<> inline const tflite::ScatterNdOptions *Operator::builtin_options_as<tflite::ScatterNdOptions>() const { |
10170 | return builtin_options_as_ScatterNdOptions(); |
10171 | } |
10172 | |
10173 | template<> inline const tflite::SelectV2Options *Operator::builtin_options_as<tflite::SelectV2Options>() const { |
10174 | return builtin_options_as_SelectV2Options(); |
10175 | } |
10176 | |
10177 | template<> inline const tflite::DensifyOptions *Operator::builtin_options_as<tflite::DensifyOptions>() const { |
10178 | return builtin_options_as_DensifyOptions(); |
10179 | } |
10180 | |
10181 | template<> inline const tflite::SegmentSumOptions *Operator::builtin_options_as<tflite::SegmentSumOptions>() const { |
10182 | return builtin_options_as_SegmentSumOptions(); |
10183 | } |
10184 | |
10185 | template<> inline const tflite::BatchMatMulOptions *Operator::builtin_options_as<tflite::BatchMatMulOptions>() const { |
10186 | return builtin_options_as_BatchMatMulOptions(); |
10187 | } |
10188 | |
10189 | struct OperatorBuilder { |
10190 | flatbuffers::FlatBufferBuilder &fbb_; |
10191 | flatbuffers::uoffset_t start_; |
10192 | void add_opcode_index(uint32_t opcode_index) { |
10193 | fbb_.AddElement<uint32_t>(Operator::VT_OPCODE_INDEX, opcode_index, 0); |
10194 | } |
10195 | void add_inputs(flatbuffers::Offset<flatbuffers::Vector<int32_t>> inputs) { |
10196 | fbb_.AddOffset(Operator::VT_INPUTS, inputs); |
10197 | } |
10198 | void add_outputs(flatbuffers::Offset<flatbuffers::Vector<int32_t>> outputs) { |
10199 | fbb_.AddOffset(Operator::VT_OUTPUTS, outputs); |
10200 | } |
10201 | void add_builtin_options_type(tflite::BuiltinOptions builtin_options_type) { |
10202 | fbb_.AddElement<uint8_t>(Operator::VT_BUILTIN_OPTIONS_TYPE, static_cast<uint8_t>(builtin_options_type), 0); |
10203 | } |
10204 | void add_builtin_options(flatbuffers::Offset<void> builtin_options) { |
10205 | fbb_.AddOffset(Operator::VT_BUILTIN_OPTIONS, builtin_options); |
10206 | } |
10207 | void add_custom_options(flatbuffers::Offset<flatbuffers::Vector<uint8_t>> custom_options) { |
10208 | fbb_.AddOffset(Operator::VT_CUSTOM_OPTIONS, custom_options); |
10209 | } |
10210 | void add_custom_options_format(tflite::CustomOptionsFormat custom_options_format) { |
10211 | fbb_.AddElement<int8_t>(Operator::VT_CUSTOM_OPTIONS_FORMAT, static_cast<int8_t>(custom_options_format), 0); |
10212 | } |
10213 | void add_mutating_variable_inputs(flatbuffers::Offset<flatbuffers::Vector<uint8_t>> mutating_variable_inputs) { |
10214 | fbb_.AddOffset(Operator::VT_MUTATING_VARIABLE_INPUTS, mutating_variable_inputs); |
10215 | } |
10216 | void add_intermediates(flatbuffers::Offset<flatbuffers::Vector<int32_t>> intermediates) { |
10217 | fbb_.AddOffset(Operator::VT_INTERMEDIATES, intermediates); |
10218 | } |
10219 | explicit OperatorBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
10220 | : fbb_(_fbb) { |
10221 | start_ = fbb_.StartTable(); |
10222 | } |
10223 | OperatorBuilder &operator=(const OperatorBuilder &); |
10224 | flatbuffers::Offset<Operator> Finish() { |
10225 | const auto end = fbb_.EndTable(start_); |
10226 | auto o = flatbuffers::Offset<Operator>(end); |
10227 | return o; |
10228 | } |
10229 | }; |
10230 | |
10231 | inline flatbuffers::Offset<Operator> CreateOperator( |
10232 | flatbuffers::FlatBufferBuilder &_fbb, |
10233 | uint32_t opcode_index = 0, |
10234 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> inputs = 0, |
10235 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> outputs = 0, |
10236 | tflite::BuiltinOptions builtin_options_type = tflite::BuiltinOptions_NONE, |
10237 | flatbuffers::Offset<void> builtin_options = 0, |
10238 | flatbuffers::Offset<flatbuffers::Vector<uint8_t>> custom_options = 0, |
10239 | tflite::CustomOptionsFormat custom_options_format = tflite::CustomOptionsFormat_FLEXBUFFERS, |
10240 | flatbuffers::Offset<flatbuffers::Vector<uint8_t>> mutating_variable_inputs = 0, |
10241 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> intermediates = 0) { |
10242 | OperatorBuilder builder_(_fbb); |
10243 | builder_.add_intermediates(intermediates); |
10244 | builder_.add_mutating_variable_inputs(mutating_variable_inputs); |
10245 | builder_.add_custom_options(custom_options); |
10246 | builder_.add_builtin_options(builtin_options); |
10247 | builder_.add_outputs(outputs); |
10248 | builder_.add_inputs(inputs); |
10249 | builder_.add_opcode_index(opcode_index); |
10250 | builder_.add_custom_options_format(custom_options_format); |
10251 | builder_.add_builtin_options_type(builtin_options_type); |
10252 | return builder_.Finish(); |
10253 | } |
10254 | |
10255 | inline flatbuffers::Offset<Operator> CreateOperatorDirect( |
10256 | flatbuffers::FlatBufferBuilder &_fbb, |
10257 | uint32_t opcode_index = 0, |
10258 | const std::vector<int32_t> *inputs = nullptr, |
10259 | const std::vector<int32_t> *outputs = nullptr, |
10260 | tflite::BuiltinOptions builtin_options_type = tflite::BuiltinOptions_NONE, |
10261 | flatbuffers::Offset<void> builtin_options = 0, |
10262 | const std::vector<uint8_t> *custom_options = nullptr, |
10263 | tflite::CustomOptionsFormat custom_options_format = tflite::CustomOptionsFormat_FLEXBUFFERS, |
10264 | const std::vector<uint8_t> *mutating_variable_inputs = nullptr, |
10265 | const std::vector<int32_t> *intermediates = nullptr) { |
10266 | auto inputs__ = inputs ? _fbb.CreateVector<int32_t>(*inputs) : 0; |
10267 | auto outputs__ = outputs ? _fbb.CreateVector<int32_t>(*outputs) : 0; |
10268 | auto custom_options__ = custom_options ? _fbb.CreateVector<uint8_t>(*custom_options) : 0; |
10269 | auto mutating_variable_inputs__ = mutating_variable_inputs ? _fbb.CreateVector<uint8_t>(*mutating_variable_inputs) : 0; |
10270 | auto intermediates__ = intermediates ? _fbb.CreateVector<int32_t>(*intermediates) : 0; |
10271 | return tflite::CreateOperator( |
10272 | _fbb, |
10273 | opcode_index, |
10274 | inputs__, |
10275 | outputs__, |
10276 | builtin_options_type, |
10277 | builtin_options, |
10278 | custom_options__, |
10279 | custom_options_format, |
10280 | mutating_variable_inputs__, |
10281 | intermediates__); |
10282 | } |
10283 | |
10284 | flatbuffers::Offset<Operator> CreateOperator(flatbuffers::FlatBufferBuilder &_fbb, const OperatorT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10285 | |
10286 | struct SubGraphT : public flatbuffers::NativeTable { |
10287 | typedef SubGraph TableType; |
10288 | std::vector<std::unique_ptr<tflite::TensorT>> tensors; |
10289 | std::vector<int32_t> inputs; |
10290 | std::vector<int32_t> outputs; |
10291 | std::vector<std::unique_ptr<tflite::OperatorT>> operators; |
10292 | std::string name; |
10293 | SubGraphT() { |
10294 | } |
10295 | }; |
10296 | |
10297 | struct SubGraph FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
10298 | typedef SubGraphT NativeTableType; |
10299 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
10300 | VT_TENSORS = 4, |
10301 | VT_INPUTS = 6, |
10302 | VT_OUTPUTS = 8, |
10303 | VT_OPERATORS = 10, |
10304 | VT_NAME = 12 |
10305 | }; |
10306 | const flatbuffers::Vector<flatbuffers::Offset<tflite::Tensor>> *tensors() const { |
10307 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::Tensor>> *>(VT_TENSORS); |
10308 | } |
10309 | const flatbuffers::Vector<int32_t> *inputs() const { |
10310 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_INPUTS); |
10311 | } |
10312 | const flatbuffers::Vector<int32_t> *outputs() const { |
10313 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_OUTPUTS); |
10314 | } |
10315 | const flatbuffers::Vector<flatbuffers::Offset<tflite::Operator>> *operators() const { |
10316 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::Operator>> *>(VT_OPERATORS); |
10317 | } |
10318 | const flatbuffers::String *name() const { |
10319 | return GetPointer<const flatbuffers::String *>(VT_NAME); |
10320 | } |
10321 | bool Verify(flatbuffers::Verifier &verifier) const { |
10322 | return VerifyTableStart(verifier) && |
10323 | VerifyOffset(verifier, VT_TENSORS) && |
10324 | verifier.VerifyVector(tensors()) && |
10325 | verifier.VerifyVectorOfTables(tensors()) && |
10326 | VerifyOffset(verifier, VT_INPUTS) && |
10327 | verifier.VerifyVector(inputs()) && |
10328 | VerifyOffset(verifier, VT_OUTPUTS) && |
10329 | verifier.VerifyVector(outputs()) && |
10330 | VerifyOffset(verifier, VT_OPERATORS) && |
10331 | verifier.VerifyVector(operators()) && |
10332 | verifier.VerifyVectorOfTables(operators()) && |
10333 | VerifyOffset(verifier, VT_NAME) && |
10334 | verifier.VerifyString(name()) && |
10335 | verifier.EndTable(); |
10336 | } |
10337 | SubGraphT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10338 | void UnPackTo(SubGraphT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10339 | static flatbuffers::Offset<SubGraph> Pack(flatbuffers::FlatBufferBuilder &_fbb, const SubGraphT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10340 | }; |
10341 | |
10342 | struct SubGraphBuilder { |
10343 | flatbuffers::FlatBufferBuilder &fbb_; |
10344 | flatbuffers::uoffset_t start_; |
10345 | void add_tensors(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Tensor>>> tensors) { |
10346 | fbb_.AddOffset(SubGraph::VT_TENSORS, tensors); |
10347 | } |
10348 | void add_inputs(flatbuffers::Offset<flatbuffers::Vector<int32_t>> inputs) { |
10349 | fbb_.AddOffset(SubGraph::VT_INPUTS, inputs); |
10350 | } |
10351 | void add_outputs(flatbuffers::Offset<flatbuffers::Vector<int32_t>> outputs) { |
10352 | fbb_.AddOffset(SubGraph::VT_OUTPUTS, outputs); |
10353 | } |
10354 | void add_operators(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Operator>>> operators) { |
10355 | fbb_.AddOffset(SubGraph::VT_OPERATORS, operators); |
10356 | } |
10357 | void add_name(flatbuffers::Offset<flatbuffers::String> name) { |
10358 | fbb_.AddOffset(SubGraph::VT_NAME, name); |
10359 | } |
10360 | explicit SubGraphBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
10361 | : fbb_(_fbb) { |
10362 | start_ = fbb_.StartTable(); |
10363 | } |
10364 | SubGraphBuilder &operator=(const SubGraphBuilder &); |
10365 | flatbuffers::Offset<SubGraph> Finish() { |
10366 | const auto end = fbb_.EndTable(start_); |
10367 | auto o = flatbuffers::Offset<SubGraph>(end); |
10368 | return o; |
10369 | } |
10370 | }; |
10371 | |
10372 | inline flatbuffers::Offset<SubGraph> CreateSubGraph( |
10373 | flatbuffers::FlatBufferBuilder &_fbb, |
10374 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Tensor>>> tensors = 0, |
10375 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> inputs = 0, |
10376 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> outputs = 0, |
10377 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Operator>>> operators = 0, |
10378 | flatbuffers::Offset<flatbuffers::String> name = 0) { |
10379 | SubGraphBuilder builder_(_fbb); |
10380 | builder_.add_name(name); |
10381 | builder_.add_operators(operators); |
10382 | builder_.add_outputs(outputs); |
10383 | builder_.add_inputs(inputs); |
10384 | builder_.add_tensors(tensors); |
10385 | return builder_.Finish(); |
10386 | } |
10387 | |
10388 | inline flatbuffers::Offset<SubGraph> CreateSubGraphDirect( |
10389 | flatbuffers::FlatBufferBuilder &_fbb, |
10390 | const std::vector<flatbuffers::Offset<tflite::Tensor>> *tensors = nullptr, |
10391 | const std::vector<int32_t> *inputs = nullptr, |
10392 | const std::vector<int32_t> *outputs = nullptr, |
10393 | const std::vector<flatbuffers::Offset<tflite::Operator>> *operators = nullptr, |
10394 | const char *name = nullptr) { |
10395 | auto tensors__ = tensors ? _fbb.CreateVector<flatbuffers::Offset<tflite::Tensor>>(*tensors) : 0; |
10396 | auto inputs__ = inputs ? _fbb.CreateVector<int32_t>(*inputs) : 0; |
10397 | auto outputs__ = outputs ? _fbb.CreateVector<int32_t>(*outputs) : 0; |
10398 | auto operators__ = operators ? _fbb.CreateVector<flatbuffers::Offset<tflite::Operator>>(*operators) : 0; |
10399 | auto name__ = name ? _fbb.CreateString(name) : 0; |
10400 | return tflite::CreateSubGraph( |
10401 | _fbb, |
10402 | tensors__, |
10403 | inputs__, |
10404 | outputs__, |
10405 | operators__, |
10406 | name__); |
10407 | } |
10408 | |
10409 | flatbuffers::Offset<SubGraph> CreateSubGraph(flatbuffers::FlatBufferBuilder &_fbb, const SubGraphT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10410 | |
10411 | struct BufferT : public flatbuffers::NativeTable { |
10412 | typedef Buffer TableType; |
10413 | std::vector<uint8_t> data; |
10414 | BufferT() { |
10415 | } |
10416 | }; |
10417 | |
10418 | struct Buffer FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
10419 | typedef BufferT NativeTableType; |
10420 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
10421 | VT_DATA = 4 |
10422 | }; |
10423 | const flatbuffers::Vector<uint8_t> *data() const { |
10424 | return GetPointer<const flatbuffers::Vector<uint8_t> *>(VT_DATA); |
10425 | } |
10426 | bool Verify(flatbuffers::Verifier &verifier) const { |
10427 | return VerifyTableStart(verifier) && |
10428 | VerifyOffset(verifier, VT_DATA) && |
10429 | verifier.VerifyVector(data()) && |
10430 | verifier.EndTable(); |
10431 | } |
10432 | BufferT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10433 | void UnPackTo(BufferT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10434 | static flatbuffers::Offset<Buffer> Pack(flatbuffers::FlatBufferBuilder &_fbb, const BufferT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10435 | }; |
10436 | |
10437 | struct BufferBuilder { |
10438 | flatbuffers::FlatBufferBuilder &fbb_; |
10439 | flatbuffers::uoffset_t start_; |
10440 | void add_data(flatbuffers::Offset<flatbuffers::Vector<uint8_t>> data) { |
10441 | fbb_.AddOffset(Buffer::VT_DATA, data); |
10442 | } |
10443 | explicit BufferBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
10444 | : fbb_(_fbb) { |
10445 | start_ = fbb_.StartTable(); |
10446 | } |
10447 | BufferBuilder &operator=(const BufferBuilder &); |
10448 | flatbuffers::Offset<Buffer> Finish() { |
10449 | const auto end = fbb_.EndTable(start_); |
10450 | auto o = flatbuffers::Offset<Buffer>(end); |
10451 | return o; |
10452 | } |
10453 | }; |
10454 | |
10455 | inline flatbuffers::Offset<Buffer> CreateBuffer( |
10456 | flatbuffers::FlatBufferBuilder &_fbb, |
10457 | flatbuffers::Offset<flatbuffers::Vector<uint8_t>> data = 0) { |
10458 | BufferBuilder builder_(_fbb); |
10459 | builder_.add_data(data); |
10460 | return builder_.Finish(); |
10461 | } |
10462 | |
10463 | inline flatbuffers::Offset<Buffer> CreateBufferDirect( |
10464 | flatbuffers::FlatBufferBuilder &_fbb, |
10465 | const std::vector<uint8_t> *data = nullptr) { |
10466 | if (data) { _fbb.ForceVectorAlignment(data->size(), sizeof(uint8_t), 16); } |
10467 | auto data__ = data ? _fbb.CreateVector<uint8_t>(*data) : 0; |
10468 | return tflite::CreateBuffer( |
10469 | _fbb, |
10470 | data__); |
10471 | } |
10472 | |
10473 | flatbuffers::Offset<Buffer> CreateBuffer(flatbuffers::FlatBufferBuilder &_fbb, const BufferT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10474 | |
10475 | struct MetadataT : public flatbuffers::NativeTable { |
10476 | typedef Metadata TableType; |
10477 | std::string name; |
10478 | uint32_t buffer; |
10479 | MetadataT() |
10480 | : buffer(0) { |
10481 | } |
10482 | }; |
10483 | |
10484 | struct Metadata FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
10485 | typedef MetadataT NativeTableType; |
10486 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
10487 | VT_NAME = 4, |
10488 | VT_BUFFER = 6 |
10489 | }; |
10490 | const flatbuffers::String *name() const { |
10491 | return GetPointer<const flatbuffers::String *>(VT_NAME); |
10492 | } |
10493 | uint32_t buffer() const { |
10494 | return GetField<uint32_t>(VT_BUFFER, 0); |
10495 | } |
10496 | bool Verify(flatbuffers::Verifier &verifier) const { |
10497 | return VerifyTableStart(verifier) && |
10498 | VerifyOffset(verifier, VT_NAME) && |
10499 | verifier.VerifyString(name()) && |
10500 | VerifyField<uint32_t>(verifier, VT_BUFFER) && |
10501 | verifier.EndTable(); |
10502 | } |
10503 | MetadataT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10504 | void UnPackTo(MetadataT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10505 | static flatbuffers::Offset<Metadata> Pack(flatbuffers::FlatBufferBuilder &_fbb, const MetadataT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10506 | }; |
10507 | |
10508 | struct MetadataBuilder { |
10509 | flatbuffers::FlatBufferBuilder &fbb_; |
10510 | flatbuffers::uoffset_t start_; |
10511 | void add_name(flatbuffers::Offset<flatbuffers::String> name) { |
10512 | fbb_.AddOffset(Metadata::VT_NAME, name); |
10513 | } |
10514 | void add_buffer(uint32_t buffer) { |
10515 | fbb_.AddElement<uint32_t>(Metadata::VT_BUFFER, buffer, 0); |
10516 | } |
10517 | explicit MetadataBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
10518 | : fbb_(_fbb) { |
10519 | start_ = fbb_.StartTable(); |
10520 | } |
10521 | MetadataBuilder &operator=(const MetadataBuilder &); |
10522 | flatbuffers::Offset<Metadata> Finish() { |
10523 | const auto end = fbb_.EndTable(start_); |
10524 | auto o = flatbuffers::Offset<Metadata>(end); |
10525 | return o; |
10526 | } |
10527 | }; |
10528 | |
10529 | inline flatbuffers::Offset<Metadata> CreateMetadata( |
10530 | flatbuffers::FlatBufferBuilder &_fbb, |
10531 | flatbuffers::Offset<flatbuffers::String> name = 0, |
10532 | uint32_t buffer = 0) { |
10533 | MetadataBuilder builder_(_fbb); |
10534 | builder_.add_buffer(buffer); |
10535 | builder_.add_name(name); |
10536 | return builder_.Finish(); |
10537 | } |
10538 | |
10539 | inline flatbuffers::Offset<Metadata> CreateMetadataDirect( |
10540 | flatbuffers::FlatBufferBuilder &_fbb, |
10541 | const char *name = nullptr, |
10542 | uint32_t buffer = 0) { |
10543 | auto name__ = name ? _fbb.CreateString(name) : 0; |
10544 | return tflite::CreateMetadata( |
10545 | _fbb, |
10546 | name__, |
10547 | buffer); |
10548 | } |
10549 | |
10550 | flatbuffers::Offset<Metadata> CreateMetadata(flatbuffers::FlatBufferBuilder &_fbb, const MetadataT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10551 | |
10552 | struct ModelT : public flatbuffers::NativeTable { |
10553 | typedef Model TableType; |
10554 | uint32_t version; |
10555 | std::vector<std::unique_ptr<tflite::OperatorCodeT>> operator_codes; |
10556 | std::vector<std::unique_ptr<tflite::SubGraphT>> subgraphs; |
10557 | std::string description; |
10558 | std::vector<std::unique_ptr<tflite::BufferT>> buffers; |
10559 | std::vector<int32_t> metadata_buffer; |
10560 | std::vector<std::unique_ptr<tflite::MetadataT>> metadata; |
10561 | ModelT() |
10562 | : version(0) { |
10563 | } |
10564 | }; |
10565 | |
10566 | struct Model FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table { |
10567 | typedef ModelT NativeTableType; |
10568 | enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE { |
10569 | VT_VERSION = 4, |
10570 | VT_OPERATOR_CODES = 6, |
10571 | VT_SUBGRAPHS = 8, |
10572 | VT_DESCRIPTION = 10, |
10573 | VT_BUFFERS = 12, |
10574 | VT_METADATA_BUFFER = 14, |
10575 | VT_METADATA = 16 |
10576 | }; |
10577 | uint32_t version() const { |
10578 | return GetField<uint32_t>(VT_VERSION, 0); |
10579 | } |
10580 | const flatbuffers::Vector<flatbuffers::Offset<tflite::OperatorCode>> *operator_codes() const { |
10581 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::OperatorCode>> *>(VT_OPERATOR_CODES); |
10582 | } |
10583 | const flatbuffers::Vector<flatbuffers::Offset<tflite::SubGraph>> *subgraphs() const { |
10584 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::SubGraph>> *>(VT_SUBGRAPHS); |
10585 | } |
10586 | const flatbuffers::String *description() const { |
10587 | return GetPointer<const flatbuffers::String *>(VT_DESCRIPTION); |
10588 | } |
10589 | const flatbuffers::Vector<flatbuffers::Offset<tflite::Buffer>> *buffers() const { |
10590 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::Buffer>> *>(VT_BUFFERS); |
10591 | } |
10592 | const flatbuffers::Vector<int32_t> *metadata_buffer() const { |
10593 | return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_METADATA_BUFFER); |
10594 | } |
10595 | const flatbuffers::Vector<flatbuffers::Offset<tflite::Metadata>> *metadata() const { |
10596 | return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<tflite::Metadata>> *>(VT_METADATA); |
10597 | } |
10598 | bool Verify(flatbuffers::Verifier &verifier) const { |
10599 | return VerifyTableStart(verifier) && |
10600 | VerifyField<uint32_t>(verifier, VT_VERSION) && |
10601 | VerifyOffset(verifier, VT_OPERATOR_CODES) && |
10602 | verifier.VerifyVector(operator_codes()) && |
10603 | verifier.VerifyVectorOfTables(operator_codes()) && |
10604 | VerifyOffset(verifier, VT_SUBGRAPHS) && |
10605 | verifier.VerifyVector(subgraphs()) && |
10606 | verifier.VerifyVectorOfTables(subgraphs()) && |
10607 | VerifyOffset(verifier, VT_DESCRIPTION) && |
10608 | verifier.VerifyString(description()) && |
10609 | VerifyOffset(verifier, VT_BUFFERS) && |
10610 | verifier.VerifyVector(buffers()) && |
10611 | verifier.VerifyVectorOfTables(buffers()) && |
10612 | VerifyOffset(verifier, VT_METADATA_BUFFER) && |
10613 | verifier.VerifyVector(metadata_buffer()) && |
10614 | VerifyOffset(verifier, VT_METADATA) && |
10615 | verifier.VerifyVector(metadata()) && |
10616 | verifier.VerifyVectorOfTables(metadata()) && |
10617 | verifier.EndTable(); |
10618 | } |
10619 | ModelT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10620 | void UnPackTo(ModelT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const; |
10621 | static flatbuffers::Offset<Model> Pack(flatbuffers::FlatBufferBuilder &_fbb, const ModelT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10622 | }; |
10623 | |
10624 | struct ModelBuilder { |
10625 | flatbuffers::FlatBufferBuilder &fbb_; |
10626 | flatbuffers::uoffset_t start_; |
10627 | void add_version(uint32_t version) { |
10628 | fbb_.AddElement<uint32_t>(Model::VT_VERSION, version, 0); |
10629 | } |
10630 | void add_operator_codes(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::OperatorCode>>> operator_codes) { |
10631 | fbb_.AddOffset(Model::VT_OPERATOR_CODES, operator_codes); |
10632 | } |
10633 | void add_subgraphs(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::SubGraph>>> subgraphs) { |
10634 | fbb_.AddOffset(Model::VT_SUBGRAPHS, subgraphs); |
10635 | } |
10636 | void add_description(flatbuffers::Offset<flatbuffers::String> description) { |
10637 | fbb_.AddOffset(Model::VT_DESCRIPTION, description); |
10638 | } |
10639 | void add_buffers(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Buffer>>> buffers) { |
10640 | fbb_.AddOffset(Model::VT_BUFFERS, buffers); |
10641 | } |
10642 | void add_metadata_buffer(flatbuffers::Offset<flatbuffers::Vector<int32_t>> metadata_buffer) { |
10643 | fbb_.AddOffset(Model::VT_METADATA_BUFFER, metadata_buffer); |
10644 | } |
10645 | void add_metadata(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Metadata>>> metadata) { |
10646 | fbb_.AddOffset(Model::VT_METADATA, metadata); |
10647 | } |
10648 | explicit ModelBuilder(flatbuffers::FlatBufferBuilder &_fbb) |
10649 | : fbb_(_fbb) { |
10650 | start_ = fbb_.StartTable(); |
10651 | } |
10652 | ModelBuilder &operator=(const ModelBuilder &); |
10653 | flatbuffers::Offset<Model> Finish() { |
10654 | const auto end = fbb_.EndTable(start_); |
10655 | auto o = flatbuffers::Offset<Model>(end); |
10656 | return o; |
10657 | } |
10658 | }; |
10659 | |
10660 | inline flatbuffers::Offset<Model> CreateModel( |
10661 | flatbuffers::FlatBufferBuilder &_fbb, |
10662 | uint32_t version = 0, |
10663 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::OperatorCode>>> operator_codes = 0, |
10664 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::SubGraph>>> subgraphs = 0, |
10665 | flatbuffers::Offset<flatbuffers::String> description = 0, |
10666 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Buffer>>> buffers = 0, |
10667 | flatbuffers::Offset<flatbuffers::Vector<int32_t>> metadata_buffer = 0, |
10668 | flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<tflite::Metadata>>> metadata = 0) { |
10669 | ModelBuilder builder_(_fbb); |
10670 | builder_.add_metadata(metadata); |
10671 | builder_.add_metadata_buffer(metadata_buffer); |
10672 | builder_.add_buffers(buffers); |
10673 | builder_.add_description(description); |
10674 | builder_.add_subgraphs(subgraphs); |
10675 | builder_.add_operator_codes(operator_codes); |
10676 | builder_.add_version(version); |
10677 | return builder_.Finish(); |
10678 | } |
10679 | |
10680 | inline flatbuffers::Offset<Model> CreateModelDirect( |
10681 | flatbuffers::FlatBufferBuilder &_fbb, |
10682 | uint32_t version = 0, |
10683 | const std::vector<flatbuffers::Offset<tflite::OperatorCode>> *operator_codes = nullptr, |
10684 | const std::vector<flatbuffers::Offset<tflite::SubGraph>> *subgraphs = nullptr, |
10685 | const char *description = nullptr, |
10686 | const std::vector<flatbuffers::Offset<tflite::Buffer>> *buffers = nullptr, |
10687 | const std::vector<int32_t> *metadata_buffer = nullptr, |
10688 | const std::vector<flatbuffers::Offset<tflite::Metadata>> *metadata = nullptr) { |
10689 | auto operator_codes__ = operator_codes ? _fbb.CreateVector<flatbuffers::Offset<tflite::OperatorCode>>(*operator_codes) : 0; |
10690 | auto subgraphs__ = subgraphs ? _fbb.CreateVector<flatbuffers::Offset<tflite::SubGraph>>(*subgraphs) : 0; |
10691 | auto description__ = description ? _fbb.CreateString(description) : 0; |
10692 | auto buffers__ = buffers ? _fbb.CreateVector<flatbuffers::Offset<tflite::Buffer>>(*buffers) : 0; |
10693 | auto metadata_buffer__ = metadata_buffer ? _fbb.CreateVector<int32_t>(*metadata_buffer) : 0; |
10694 | auto metadata__ = metadata ? _fbb.CreateVector<flatbuffers::Offset<tflite::Metadata>>(*metadata) : 0; |
10695 | return tflite::CreateModel( |
10696 | _fbb, |
10697 | version, |
10698 | operator_codes__, |
10699 | subgraphs__, |
10700 | description__, |
10701 | buffers__, |
10702 | metadata_buffer__, |
10703 | metadata__); |
10704 | } |
10705 | |
10706 | flatbuffers::Offset<Model> CreateModel(flatbuffers::FlatBufferBuilder &_fbb, const ModelT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr); |
10707 | |
10708 | inline CustomQuantizationT *CustomQuantization::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10709 | auto _o = new CustomQuantizationT(); |
10710 | UnPackTo(_o, _resolver); |
10711 | return _o; |
10712 | } |
10713 | |
10714 | inline void CustomQuantization::UnPackTo(CustomQuantizationT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10715 | (void)_o; |
10716 | (void)_resolver; |
10717 | { auto _e = custom(); if (_e) { _o->custom.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->custom[_i] = _e->Get(_i); } } } |
10718 | } |
10719 | |
10720 | inline flatbuffers::Offset<CustomQuantization> CustomQuantization::Pack(flatbuffers::FlatBufferBuilder &_fbb, const CustomQuantizationT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10721 | return CreateCustomQuantization(_fbb, _o, _rehasher); |
10722 | } |
10723 | |
10724 | inline flatbuffers::Offset<CustomQuantization> CreateCustomQuantization(flatbuffers::FlatBufferBuilder &_fbb, const CustomQuantizationT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10725 | (void)_rehasher; |
10726 | (void)_o; |
10727 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const CustomQuantizationT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10728 | _fbb.ForceVectorAlignment(_o->custom.size(), sizeof(uint8_t), 16); |
10729 | auto _custom = _o->custom.size() ? _fbb.CreateVector(_o->custom) : 0; |
10730 | return tflite::CreateCustomQuantization( |
10731 | _fbb, |
10732 | _custom); |
10733 | } |
10734 | |
10735 | inline QuantizationParametersT *QuantizationParameters::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10736 | auto _o = new QuantizationParametersT(); |
10737 | UnPackTo(_o, _resolver); |
10738 | return _o; |
10739 | } |
10740 | |
10741 | inline void QuantizationParameters::UnPackTo(QuantizationParametersT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10742 | (void)_o; |
10743 | (void)_resolver; |
10744 | { auto _e = min(); if (_e) { _o->min.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->min[_i] = _e->Get(_i); } } } |
10745 | { auto _e = max(); if (_e) { _o->max.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->max[_i] = _e->Get(_i); } } } |
10746 | { auto _e = scale(); if (_e) { _o->scale.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->scale[_i] = _e->Get(_i); } } } |
10747 | { auto _e = zero_point(); if (_e) { _o->zero_point.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->zero_point[_i] = _e->Get(_i); } } } |
10748 | { auto _e = details_type(); _o->details.type = _e; } |
10749 | { auto _e = details(); if (_e) _o->details.value = tflite::QuantizationDetailsUnion::UnPack(_e, details_type(), _resolver); } |
10750 | { auto _e = quantized_dimension(); _o->quantized_dimension = _e; } |
10751 | } |
10752 | |
10753 | inline flatbuffers::Offset<QuantizationParameters> QuantizationParameters::Pack(flatbuffers::FlatBufferBuilder &_fbb, const QuantizationParametersT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10754 | return CreateQuantizationParameters(_fbb, _o, _rehasher); |
10755 | } |
10756 | |
10757 | inline flatbuffers::Offset<QuantizationParameters> CreateQuantizationParameters(flatbuffers::FlatBufferBuilder &_fbb, const QuantizationParametersT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10758 | (void)_rehasher; |
10759 | (void)_o; |
10760 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const QuantizationParametersT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10761 | auto _min = _o->min.size() ? _fbb.CreateVector(_o->min) : 0; |
10762 | auto _max = _o->max.size() ? _fbb.CreateVector(_o->max) : 0; |
10763 | auto _scale = _o->scale.size() ? _fbb.CreateVector(_o->scale) : 0; |
10764 | auto _zero_point = _o->zero_point.size() ? _fbb.CreateVector(_o->zero_point) : 0; |
10765 | auto _details_type = _o->details.type; |
10766 | auto _details = _o->details.Pack(_fbb); |
10767 | auto _quantized_dimension = _o->quantized_dimension; |
10768 | return tflite::CreateQuantizationParameters( |
10769 | _fbb, |
10770 | _min, |
10771 | _max, |
10772 | _scale, |
10773 | _zero_point, |
10774 | _details_type, |
10775 | _details, |
10776 | _quantized_dimension); |
10777 | } |
10778 | |
10779 | inline Int32VectorT *Int32Vector::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10780 | auto _o = new Int32VectorT(); |
10781 | UnPackTo(_o, _resolver); |
10782 | return _o; |
10783 | } |
10784 | |
10785 | inline void Int32Vector::UnPackTo(Int32VectorT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10786 | (void)_o; |
10787 | (void)_resolver; |
10788 | { auto _e = values(); if (_e) { _o->values.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->values[_i] = _e->Get(_i); } } } |
10789 | } |
10790 | |
10791 | inline flatbuffers::Offset<Int32Vector> Int32Vector::Pack(flatbuffers::FlatBufferBuilder &_fbb, const Int32VectorT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10792 | return CreateInt32Vector(_fbb, _o, _rehasher); |
10793 | } |
10794 | |
10795 | inline flatbuffers::Offset<Int32Vector> CreateInt32Vector(flatbuffers::FlatBufferBuilder &_fbb, const Int32VectorT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10796 | (void)_rehasher; |
10797 | (void)_o; |
10798 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const Int32VectorT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10799 | auto _values = _o->values.size() ? _fbb.CreateVector(_o->values) : 0; |
10800 | return tflite::CreateInt32Vector( |
10801 | _fbb, |
10802 | _values); |
10803 | } |
10804 | |
10805 | inline Uint16VectorT *Uint16Vector::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10806 | auto _o = new Uint16VectorT(); |
10807 | UnPackTo(_o, _resolver); |
10808 | return _o; |
10809 | } |
10810 | |
10811 | inline void Uint16Vector::UnPackTo(Uint16VectorT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10812 | (void)_o; |
10813 | (void)_resolver; |
10814 | { auto _e = values(); if (_e) { _o->values.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->values[_i] = _e->Get(_i); } } } |
10815 | } |
10816 | |
10817 | inline flatbuffers::Offset<Uint16Vector> Uint16Vector::Pack(flatbuffers::FlatBufferBuilder &_fbb, const Uint16VectorT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10818 | return CreateUint16Vector(_fbb, _o, _rehasher); |
10819 | } |
10820 | |
10821 | inline flatbuffers::Offset<Uint16Vector> CreateUint16Vector(flatbuffers::FlatBufferBuilder &_fbb, const Uint16VectorT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10822 | (void)_rehasher; |
10823 | (void)_o; |
10824 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const Uint16VectorT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10825 | _fbb.ForceVectorAlignment(_o->values.size(), sizeof(uint16_t), 4); |
10826 | auto _values = _o->values.size() ? _fbb.CreateVector(_o->values) : 0; |
10827 | return tflite::CreateUint16Vector( |
10828 | _fbb, |
10829 | _values); |
10830 | } |
10831 | |
10832 | inline Uint8VectorT *Uint8Vector::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10833 | auto _o = new Uint8VectorT(); |
10834 | UnPackTo(_o, _resolver); |
10835 | return _o; |
10836 | } |
10837 | |
10838 | inline void Uint8Vector::UnPackTo(Uint8VectorT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10839 | (void)_o; |
10840 | (void)_resolver; |
10841 | { auto _e = values(); if (_e) { _o->values.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->values[_i] = _e->Get(_i); } } } |
10842 | } |
10843 | |
10844 | inline flatbuffers::Offset<Uint8Vector> Uint8Vector::Pack(flatbuffers::FlatBufferBuilder &_fbb, const Uint8VectorT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10845 | return CreateUint8Vector(_fbb, _o, _rehasher); |
10846 | } |
10847 | |
10848 | inline flatbuffers::Offset<Uint8Vector> CreateUint8Vector(flatbuffers::FlatBufferBuilder &_fbb, const Uint8VectorT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10849 | (void)_rehasher; |
10850 | (void)_o; |
10851 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const Uint8VectorT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10852 | _fbb.ForceVectorAlignment(_o->values.size(), sizeof(uint8_t), 4); |
10853 | auto _values = _o->values.size() ? _fbb.CreateVector(_o->values) : 0; |
10854 | return tflite::CreateUint8Vector( |
10855 | _fbb, |
10856 | _values); |
10857 | } |
10858 | |
10859 | inline DimensionMetadataT *DimensionMetadata::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10860 | auto _o = new DimensionMetadataT(); |
10861 | UnPackTo(_o, _resolver); |
10862 | return _o; |
10863 | } |
10864 | |
10865 | inline void DimensionMetadata::UnPackTo(DimensionMetadataT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10866 | (void)_o; |
10867 | (void)_resolver; |
10868 | { auto _e = format(); _o->format = _e; } |
10869 | { auto _e = dense_size(); _o->dense_size = _e; } |
10870 | { auto _e = array_segments_type(); _o->array_segments.type = _e; } |
10871 | { auto _e = array_segments(); if (_e) _o->array_segments.value = tflite::SparseIndexVectorUnion::UnPack(_e, array_segments_type(), _resolver); } |
10872 | { auto _e = array_indices_type(); _o->array_indices.type = _e; } |
10873 | { auto _e = array_indices(); if (_e) _o->array_indices.value = tflite::SparseIndexVectorUnion::UnPack(_e, array_indices_type(), _resolver); } |
10874 | } |
10875 | |
10876 | inline flatbuffers::Offset<DimensionMetadata> DimensionMetadata::Pack(flatbuffers::FlatBufferBuilder &_fbb, const DimensionMetadataT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10877 | return CreateDimensionMetadata(_fbb, _o, _rehasher); |
10878 | } |
10879 | |
10880 | inline flatbuffers::Offset<DimensionMetadata> CreateDimensionMetadata(flatbuffers::FlatBufferBuilder &_fbb, const DimensionMetadataT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10881 | (void)_rehasher; |
10882 | (void)_o; |
10883 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const DimensionMetadataT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10884 | auto _format = _o->format; |
10885 | auto _dense_size = _o->dense_size; |
10886 | auto _array_segments_type = _o->array_segments.type; |
10887 | auto _array_segments = _o->array_segments.Pack(_fbb); |
10888 | auto _array_indices_type = _o->array_indices.type; |
10889 | auto _array_indices = _o->array_indices.Pack(_fbb); |
10890 | return tflite::CreateDimensionMetadata( |
10891 | _fbb, |
10892 | _format, |
10893 | _dense_size, |
10894 | _array_segments_type, |
10895 | _array_segments, |
10896 | _array_indices_type, |
10897 | _array_indices); |
10898 | } |
10899 | |
10900 | inline SparsityParametersT *SparsityParameters::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10901 | auto _o = new SparsityParametersT(); |
10902 | UnPackTo(_o, _resolver); |
10903 | return _o; |
10904 | } |
10905 | |
10906 | inline void SparsityParameters::UnPackTo(SparsityParametersT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10907 | (void)_o; |
10908 | (void)_resolver; |
10909 | { auto _e = traversal_order(); if (_e) { _o->traversal_order.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->traversal_order[_i] = _e->Get(_i); } } } |
10910 | { auto _e = block_map(); if (_e) { _o->block_map.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->block_map[_i] = _e->Get(_i); } } } |
10911 | { auto _e = dim_metadata(); if (_e) { _o->dim_metadata.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->dim_metadata[_i] = std::unique_ptr<tflite::DimensionMetadataT>(_e->Get(_i)->UnPack(_resolver)); } } } |
10912 | } |
10913 | |
10914 | inline flatbuffers::Offset<SparsityParameters> SparsityParameters::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SparsityParametersT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10915 | return CreateSparsityParameters(_fbb, _o, _rehasher); |
10916 | } |
10917 | |
10918 | inline flatbuffers::Offset<SparsityParameters> CreateSparsityParameters(flatbuffers::FlatBufferBuilder &_fbb, const SparsityParametersT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10919 | (void)_rehasher; |
10920 | (void)_o; |
10921 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SparsityParametersT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10922 | auto _traversal_order = _o->traversal_order.size() ? _fbb.CreateVector(_o->traversal_order) : 0; |
10923 | auto _block_map = _o->block_map.size() ? _fbb.CreateVector(_o->block_map) : 0; |
10924 | auto _dim_metadata = _o->dim_metadata.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::DimensionMetadata>> (_o->dim_metadata.size(), [](size_t i, _VectorArgs *__va) { return CreateDimensionMetadata(*__va->__fbb, __va->__o->dim_metadata[i].get(), __va->__rehasher); }, &_va ) : 0; |
10925 | return tflite::CreateSparsityParameters( |
10926 | _fbb, |
10927 | _traversal_order, |
10928 | _block_map, |
10929 | _dim_metadata); |
10930 | } |
10931 | |
10932 | inline TensorT *Tensor::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10933 | auto _o = new TensorT(); |
10934 | UnPackTo(_o, _resolver); |
10935 | return _o; |
10936 | } |
10937 | |
10938 | inline void Tensor::UnPackTo(TensorT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10939 | (void)_o; |
10940 | (void)_resolver; |
10941 | { auto _e = shape(); if (_e) { _o->shape.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->shape[_i] = _e->Get(_i); } } } |
10942 | { auto _e = type(); _o->type = _e; } |
10943 | { auto _e = buffer(); _o->buffer = _e; } |
10944 | { auto _e = name(); if (_e) _o->name = _e->str(); } |
10945 | { auto _e = quantization(); if (_e) _o->quantization = std::unique_ptr<tflite::QuantizationParametersT>(_e->UnPack(_resolver)); } |
10946 | { auto _e = is_variable(); _o->is_variable = _e; } |
10947 | { auto _e = sparsity(); if (_e) _o->sparsity = std::unique_ptr<tflite::SparsityParametersT>(_e->UnPack(_resolver)); } |
10948 | { auto _e = shape_signature(); if (_e) { _o->shape_signature.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->shape_signature[_i] = _e->Get(_i); } } } |
10949 | } |
10950 | |
10951 | inline flatbuffers::Offset<Tensor> Tensor::Pack(flatbuffers::FlatBufferBuilder &_fbb, const TensorT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10952 | return CreateTensor(_fbb, _o, _rehasher); |
10953 | } |
10954 | |
10955 | inline flatbuffers::Offset<Tensor> CreateTensor(flatbuffers::FlatBufferBuilder &_fbb, const TensorT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
10956 | (void)_rehasher; |
10957 | (void)_o; |
10958 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const TensorT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
10959 | auto _shape = _o->shape.size() ? _fbb.CreateVector(_o->shape) : 0; |
10960 | auto _type = _o->type; |
10961 | auto _buffer = _o->buffer; |
10962 | auto _name = _o->name.empty() ? 0 : _fbb.CreateString(_o->name); |
10963 | auto _quantization = _o->quantization ? CreateQuantizationParameters(_fbb, _o->quantization.get(), _rehasher) : 0; |
10964 | auto _is_variable = _o->is_variable; |
10965 | auto _sparsity = _o->sparsity ? CreateSparsityParameters(_fbb, _o->sparsity.get(), _rehasher) : 0; |
10966 | auto _shape_signature = _o->shape_signature.size() ? _fbb.CreateVector(_o->shape_signature) : 0; |
10967 | return tflite::CreateTensor( |
10968 | _fbb, |
10969 | _shape, |
10970 | _type, |
10971 | _buffer, |
10972 | _name, |
10973 | _quantization, |
10974 | _is_variable, |
10975 | _sparsity, |
10976 | _shape_signature); |
10977 | } |
10978 | |
10979 | inline Conv2DOptionsT *Conv2DOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
10980 | auto _o = new Conv2DOptionsT(); |
10981 | UnPackTo(_o, _resolver); |
10982 | return _o; |
10983 | } |
10984 | |
10985 | inline void Conv2DOptions::UnPackTo(Conv2DOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
10986 | (void)_o; |
10987 | (void)_resolver; |
10988 | { auto _e = padding(); _o->padding = _e; } |
10989 | { auto _e = stride_w(); _o->stride_w = _e; } |
10990 | { auto _e = stride_h(); _o->stride_h = _e; } |
10991 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
10992 | { auto _e = dilation_w_factor(); _o->dilation_w_factor = _e; } |
10993 | { auto _e = dilation_h_factor(); _o->dilation_h_factor = _e; } |
10994 | } |
10995 | |
10996 | inline flatbuffers::Offset<Conv2DOptions> Conv2DOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const Conv2DOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
10997 | return CreateConv2DOptions(_fbb, _o, _rehasher); |
10998 | } |
10999 | |
11000 | inline flatbuffers::Offset<Conv2DOptions> CreateConv2DOptions(flatbuffers::FlatBufferBuilder &_fbb, const Conv2DOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11001 | (void)_rehasher; |
11002 | (void)_o; |
11003 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const Conv2DOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11004 | auto _padding = _o->padding; |
11005 | auto _stride_w = _o->stride_w; |
11006 | auto _stride_h = _o->stride_h; |
11007 | auto _fused_activation_function = _o->fused_activation_function; |
11008 | auto _dilation_w_factor = _o->dilation_w_factor; |
11009 | auto _dilation_h_factor = _o->dilation_h_factor; |
11010 | return tflite::CreateConv2DOptions( |
11011 | _fbb, |
11012 | _padding, |
11013 | _stride_w, |
11014 | _stride_h, |
11015 | _fused_activation_function, |
11016 | _dilation_w_factor, |
11017 | _dilation_h_factor); |
11018 | } |
11019 | |
11020 | inline Pool2DOptionsT *Pool2DOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11021 | auto _o = new Pool2DOptionsT(); |
11022 | UnPackTo(_o, _resolver); |
11023 | return _o; |
11024 | } |
11025 | |
11026 | inline void Pool2DOptions::UnPackTo(Pool2DOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11027 | (void)_o; |
11028 | (void)_resolver; |
11029 | { auto _e = padding(); _o->padding = _e; } |
11030 | { auto _e = stride_w(); _o->stride_w = _e; } |
11031 | { auto _e = stride_h(); _o->stride_h = _e; } |
11032 | { auto _e = filter_width(); _o->filter_width = _e; } |
11033 | { auto _e = filter_height(); _o->filter_height = _e; } |
11034 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11035 | } |
11036 | |
11037 | inline flatbuffers::Offset<Pool2DOptions> Pool2DOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const Pool2DOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11038 | return CreatePool2DOptions(_fbb, _o, _rehasher); |
11039 | } |
11040 | |
11041 | inline flatbuffers::Offset<Pool2DOptions> CreatePool2DOptions(flatbuffers::FlatBufferBuilder &_fbb, const Pool2DOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11042 | (void)_rehasher; |
11043 | (void)_o; |
11044 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const Pool2DOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11045 | auto _padding = _o->padding; |
11046 | auto _stride_w = _o->stride_w; |
11047 | auto _stride_h = _o->stride_h; |
11048 | auto _filter_width = _o->filter_width; |
11049 | auto _filter_height = _o->filter_height; |
11050 | auto _fused_activation_function = _o->fused_activation_function; |
11051 | return tflite::CreatePool2DOptions( |
11052 | _fbb, |
11053 | _padding, |
11054 | _stride_w, |
11055 | _stride_h, |
11056 | _filter_width, |
11057 | _filter_height, |
11058 | _fused_activation_function); |
11059 | } |
11060 | |
11061 | inline DepthwiseConv2DOptionsT *DepthwiseConv2DOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11062 | auto _o = new DepthwiseConv2DOptionsT(); |
11063 | UnPackTo(_o, _resolver); |
11064 | return _o; |
11065 | } |
11066 | |
11067 | inline void DepthwiseConv2DOptions::UnPackTo(DepthwiseConv2DOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11068 | (void)_o; |
11069 | (void)_resolver; |
11070 | { auto _e = padding(); _o->padding = _e; } |
11071 | { auto _e = stride_w(); _o->stride_w = _e; } |
11072 | { auto _e = stride_h(); _o->stride_h = _e; } |
11073 | { auto _e = depth_multiplier(); _o->depth_multiplier = _e; } |
11074 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11075 | { auto _e = dilation_w_factor(); _o->dilation_w_factor = _e; } |
11076 | { auto _e = dilation_h_factor(); _o->dilation_h_factor = _e; } |
11077 | } |
11078 | |
11079 | inline flatbuffers::Offset<DepthwiseConv2DOptions> DepthwiseConv2DOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const DepthwiseConv2DOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11080 | return CreateDepthwiseConv2DOptions(_fbb, _o, _rehasher); |
11081 | } |
11082 | |
11083 | inline flatbuffers::Offset<DepthwiseConv2DOptions> CreateDepthwiseConv2DOptions(flatbuffers::FlatBufferBuilder &_fbb, const DepthwiseConv2DOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11084 | (void)_rehasher; |
11085 | (void)_o; |
11086 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const DepthwiseConv2DOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11087 | auto _padding = _o->padding; |
11088 | auto _stride_w = _o->stride_w; |
11089 | auto _stride_h = _o->stride_h; |
11090 | auto _depth_multiplier = _o->depth_multiplier; |
11091 | auto _fused_activation_function = _o->fused_activation_function; |
11092 | auto _dilation_w_factor = _o->dilation_w_factor; |
11093 | auto _dilation_h_factor = _o->dilation_h_factor; |
11094 | return tflite::CreateDepthwiseConv2DOptions( |
11095 | _fbb, |
11096 | _padding, |
11097 | _stride_w, |
11098 | _stride_h, |
11099 | _depth_multiplier, |
11100 | _fused_activation_function, |
11101 | _dilation_w_factor, |
11102 | _dilation_h_factor); |
11103 | } |
11104 | |
11105 | inline ConcatEmbeddingsOptionsT *ConcatEmbeddingsOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11106 | auto _o = new ConcatEmbeddingsOptionsT(); |
11107 | UnPackTo(_o, _resolver); |
11108 | return _o; |
11109 | } |
11110 | |
11111 | inline void ConcatEmbeddingsOptions::UnPackTo(ConcatEmbeddingsOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11112 | (void)_o; |
11113 | (void)_resolver; |
11114 | { auto _e = num_channels(); _o->num_channels = _e; } |
11115 | { auto _e = num_columns_per_channel(); if (_e) { _o->num_columns_per_channel.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->num_columns_per_channel[_i] = _e->Get(_i); } } } |
11116 | { auto _e = embedding_dim_per_channel(); if (_e) { _o->embedding_dim_per_channel.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->embedding_dim_per_channel[_i] = _e->Get(_i); } } } |
11117 | } |
11118 | |
11119 | inline flatbuffers::Offset<ConcatEmbeddingsOptions> ConcatEmbeddingsOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ConcatEmbeddingsOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11120 | return CreateConcatEmbeddingsOptions(_fbb, _o, _rehasher); |
11121 | } |
11122 | |
11123 | inline flatbuffers::Offset<ConcatEmbeddingsOptions> CreateConcatEmbeddingsOptions(flatbuffers::FlatBufferBuilder &_fbb, const ConcatEmbeddingsOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11124 | (void)_rehasher; |
11125 | (void)_o; |
11126 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ConcatEmbeddingsOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11127 | auto _num_channels = _o->num_channels; |
11128 | auto _num_columns_per_channel = _o->num_columns_per_channel.size() ? _fbb.CreateVector(_o->num_columns_per_channel) : 0; |
11129 | auto _embedding_dim_per_channel = _o->embedding_dim_per_channel.size() ? _fbb.CreateVector(_o->embedding_dim_per_channel) : 0; |
11130 | return tflite::CreateConcatEmbeddingsOptions( |
11131 | _fbb, |
11132 | _num_channels, |
11133 | _num_columns_per_channel, |
11134 | _embedding_dim_per_channel); |
11135 | } |
11136 | |
11137 | inline LSHProjectionOptionsT *LSHProjectionOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11138 | auto _o = new LSHProjectionOptionsT(); |
11139 | UnPackTo(_o, _resolver); |
11140 | return _o; |
11141 | } |
11142 | |
11143 | inline void LSHProjectionOptions::UnPackTo(LSHProjectionOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11144 | (void)_o; |
11145 | (void)_resolver; |
11146 | { auto _e = type(); _o->type = _e; } |
11147 | } |
11148 | |
11149 | inline flatbuffers::Offset<LSHProjectionOptions> LSHProjectionOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LSHProjectionOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11150 | return CreateLSHProjectionOptions(_fbb, _o, _rehasher); |
11151 | } |
11152 | |
11153 | inline flatbuffers::Offset<LSHProjectionOptions> CreateLSHProjectionOptions(flatbuffers::FlatBufferBuilder &_fbb, const LSHProjectionOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11154 | (void)_rehasher; |
11155 | (void)_o; |
11156 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LSHProjectionOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11157 | auto _type = _o->type; |
11158 | return tflite::CreateLSHProjectionOptions( |
11159 | _fbb, |
11160 | _type); |
11161 | } |
11162 | |
11163 | inline SVDFOptionsT *SVDFOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11164 | auto _o = new SVDFOptionsT(); |
11165 | UnPackTo(_o, _resolver); |
11166 | return _o; |
11167 | } |
11168 | |
11169 | inline void SVDFOptions::UnPackTo(SVDFOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11170 | (void)_o; |
11171 | (void)_resolver; |
11172 | { auto _e = rank(); _o->rank = _e; } |
11173 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11174 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11175 | } |
11176 | |
11177 | inline flatbuffers::Offset<SVDFOptions> SVDFOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SVDFOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11178 | return CreateSVDFOptions(_fbb, _o, _rehasher); |
11179 | } |
11180 | |
11181 | inline flatbuffers::Offset<SVDFOptions> CreateSVDFOptions(flatbuffers::FlatBufferBuilder &_fbb, const SVDFOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11182 | (void)_rehasher; |
11183 | (void)_o; |
11184 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SVDFOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11185 | auto _rank = _o->rank; |
11186 | auto _fused_activation_function = _o->fused_activation_function; |
11187 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11188 | return tflite::CreateSVDFOptions( |
11189 | _fbb, |
11190 | _rank, |
11191 | _fused_activation_function, |
11192 | _asymmetric_quantize_inputs); |
11193 | } |
11194 | |
11195 | inline RNNOptionsT *RNNOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11196 | auto _o = new RNNOptionsT(); |
11197 | UnPackTo(_o, _resolver); |
11198 | return _o; |
11199 | } |
11200 | |
11201 | inline void RNNOptions::UnPackTo(RNNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11202 | (void)_o; |
11203 | (void)_resolver; |
11204 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11205 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11206 | } |
11207 | |
11208 | inline flatbuffers::Offset<RNNOptions> RNNOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const RNNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11209 | return CreateRNNOptions(_fbb, _o, _rehasher); |
11210 | } |
11211 | |
11212 | inline flatbuffers::Offset<RNNOptions> CreateRNNOptions(flatbuffers::FlatBufferBuilder &_fbb, const RNNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11213 | (void)_rehasher; |
11214 | (void)_o; |
11215 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const RNNOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11216 | auto _fused_activation_function = _o->fused_activation_function; |
11217 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11218 | return tflite::CreateRNNOptions( |
11219 | _fbb, |
11220 | _fused_activation_function, |
11221 | _asymmetric_quantize_inputs); |
11222 | } |
11223 | |
11224 | inline SequenceRNNOptionsT *SequenceRNNOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11225 | auto _o = new SequenceRNNOptionsT(); |
11226 | UnPackTo(_o, _resolver); |
11227 | return _o; |
11228 | } |
11229 | |
11230 | inline void SequenceRNNOptions::UnPackTo(SequenceRNNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11231 | (void)_o; |
11232 | (void)_resolver; |
11233 | { auto _e = time_major(); _o->time_major = _e; } |
11234 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11235 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11236 | } |
11237 | |
11238 | inline flatbuffers::Offset<SequenceRNNOptions> SequenceRNNOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SequenceRNNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11239 | return CreateSequenceRNNOptions(_fbb, _o, _rehasher); |
11240 | } |
11241 | |
11242 | inline flatbuffers::Offset<SequenceRNNOptions> CreateSequenceRNNOptions(flatbuffers::FlatBufferBuilder &_fbb, const SequenceRNNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11243 | (void)_rehasher; |
11244 | (void)_o; |
11245 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SequenceRNNOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11246 | auto _time_major = _o->time_major; |
11247 | auto _fused_activation_function = _o->fused_activation_function; |
11248 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11249 | return tflite::CreateSequenceRNNOptions( |
11250 | _fbb, |
11251 | _time_major, |
11252 | _fused_activation_function, |
11253 | _asymmetric_quantize_inputs); |
11254 | } |
11255 | |
11256 | inline BidirectionalSequenceRNNOptionsT *BidirectionalSequenceRNNOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11257 | auto _o = new BidirectionalSequenceRNNOptionsT(); |
11258 | UnPackTo(_o, _resolver); |
11259 | return _o; |
11260 | } |
11261 | |
11262 | inline void BidirectionalSequenceRNNOptions::UnPackTo(BidirectionalSequenceRNNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11263 | (void)_o; |
11264 | (void)_resolver; |
11265 | { auto _e = time_major(); _o->time_major = _e; } |
11266 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11267 | { auto _e = merge_outputs(); _o->merge_outputs = _e; } |
11268 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11269 | } |
11270 | |
11271 | inline flatbuffers::Offset<BidirectionalSequenceRNNOptions> BidirectionalSequenceRNNOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceRNNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11272 | return CreateBidirectionalSequenceRNNOptions(_fbb, _o, _rehasher); |
11273 | } |
11274 | |
11275 | inline flatbuffers::Offset<BidirectionalSequenceRNNOptions> CreateBidirectionalSequenceRNNOptions(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceRNNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11276 | (void)_rehasher; |
11277 | (void)_o; |
11278 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const BidirectionalSequenceRNNOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11279 | auto _time_major = _o->time_major; |
11280 | auto _fused_activation_function = _o->fused_activation_function; |
11281 | auto _merge_outputs = _o->merge_outputs; |
11282 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11283 | return tflite::CreateBidirectionalSequenceRNNOptions( |
11284 | _fbb, |
11285 | _time_major, |
11286 | _fused_activation_function, |
11287 | _merge_outputs, |
11288 | _asymmetric_quantize_inputs); |
11289 | } |
11290 | |
11291 | inline FullyConnectedOptionsT *FullyConnectedOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11292 | auto _o = new FullyConnectedOptionsT(); |
11293 | UnPackTo(_o, _resolver); |
11294 | return _o; |
11295 | } |
11296 | |
11297 | inline void FullyConnectedOptions::UnPackTo(FullyConnectedOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11298 | (void)_o; |
11299 | (void)_resolver; |
11300 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11301 | { auto _e = weights_format(); _o->weights_format = _e; } |
11302 | { auto _e = keep_num_dims(); _o->keep_num_dims = _e; } |
11303 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11304 | } |
11305 | |
11306 | inline flatbuffers::Offset<FullyConnectedOptions> FullyConnectedOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const FullyConnectedOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11307 | return CreateFullyConnectedOptions(_fbb, _o, _rehasher); |
11308 | } |
11309 | |
11310 | inline flatbuffers::Offset<FullyConnectedOptions> CreateFullyConnectedOptions(flatbuffers::FlatBufferBuilder &_fbb, const FullyConnectedOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11311 | (void)_rehasher; |
11312 | (void)_o; |
11313 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const FullyConnectedOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11314 | auto _fused_activation_function = _o->fused_activation_function; |
11315 | auto _weights_format = _o->weights_format; |
11316 | auto _keep_num_dims = _o->keep_num_dims; |
11317 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11318 | return tflite::CreateFullyConnectedOptions( |
11319 | _fbb, |
11320 | _fused_activation_function, |
11321 | _weights_format, |
11322 | _keep_num_dims, |
11323 | _asymmetric_quantize_inputs); |
11324 | } |
11325 | |
11326 | inline SoftmaxOptionsT *SoftmaxOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11327 | auto _o = new SoftmaxOptionsT(); |
11328 | UnPackTo(_o, _resolver); |
11329 | return _o; |
11330 | } |
11331 | |
11332 | inline void SoftmaxOptions::UnPackTo(SoftmaxOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11333 | (void)_o; |
11334 | (void)_resolver; |
11335 | { auto _e = beta(); _o->beta = _e; } |
11336 | } |
11337 | |
11338 | inline flatbuffers::Offset<SoftmaxOptions> SoftmaxOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SoftmaxOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11339 | return CreateSoftmaxOptions(_fbb, _o, _rehasher); |
11340 | } |
11341 | |
11342 | inline flatbuffers::Offset<SoftmaxOptions> CreateSoftmaxOptions(flatbuffers::FlatBufferBuilder &_fbb, const SoftmaxOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11343 | (void)_rehasher; |
11344 | (void)_o; |
11345 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SoftmaxOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11346 | auto _beta = _o->beta; |
11347 | return tflite::CreateSoftmaxOptions( |
11348 | _fbb, |
11349 | _beta); |
11350 | } |
11351 | |
11352 | inline ConcatenationOptionsT *ConcatenationOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11353 | auto _o = new ConcatenationOptionsT(); |
11354 | UnPackTo(_o, _resolver); |
11355 | return _o; |
11356 | } |
11357 | |
11358 | inline void ConcatenationOptions::UnPackTo(ConcatenationOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11359 | (void)_o; |
11360 | (void)_resolver; |
11361 | { auto _e = axis(); _o->axis = _e; } |
11362 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11363 | } |
11364 | |
11365 | inline flatbuffers::Offset<ConcatenationOptions> ConcatenationOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ConcatenationOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11366 | return CreateConcatenationOptions(_fbb, _o, _rehasher); |
11367 | } |
11368 | |
11369 | inline flatbuffers::Offset<ConcatenationOptions> CreateConcatenationOptions(flatbuffers::FlatBufferBuilder &_fbb, const ConcatenationOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11370 | (void)_rehasher; |
11371 | (void)_o; |
11372 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ConcatenationOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11373 | auto _axis = _o->axis; |
11374 | auto _fused_activation_function = _o->fused_activation_function; |
11375 | return tflite::CreateConcatenationOptions( |
11376 | _fbb, |
11377 | _axis, |
11378 | _fused_activation_function); |
11379 | } |
11380 | |
11381 | inline AddOptionsT *AddOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11382 | auto _o = new AddOptionsT(); |
11383 | UnPackTo(_o, _resolver); |
11384 | return _o; |
11385 | } |
11386 | |
11387 | inline void AddOptions::UnPackTo(AddOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11388 | (void)_o; |
11389 | (void)_resolver; |
11390 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11391 | } |
11392 | |
11393 | inline flatbuffers::Offset<AddOptions> AddOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AddOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11394 | return CreateAddOptions(_fbb, _o, _rehasher); |
11395 | } |
11396 | |
11397 | inline flatbuffers::Offset<AddOptions> CreateAddOptions(flatbuffers::FlatBufferBuilder &_fbb, const AddOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11398 | (void)_rehasher; |
11399 | (void)_o; |
11400 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AddOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11401 | auto _fused_activation_function = _o->fused_activation_function; |
11402 | return tflite::CreateAddOptions( |
11403 | _fbb, |
11404 | _fused_activation_function); |
11405 | } |
11406 | |
11407 | inline MulOptionsT *MulOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11408 | auto _o = new MulOptionsT(); |
11409 | UnPackTo(_o, _resolver); |
11410 | return _o; |
11411 | } |
11412 | |
11413 | inline void MulOptions::UnPackTo(MulOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11414 | (void)_o; |
11415 | (void)_resolver; |
11416 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11417 | } |
11418 | |
11419 | inline flatbuffers::Offset<MulOptions> MulOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const MulOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11420 | return CreateMulOptions(_fbb, _o, _rehasher); |
11421 | } |
11422 | |
11423 | inline flatbuffers::Offset<MulOptions> CreateMulOptions(flatbuffers::FlatBufferBuilder &_fbb, const MulOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11424 | (void)_rehasher; |
11425 | (void)_o; |
11426 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const MulOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11427 | auto _fused_activation_function = _o->fused_activation_function; |
11428 | return tflite::CreateMulOptions( |
11429 | _fbb, |
11430 | _fused_activation_function); |
11431 | } |
11432 | |
11433 | inline L2NormOptionsT *L2NormOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11434 | auto _o = new L2NormOptionsT(); |
11435 | UnPackTo(_o, _resolver); |
11436 | return _o; |
11437 | } |
11438 | |
11439 | inline void L2NormOptions::UnPackTo(L2NormOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11440 | (void)_o; |
11441 | (void)_resolver; |
11442 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11443 | } |
11444 | |
11445 | inline flatbuffers::Offset<L2NormOptions> L2NormOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const L2NormOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11446 | return CreateL2NormOptions(_fbb, _o, _rehasher); |
11447 | } |
11448 | |
11449 | inline flatbuffers::Offset<L2NormOptions> CreateL2NormOptions(flatbuffers::FlatBufferBuilder &_fbb, const L2NormOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11450 | (void)_rehasher; |
11451 | (void)_o; |
11452 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const L2NormOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11453 | auto _fused_activation_function = _o->fused_activation_function; |
11454 | return tflite::CreateL2NormOptions( |
11455 | _fbb, |
11456 | _fused_activation_function); |
11457 | } |
11458 | |
11459 | inline LocalResponseNormalizationOptionsT *LocalResponseNormalizationOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11460 | auto _o = new LocalResponseNormalizationOptionsT(); |
11461 | UnPackTo(_o, _resolver); |
11462 | return _o; |
11463 | } |
11464 | |
11465 | inline void LocalResponseNormalizationOptions::UnPackTo(LocalResponseNormalizationOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11466 | (void)_o; |
11467 | (void)_resolver; |
11468 | { auto _e = radius(); _o->radius = _e; } |
11469 | { auto _e = bias(); _o->bias = _e; } |
11470 | { auto _e = alpha(); _o->alpha = _e; } |
11471 | { auto _e = beta(); _o->beta = _e; } |
11472 | } |
11473 | |
11474 | inline flatbuffers::Offset<LocalResponseNormalizationOptions> LocalResponseNormalizationOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LocalResponseNormalizationOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11475 | return CreateLocalResponseNormalizationOptions(_fbb, _o, _rehasher); |
11476 | } |
11477 | |
11478 | inline flatbuffers::Offset<LocalResponseNormalizationOptions> CreateLocalResponseNormalizationOptions(flatbuffers::FlatBufferBuilder &_fbb, const LocalResponseNormalizationOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11479 | (void)_rehasher; |
11480 | (void)_o; |
11481 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LocalResponseNormalizationOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11482 | auto _radius = _o->radius; |
11483 | auto _bias = _o->bias; |
11484 | auto _alpha = _o->alpha; |
11485 | auto _beta = _o->beta; |
11486 | return tflite::CreateLocalResponseNormalizationOptions( |
11487 | _fbb, |
11488 | _radius, |
11489 | _bias, |
11490 | _alpha, |
11491 | _beta); |
11492 | } |
11493 | |
11494 | inline LSTMOptionsT *LSTMOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11495 | auto _o = new LSTMOptionsT(); |
11496 | UnPackTo(_o, _resolver); |
11497 | return _o; |
11498 | } |
11499 | |
11500 | inline void LSTMOptions::UnPackTo(LSTMOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11501 | (void)_o; |
11502 | (void)_resolver; |
11503 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11504 | { auto _e = cell_clip(); _o->cell_clip = _e; } |
11505 | { auto _e = proj_clip(); _o->proj_clip = _e; } |
11506 | { auto _e = kernel_type(); _o->kernel_type = _e; } |
11507 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11508 | } |
11509 | |
11510 | inline flatbuffers::Offset<LSTMOptions> LSTMOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LSTMOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11511 | return CreateLSTMOptions(_fbb, _o, _rehasher); |
11512 | } |
11513 | |
11514 | inline flatbuffers::Offset<LSTMOptions> CreateLSTMOptions(flatbuffers::FlatBufferBuilder &_fbb, const LSTMOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11515 | (void)_rehasher; |
11516 | (void)_o; |
11517 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LSTMOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11518 | auto _fused_activation_function = _o->fused_activation_function; |
11519 | auto _cell_clip = _o->cell_clip; |
11520 | auto _proj_clip = _o->proj_clip; |
11521 | auto _kernel_type = _o->kernel_type; |
11522 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11523 | return tflite::CreateLSTMOptions( |
11524 | _fbb, |
11525 | _fused_activation_function, |
11526 | _cell_clip, |
11527 | _proj_clip, |
11528 | _kernel_type, |
11529 | _asymmetric_quantize_inputs); |
11530 | } |
11531 | |
11532 | inline UnidirectionalSequenceLSTMOptionsT *UnidirectionalSequenceLSTMOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11533 | auto _o = new UnidirectionalSequenceLSTMOptionsT(); |
11534 | UnPackTo(_o, _resolver); |
11535 | return _o; |
11536 | } |
11537 | |
11538 | inline void UnidirectionalSequenceLSTMOptions::UnPackTo(UnidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11539 | (void)_o; |
11540 | (void)_resolver; |
11541 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11542 | { auto _e = cell_clip(); _o->cell_clip = _e; } |
11543 | { auto _e = proj_clip(); _o->proj_clip = _e; } |
11544 | { auto _e = time_major(); _o->time_major = _e; } |
11545 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11546 | } |
11547 | |
11548 | inline flatbuffers::Offset<UnidirectionalSequenceLSTMOptions> UnidirectionalSequenceLSTMOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const UnidirectionalSequenceLSTMOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11549 | return CreateUnidirectionalSequenceLSTMOptions(_fbb, _o, _rehasher); |
11550 | } |
11551 | |
11552 | inline flatbuffers::Offset<UnidirectionalSequenceLSTMOptions> CreateUnidirectionalSequenceLSTMOptions(flatbuffers::FlatBufferBuilder &_fbb, const UnidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11553 | (void)_rehasher; |
11554 | (void)_o; |
11555 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const UnidirectionalSequenceLSTMOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11556 | auto _fused_activation_function = _o->fused_activation_function; |
11557 | auto _cell_clip = _o->cell_clip; |
11558 | auto _proj_clip = _o->proj_clip; |
11559 | auto _time_major = _o->time_major; |
11560 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11561 | return tflite::CreateUnidirectionalSequenceLSTMOptions( |
11562 | _fbb, |
11563 | _fused_activation_function, |
11564 | _cell_clip, |
11565 | _proj_clip, |
11566 | _time_major, |
11567 | _asymmetric_quantize_inputs); |
11568 | } |
11569 | |
11570 | inline BidirectionalSequenceLSTMOptionsT *BidirectionalSequenceLSTMOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11571 | auto _o = new BidirectionalSequenceLSTMOptionsT(); |
11572 | UnPackTo(_o, _resolver); |
11573 | return _o; |
11574 | } |
11575 | |
11576 | inline void BidirectionalSequenceLSTMOptions::UnPackTo(BidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11577 | (void)_o; |
11578 | (void)_resolver; |
11579 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11580 | { auto _e = cell_clip(); _o->cell_clip = _e; } |
11581 | { auto _e = proj_clip(); _o->proj_clip = _e; } |
11582 | { auto _e = merge_outputs(); _o->merge_outputs = _e; } |
11583 | { auto _e = time_major(); _o->time_major = _e; } |
11584 | { auto _e = asymmetric_quantize_inputs(); _o->asymmetric_quantize_inputs = _e; } |
11585 | } |
11586 | |
11587 | inline flatbuffers::Offset<BidirectionalSequenceLSTMOptions> BidirectionalSequenceLSTMOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceLSTMOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11588 | return CreateBidirectionalSequenceLSTMOptions(_fbb, _o, _rehasher); |
11589 | } |
11590 | |
11591 | inline flatbuffers::Offset<BidirectionalSequenceLSTMOptions> CreateBidirectionalSequenceLSTMOptions(flatbuffers::FlatBufferBuilder &_fbb, const BidirectionalSequenceLSTMOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11592 | (void)_rehasher; |
11593 | (void)_o; |
11594 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const BidirectionalSequenceLSTMOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11595 | auto _fused_activation_function = _o->fused_activation_function; |
11596 | auto _cell_clip = _o->cell_clip; |
11597 | auto _proj_clip = _o->proj_clip; |
11598 | auto _merge_outputs = _o->merge_outputs; |
11599 | auto _time_major = _o->time_major; |
11600 | auto _asymmetric_quantize_inputs = _o->asymmetric_quantize_inputs; |
11601 | return tflite::CreateBidirectionalSequenceLSTMOptions( |
11602 | _fbb, |
11603 | _fused_activation_function, |
11604 | _cell_clip, |
11605 | _proj_clip, |
11606 | _merge_outputs, |
11607 | _time_major, |
11608 | _asymmetric_quantize_inputs); |
11609 | } |
11610 | |
11611 | inline ResizeBilinearOptionsT *ResizeBilinearOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11612 | auto _o = new ResizeBilinearOptionsT(); |
11613 | UnPackTo(_o, _resolver); |
11614 | return _o; |
11615 | } |
11616 | |
11617 | inline void ResizeBilinearOptions::UnPackTo(ResizeBilinearOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11618 | (void)_o; |
11619 | (void)_resolver; |
11620 | { auto _e = align_corners(); _o->align_corners = _e; } |
11621 | { auto _e = half_pixel_centers(); _o->half_pixel_centers = _e; } |
11622 | } |
11623 | |
11624 | inline flatbuffers::Offset<ResizeBilinearOptions> ResizeBilinearOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ResizeBilinearOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11625 | return CreateResizeBilinearOptions(_fbb, _o, _rehasher); |
11626 | } |
11627 | |
11628 | inline flatbuffers::Offset<ResizeBilinearOptions> CreateResizeBilinearOptions(flatbuffers::FlatBufferBuilder &_fbb, const ResizeBilinearOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11629 | (void)_rehasher; |
11630 | (void)_o; |
11631 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ResizeBilinearOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11632 | auto _align_corners = _o->align_corners; |
11633 | auto _half_pixel_centers = _o->half_pixel_centers; |
11634 | return tflite::CreateResizeBilinearOptions( |
11635 | _fbb, |
11636 | _align_corners, |
11637 | _half_pixel_centers); |
11638 | } |
11639 | |
11640 | inline ResizeNearestNeighborOptionsT *ResizeNearestNeighborOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11641 | auto _o = new ResizeNearestNeighborOptionsT(); |
11642 | UnPackTo(_o, _resolver); |
11643 | return _o; |
11644 | } |
11645 | |
11646 | inline void ResizeNearestNeighborOptions::UnPackTo(ResizeNearestNeighborOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11647 | (void)_o; |
11648 | (void)_resolver; |
11649 | { auto _e = align_corners(); _o->align_corners = _e; } |
11650 | { auto _e = half_pixel_centers(); _o->half_pixel_centers = _e; } |
11651 | } |
11652 | |
11653 | inline flatbuffers::Offset<ResizeNearestNeighborOptions> ResizeNearestNeighborOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ResizeNearestNeighborOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11654 | return CreateResizeNearestNeighborOptions(_fbb, _o, _rehasher); |
11655 | } |
11656 | |
11657 | inline flatbuffers::Offset<ResizeNearestNeighborOptions> CreateResizeNearestNeighborOptions(flatbuffers::FlatBufferBuilder &_fbb, const ResizeNearestNeighborOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11658 | (void)_rehasher; |
11659 | (void)_o; |
11660 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ResizeNearestNeighborOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11661 | auto _align_corners = _o->align_corners; |
11662 | auto _half_pixel_centers = _o->half_pixel_centers; |
11663 | return tflite::CreateResizeNearestNeighborOptions( |
11664 | _fbb, |
11665 | _align_corners, |
11666 | _half_pixel_centers); |
11667 | } |
11668 | |
11669 | inline CallOptionsT *CallOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11670 | auto _o = new CallOptionsT(); |
11671 | UnPackTo(_o, _resolver); |
11672 | return _o; |
11673 | } |
11674 | |
11675 | inline void CallOptions::UnPackTo(CallOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11676 | (void)_o; |
11677 | (void)_resolver; |
11678 | { auto _e = subgraph(); _o->subgraph = _e; } |
11679 | } |
11680 | |
11681 | inline flatbuffers::Offset<CallOptions> CallOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const CallOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11682 | return CreateCallOptions(_fbb, _o, _rehasher); |
11683 | } |
11684 | |
11685 | inline flatbuffers::Offset<CallOptions> CreateCallOptions(flatbuffers::FlatBufferBuilder &_fbb, const CallOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11686 | (void)_rehasher; |
11687 | (void)_o; |
11688 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const CallOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11689 | auto _subgraph = _o->subgraph; |
11690 | return tflite::CreateCallOptions( |
11691 | _fbb, |
11692 | _subgraph); |
11693 | } |
11694 | |
11695 | inline PadOptionsT *PadOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11696 | auto _o = new PadOptionsT(); |
11697 | UnPackTo(_o, _resolver); |
11698 | return _o; |
11699 | } |
11700 | |
11701 | inline void PadOptions::UnPackTo(PadOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11702 | (void)_o; |
11703 | (void)_resolver; |
11704 | } |
11705 | |
11706 | inline flatbuffers::Offset<PadOptions> PadOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const PadOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11707 | return CreatePadOptions(_fbb, _o, _rehasher); |
11708 | } |
11709 | |
11710 | inline flatbuffers::Offset<PadOptions> CreatePadOptions(flatbuffers::FlatBufferBuilder &_fbb, const PadOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11711 | (void)_rehasher; |
11712 | (void)_o; |
11713 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const PadOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11714 | return tflite::CreatePadOptions( |
11715 | _fbb); |
11716 | } |
11717 | |
11718 | inline PadV2OptionsT *PadV2Options::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11719 | auto _o = new PadV2OptionsT(); |
11720 | UnPackTo(_o, _resolver); |
11721 | return _o; |
11722 | } |
11723 | |
11724 | inline void PadV2Options::UnPackTo(PadV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11725 | (void)_o; |
11726 | (void)_resolver; |
11727 | } |
11728 | |
11729 | inline flatbuffers::Offset<PadV2Options> PadV2Options::Pack(flatbuffers::FlatBufferBuilder &_fbb, const PadV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11730 | return CreatePadV2Options(_fbb, _o, _rehasher); |
11731 | } |
11732 | |
11733 | inline flatbuffers::Offset<PadV2Options> CreatePadV2Options(flatbuffers::FlatBufferBuilder &_fbb, const PadV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11734 | (void)_rehasher; |
11735 | (void)_o; |
11736 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const PadV2OptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11737 | return tflite::CreatePadV2Options( |
11738 | _fbb); |
11739 | } |
11740 | |
11741 | inline ReshapeOptionsT *ReshapeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11742 | auto _o = new ReshapeOptionsT(); |
11743 | UnPackTo(_o, _resolver); |
11744 | return _o; |
11745 | } |
11746 | |
11747 | inline void ReshapeOptions::UnPackTo(ReshapeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11748 | (void)_o; |
11749 | (void)_resolver; |
11750 | { auto _e = new_shape(); if (_e) { _o->new_shape.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->new_shape[_i] = _e->Get(_i); } } } |
11751 | } |
11752 | |
11753 | inline flatbuffers::Offset<ReshapeOptions> ReshapeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReshapeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11754 | return CreateReshapeOptions(_fbb, _o, _rehasher); |
11755 | } |
11756 | |
11757 | inline flatbuffers::Offset<ReshapeOptions> CreateReshapeOptions(flatbuffers::FlatBufferBuilder &_fbb, const ReshapeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11758 | (void)_rehasher; |
11759 | (void)_o; |
11760 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ReshapeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11761 | auto _new_shape = _o->new_shape.size() ? _fbb.CreateVector(_o->new_shape) : 0; |
11762 | return tflite::CreateReshapeOptions( |
11763 | _fbb, |
11764 | _new_shape); |
11765 | } |
11766 | |
11767 | inline SpaceToBatchNDOptionsT *SpaceToBatchNDOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11768 | auto _o = new SpaceToBatchNDOptionsT(); |
11769 | UnPackTo(_o, _resolver); |
11770 | return _o; |
11771 | } |
11772 | |
11773 | inline void SpaceToBatchNDOptions::UnPackTo(SpaceToBatchNDOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11774 | (void)_o; |
11775 | (void)_resolver; |
11776 | } |
11777 | |
11778 | inline flatbuffers::Offset<SpaceToBatchNDOptions> SpaceToBatchNDOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToBatchNDOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11779 | return CreateSpaceToBatchNDOptions(_fbb, _o, _rehasher); |
11780 | } |
11781 | |
11782 | inline flatbuffers::Offset<SpaceToBatchNDOptions> CreateSpaceToBatchNDOptions(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToBatchNDOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11783 | (void)_rehasher; |
11784 | (void)_o; |
11785 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SpaceToBatchNDOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11786 | return tflite::CreateSpaceToBatchNDOptions( |
11787 | _fbb); |
11788 | } |
11789 | |
11790 | inline BatchToSpaceNDOptionsT *BatchToSpaceNDOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11791 | auto _o = new BatchToSpaceNDOptionsT(); |
11792 | UnPackTo(_o, _resolver); |
11793 | return _o; |
11794 | } |
11795 | |
11796 | inline void BatchToSpaceNDOptions::UnPackTo(BatchToSpaceNDOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11797 | (void)_o; |
11798 | (void)_resolver; |
11799 | } |
11800 | |
11801 | inline flatbuffers::Offset<BatchToSpaceNDOptions> BatchToSpaceNDOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const BatchToSpaceNDOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11802 | return CreateBatchToSpaceNDOptions(_fbb, _o, _rehasher); |
11803 | } |
11804 | |
11805 | inline flatbuffers::Offset<BatchToSpaceNDOptions> CreateBatchToSpaceNDOptions(flatbuffers::FlatBufferBuilder &_fbb, const BatchToSpaceNDOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11806 | (void)_rehasher; |
11807 | (void)_o; |
11808 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const BatchToSpaceNDOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11809 | return tflite::CreateBatchToSpaceNDOptions( |
11810 | _fbb); |
11811 | } |
11812 | |
11813 | inline SkipGramOptionsT *SkipGramOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11814 | auto _o = new SkipGramOptionsT(); |
11815 | UnPackTo(_o, _resolver); |
11816 | return _o; |
11817 | } |
11818 | |
11819 | inline void SkipGramOptions::UnPackTo(SkipGramOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11820 | (void)_o; |
11821 | (void)_resolver; |
11822 | { auto _e = ngram_size(); _o->ngram_size = _e; } |
11823 | { auto _e = max_skip_size(); _o->max_skip_size = _e; } |
11824 | { auto _e = include_all_ngrams(); _o->include_all_ngrams = _e; } |
11825 | } |
11826 | |
11827 | inline flatbuffers::Offset<SkipGramOptions> SkipGramOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SkipGramOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11828 | return CreateSkipGramOptions(_fbb, _o, _rehasher); |
11829 | } |
11830 | |
11831 | inline flatbuffers::Offset<SkipGramOptions> CreateSkipGramOptions(flatbuffers::FlatBufferBuilder &_fbb, const SkipGramOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11832 | (void)_rehasher; |
11833 | (void)_o; |
11834 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SkipGramOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11835 | auto _ngram_size = _o->ngram_size; |
11836 | auto _max_skip_size = _o->max_skip_size; |
11837 | auto _include_all_ngrams = _o->include_all_ngrams; |
11838 | return tflite::CreateSkipGramOptions( |
11839 | _fbb, |
11840 | _ngram_size, |
11841 | _max_skip_size, |
11842 | _include_all_ngrams); |
11843 | } |
11844 | |
11845 | inline SpaceToDepthOptionsT *SpaceToDepthOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11846 | auto _o = new SpaceToDepthOptionsT(); |
11847 | UnPackTo(_o, _resolver); |
11848 | return _o; |
11849 | } |
11850 | |
11851 | inline void SpaceToDepthOptions::UnPackTo(SpaceToDepthOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11852 | (void)_o; |
11853 | (void)_resolver; |
11854 | { auto _e = block_size(); _o->block_size = _e; } |
11855 | } |
11856 | |
11857 | inline flatbuffers::Offset<SpaceToDepthOptions> SpaceToDepthOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToDepthOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11858 | return CreateSpaceToDepthOptions(_fbb, _o, _rehasher); |
11859 | } |
11860 | |
11861 | inline flatbuffers::Offset<SpaceToDepthOptions> CreateSpaceToDepthOptions(flatbuffers::FlatBufferBuilder &_fbb, const SpaceToDepthOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11862 | (void)_rehasher; |
11863 | (void)_o; |
11864 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SpaceToDepthOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11865 | auto _block_size = _o->block_size; |
11866 | return tflite::CreateSpaceToDepthOptions( |
11867 | _fbb, |
11868 | _block_size); |
11869 | } |
11870 | |
11871 | inline DepthToSpaceOptionsT *DepthToSpaceOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11872 | auto _o = new DepthToSpaceOptionsT(); |
11873 | UnPackTo(_o, _resolver); |
11874 | return _o; |
11875 | } |
11876 | |
11877 | inline void DepthToSpaceOptions::UnPackTo(DepthToSpaceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11878 | (void)_o; |
11879 | (void)_resolver; |
11880 | { auto _e = block_size(); _o->block_size = _e; } |
11881 | } |
11882 | |
11883 | inline flatbuffers::Offset<DepthToSpaceOptions> DepthToSpaceOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const DepthToSpaceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11884 | return CreateDepthToSpaceOptions(_fbb, _o, _rehasher); |
11885 | } |
11886 | |
11887 | inline flatbuffers::Offset<DepthToSpaceOptions> CreateDepthToSpaceOptions(flatbuffers::FlatBufferBuilder &_fbb, const DepthToSpaceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11888 | (void)_rehasher; |
11889 | (void)_o; |
11890 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const DepthToSpaceOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11891 | auto _block_size = _o->block_size; |
11892 | return tflite::CreateDepthToSpaceOptions( |
11893 | _fbb, |
11894 | _block_size); |
11895 | } |
11896 | |
11897 | inline SubOptionsT *SubOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11898 | auto _o = new SubOptionsT(); |
11899 | UnPackTo(_o, _resolver); |
11900 | return _o; |
11901 | } |
11902 | |
11903 | inline void SubOptions::UnPackTo(SubOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11904 | (void)_o; |
11905 | (void)_resolver; |
11906 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11907 | } |
11908 | |
11909 | inline flatbuffers::Offset<SubOptions> SubOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SubOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11910 | return CreateSubOptions(_fbb, _o, _rehasher); |
11911 | } |
11912 | |
11913 | inline flatbuffers::Offset<SubOptions> CreateSubOptions(flatbuffers::FlatBufferBuilder &_fbb, const SubOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11914 | (void)_rehasher; |
11915 | (void)_o; |
11916 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SubOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11917 | auto _fused_activation_function = _o->fused_activation_function; |
11918 | return tflite::CreateSubOptions( |
11919 | _fbb, |
11920 | _fused_activation_function); |
11921 | } |
11922 | |
11923 | inline DivOptionsT *DivOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11924 | auto _o = new DivOptionsT(); |
11925 | UnPackTo(_o, _resolver); |
11926 | return _o; |
11927 | } |
11928 | |
11929 | inline void DivOptions::UnPackTo(DivOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11930 | (void)_o; |
11931 | (void)_resolver; |
11932 | { auto _e = fused_activation_function(); _o->fused_activation_function = _e; } |
11933 | } |
11934 | |
11935 | inline flatbuffers::Offset<DivOptions> DivOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const DivOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11936 | return CreateDivOptions(_fbb, _o, _rehasher); |
11937 | } |
11938 | |
11939 | inline flatbuffers::Offset<DivOptions> CreateDivOptions(flatbuffers::FlatBufferBuilder &_fbb, const DivOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11940 | (void)_rehasher; |
11941 | (void)_o; |
11942 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const DivOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11943 | auto _fused_activation_function = _o->fused_activation_function; |
11944 | return tflite::CreateDivOptions( |
11945 | _fbb, |
11946 | _fused_activation_function); |
11947 | } |
11948 | |
11949 | inline TopKV2OptionsT *TopKV2Options::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11950 | auto _o = new TopKV2OptionsT(); |
11951 | UnPackTo(_o, _resolver); |
11952 | return _o; |
11953 | } |
11954 | |
11955 | inline void TopKV2Options::UnPackTo(TopKV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11956 | (void)_o; |
11957 | (void)_resolver; |
11958 | } |
11959 | |
11960 | inline flatbuffers::Offset<TopKV2Options> TopKV2Options::Pack(flatbuffers::FlatBufferBuilder &_fbb, const TopKV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11961 | return CreateTopKV2Options(_fbb, _o, _rehasher); |
11962 | } |
11963 | |
11964 | inline flatbuffers::Offset<TopKV2Options> CreateTopKV2Options(flatbuffers::FlatBufferBuilder &_fbb, const TopKV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11965 | (void)_rehasher; |
11966 | (void)_o; |
11967 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const TopKV2OptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11968 | return tflite::CreateTopKV2Options( |
11969 | _fbb); |
11970 | } |
11971 | |
11972 | inline EmbeddingLookupSparseOptionsT *EmbeddingLookupSparseOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11973 | auto _o = new EmbeddingLookupSparseOptionsT(); |
11974 | UnPackTo(_o, _resolver); |
11975 | return _o; |
11976 | } |
11977 | |
11978 | inline void EmbeddingLookupSparseOptions::UnPackTo(EmbeddingLookupSparseOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
11979 | (void)_o; |
11980 | (void)_resolver; |
11981 | { auto _e = combiner(); _o->combiner = _e; } |
11982 | } |
11983 | |
11984 | inline flatbuffers::Offset<EmbeddingLookupSparseOptions> EmbeddingLookupSparseOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const EmbeddingLookupSparseOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
11985 | return CreateEmbeddingLookupSparseOptions(_fbb, _o, _rehasher); |
11986 | } |
11987 | |
11988 | inline flatbuffers::Offset<EmbeddingLookupSparseOptions> CreateEmbeddingLookupSparseOptions(flatbuffers::FlatBufferBuilder &_fbb, const EmbeddingLookupSparseOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
11989 | (void)_rehasher; |
11990 | (void)_o; |
11991 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const EmbeddingLookupSparseOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
11992 | auto _combiner = _o->combiner; |
11993 | return tflite::CreateEmbeddingLookupSparseOptions( |
11994 | _fbb, |
11995 | _combiner); |
11996 | } |
11997 | |
11998 | inline GatherOptionsT *GatherOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
11999 | auto _o = new GatherOptionsT(); |
12000 | UnPackTo(_o, _resolver); |
12001 | return _o; |
12002 | } |
12003 | |
12004 | inline void GatherOptions::UnPackTo(GatherOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12005 | (void)_o; |
12006 | (void)_resolver; |
12007 | { auto _e = axis(); _o->axis = _e; } |
12008 | } |
12009 | |
12010 | inline flatbuffers::Offset<GatherOptions> GatherOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const GatherOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12011 | return CreateGatherOptions(_fbb, _o, _rehasher); |
12012 | } |
12013 | |
12014 | inline flatbuffers::Offset<GatherOptions> CreateGatherOptions(flatbuffers::FlatBufferBuilder &_fbb, const GatherOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12015 | (void)_rehasher; |
12016 | (void)_o; |
12017 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const GatherOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12018 | auto _axis = _o->axis; |
12019 | return tflite::CreateGatherOptions( |
12020 | _fbb, |
12021 | _axis); |
12022 | } |
12023 | |
12024 | inline TransposeOptionsT *TransposeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12025 | auto _o = new TransposeOptionsT(); |
12026 | UnPackTo(_o, _resolver); |
12027 | return _o; |
12028 | } |
12029 | |
12030 | inline void TransposeOptions::UnPackTo(TransposeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12031 | (void)_o; |
12032 | (void)_resolver; |
12033 | } |
12034 | |
12035 | inline flatbuffers::Offset<TransposeOptions> TransposeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const TransposeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12036 | return CreateTransposeOptions(_fbb, _o, _rehasher); |
12037 | } |
12038 | |
12039 | inline flatbuffers::Offset<TransposeOptions> CreateTransposeOptions(flatbuffers::FlatBufferBuilder &_fbb, const TransposeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12040 | (void)_rehasher; |
12041 | (void)_o; |
12042 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const TransposeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12043 | return tflite::CreateTransposeOptions( |
12044 | _fbb); |
12045 | } |
12046 | |
12047 | inline ExpOptionsT *ExpOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12048 | auto _o = new ExpOptionsT(); |
12049 | UnPackTo(_o, _resolver); |
12050 | return _o; |
12051 | } |
12052 | |
12053 | inline void ExpOptions::UnPackTo(ExpOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12054 | (void)_o; |
12055 | (void)_resolver; |
12056 | } |
12057 | |
12058 | inline flatbuffers::Offset<ExpOptions> ExpOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ExpOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12059 | return CreateExpOptions(_fbb, _o, _rehasher); |
12060 | } |
12061 | |
12062 | inline flatbuffers::Offset<ExpOptions> CreateExpOptions(flatbuffers::FlatBufferBuilder &_fbb, const ExpOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12063 | (void)_rehasher; |
12064 | (void)_o; |
12065 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ExpOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12066 | return tflite::CreateExpOptions( |
12067 | _fbb); |
12068 | } |
12069 | |
12070 | inline CosOptionsT *CosOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12071 | auto _o = new CosOptionsT(); |
12072 | UnPackTo(_o, _resolver); |
12073 | return _o; |
12074 | } |
12075 | |
12076 | inline void CosOptions::UnPackTo(CosOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12077 | (void)_o; |
12078 | (void)_resolver; |
12079 | } |
12080 | |
12081 | inline flatbuffers::Offset<CosOptions> CosOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const CosOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12082 | return CreateCosOptions(_fbb, _o, _rehasher); |
12083 | } |
12084 | |
12085 | inline flatbuffers::Offset<CosOptions> CreateCosOptions(flatbuffers::FlatBufferBuilder &_fbb, const CosOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12086 | (void)_rehasher; |
12087 | (void)_o; |
12088 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const CosOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12089 | return tflite::CreateCosOptions( |
12090 | _fbb); |
12091 | } |
12092 | |
12093 | inline ReducerOptionsT *ReducerOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12094 | auto _o = new ReducerOptionsT(); |
12095 | UnPackTo(_o, _resolver); |
12096 | return _o; |
12097 | } |
12098 | |
12099 | inline void ReducerOptions::UnPackTo(ReducerOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12100 | (void)_o; |
12101 | (void)_resolver; |
12102 | { auto _e = keep_dims(); _o->keep_dims = _e; } |
12103 | } |
12104 | |
12105 | inline flatbuffers::Offset<ReducerOptions> ReducerOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReducerOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12106 | return CreateReducerOptions(_fbb, _o, _rehasher); |
12107 | } |
12108 | |
12109 | inline flatbuffers::Offset<ReducerOptions> CreateReducerOptions(flatbuffers::FlatBufferBuilder &_fbb, const ReducerOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12110 | (void)_rehasher; |
12111 | (void)_o; |
12112 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ReducerOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12113 | auto _keep_dims = _o->keep_dims; |
12114 | return tflite::CreateReducerOptions( |
12115 | _fbb, |
12116 | _keep_dims); |
12117 | } |
12118 | |
12119 | inline SqueezeOptionsT *SqueezeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12120 | auto _o = new SqueezeOptionsT(); |
12121 | UnPackTo(_o, _resolver); |
12122 | return _o; |
12123 | } |
12124 | |
12125 | inline void SqueezeOptions::UnPackTo(SqueezeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12126 | (void)_o; |
12127 | (void)_resolver; |
12128 | { auto _e = squeeze_dims(); if (_e) { _o->squeeze_dims.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->squeeze_dims[_i] = _e->Get(_i); } } } |
12129 | } |
12130 | |
12131 | inline flatbuffers::Offset<SqueezeOptions> SqueezeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SqueezeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12132 | return CreateSqueezeOptions(_fbb, _o, _rehasher); |
12133 | } |
12134 | |
12135 | inline flatbuffers::Offset<SqueezeOptions> CreateSqueezeOptions(flatbuffers::FlatBufferBuilder &_fbb, const SqueezeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12136 | (void)_rehasher; |
12137 | (void)_o; |
12138 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SqueezeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12139 | auto _squeeze_dims = _o->squeeze_dims.size() ? _fbb.CreateVector(_o->squeeze_dims) : 0; |
12140 | return tflite::CreateSqueezeOptions( |
12141 | _fbb, |
12142 | _squeeze_dims); |
12143 | } |
12144 | |
12145 | inline SplitOptionsT *SplitOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12146 | auto _o = new SplitOptionsT(); |
12147 | UnPackTo(_o, _resolver); |
12148 | return _o; |
12149 | } |
12150 | |
12151 | inline void SplitOptions::UnPackTo(SplitOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12152 | (void)_o; |
12153 | (void)_resolver; |
12154 | { auto _e = num_splits(); _o->num_splits = _e; } |
12155 | } |
12156 | |
12157 | inline flatbuffers::Offset<SplitOptions> SplitOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SplitOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12158 | return CreateSplitOptions(_fbb, _o, _rehasher); |
12159 | } |
12160 | |
12161 | inline flatbuffers::Offset<SplitOptions> CreateSplitOptions(flatbuffers::FlatBufferBuilder &_fbb, const SplitOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12162 | (void)_rehasher; |
12163 | (void)_o; |
12164 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SplitOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12165 | auto _num_splits = _o->num_splits; |
12166 | return tflite::CreateSplitOptions( |
12167 | _fbb, |
12168 | _num_splits); |
12169 | } |
12170 | |
12171 | inline SplitVOptionsT *SplitVOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12172 | auto _o = new SplitVOptionsT(); |
12173 | UnPackTo(_o, _resolver); |
12174 | return _o; |
12175 | } |
12176 | |
12177 | inline void SplitVOptions::UnPackTo(SplitVOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12178 | (void)_o; |
12179 | (void)_resolver; |
12180 | { auto _e = num_splits(); _o->num_splits = _e; } |
12181 | } |
12182 | |
12183 | inline flatbuffers::Offset<SplitVOptions> SplitVOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SplitVOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12184 | return CreateSplitVOptions(_fbb, _o, _rehasher); |
12185 | } |
12186 | |
12187 | inline flatbuffers::Offset<SplitVOptions> CreateSplitVOptions(flatbuffers::FlatBufferBuilder &_fbb, const SplitVOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12188 | (void)_rehasher; |
12189 | (void)_o; |
12190 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SplitVOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12191 | auto _num_splits = _o->num_splits; |
12192 | return tflite::CreateSplitVOptions( |
12193 | _fbb, |
12194 | _num_splits); |
12195 | } |
12196 | |
12197 | inline StridedSliceOptionsT *StridedSliceOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12198 | auto _o = new StridedSliceOptionsT(); |
12199 | UnPackTo(_o, _resolver); |
12200 | return _o; |
12201 | } |
12202 | |
12203 | inline void StridedSliceOptions::UnPackTo(StridedSliceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12204 | (void)_o; |
12205 | (void)_resolver; |
12206 | { auto _e = begin_mask(); _o->begin_mask = _e; } |
12207 | { auto _e = end_mask(); _o->end_mask = _e; } |
12208 | { auto _e = ellipsis_mask(); _o->ellipsis_mask = _e; } |
12209 | { auto _e = new_axis_mask(); _o->new_axis_mask = _e; } |
12210 | { auto _e = shrink_axis_mask(); _o->shrink_axis_mask = _e; } |
12211 | } |
12212 | |
12213 | inline flatbuffers::Offset<StridedSliceOptions> StridedSliceOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const StridedSliceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12214 | return CreateStridedSliceOptions(_fbb, _o, _rehasher); |
12215 | } |
12216 | |
12217 | inline flatbuffers::Offset<StridedSliceOptions> CreateStridedSliceOptions(flatbuffers::FlatBufferBuilder &_fbb, const StridedSliceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12218 | (void)_rehasher; |
12219 | (void)_o; |
12220 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const StridedSliceOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12221 | auto _begin_mask = _o->begin_mask; |
12222 | auto _end_mask = _o->end_mask; |
12223 | auto _ellipsis_mask = _o->ellipsis_mask; |
12224 | auto _new_axis_mask = _o->new_axis_mask; |
12225 | auto _shrink_axis_mask = _o->shrink_axis_mask; |
12226 | return tflite::CreateStridedSliceOptions( |
12227 | _fbb, |
12228 | _begin_mask, |
12229 | _end_mask, |
12230 | _ellipsis_mask, |
12231 | _new_axis_mask, |
12232 | _shrink_axis_mask); |
12233 | } |
12234 | |
12235 | inline LogSoftmaxOptionsT *LogSoftmaxOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12236 | auto _o = new LogSoftmaxOptionsT(); |
12237 | UnPackTo(_o, _resolver); |
12238 | return _o; |
12239 | } |
12240 | |
12241 | inline void LogSoftmaxOptions::UnPackTo(LogSoftmaxOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12242 | (void)_o; |
12243 | (void)_resolver; |
12244 | } |
12245 | |
12246 | inline flatbuffers::Offset<LogSoftmaxOptions> LogSoftmaxOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogSoftmaxOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12247 | return CreateLogSoftmaxOptions(_fbb, _o, _rehasher); |
12248 | } |
12249 | |
12250 | inline flatbuffers::Offset<LogSoftmaxOptions> CreateLogSoftmaxOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogSoftmaxOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12251 | (void)_rehasher; |
12252 | (void)_o; |
12253 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LogSoftmaxOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12254 | return tflite::CreateLogSoftmaxOptions( |
12255 | _fbb); |
12256 | } |
12257 | |
12258 | inline CastOptionsT *CastOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12259 | auto _o = new CastOptionsT(); |
12260 | UnPackTo(_o, _resolver); |
12261 | return _o; |
12262 | } |
12263 | |
12264 | inline void CastOptions::UnPackTo(CastOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12265 | (void)_o; |
12266 | (void)_resolver; |
12267 | { auto _e = in_data_type(); _o->in_data_type = _e; } |
12268 | { auto _e = out_data_type(); _o->out_data_type = _e; } |
12269 | } |
12270 | |
12271 | inline flatbuffers::Offset<CastOptions> CastOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const CastOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12272 | return CreateCastOptions(_fbb, _o, _rehasher); |
12273 | } |
12274 | |
12275 | inline flatbuffers::Offset<CastOptions> CreateCastOptions(flatbuffers::FlatBufferBuilder &_fbb, const CastOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12276 | (void)_rehasher; |
12277 | (void)_o; |
12278 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const CastOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12279 | auto _in_data_type = _o->in_data_type; |
12280 | auto _out_data_type = _o->out_data_type; |
12281 | return tflite::CreateCastOptions( |
12282 | _fbb, |
12283 | _in_data_type, |
12284 | _out_data_type); |
12285 | } |
12286 | |
12287 | inline DequantizeOptionsT *DequantizeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12288 | auto _o = new DequantizeOptionsT(); |
12289 | UnPackTo(_o, _resolver); |
12290 | return _o; |
12291 | } |
12292 | |
12293 | inline void DequantizeOptions::UnPackTo(DequantizeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12294 | (void)_o; |
12295 | (void)_resolver; |
12296 | } |
12297 | |
12298 | inline flatbuffers::Offset<DequantizeOptions> DequantizeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const DequantizeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12299 | return CreateDequantizeOptions(_fbb, _o, _rehasher); |
12300 | } |
12301 | |
12302 | inline flatbuffers::Offset<DequantizeOptions> CreateDequantizeOptions(flatbuffers::FlatBufferBuilder &_fbb, const DequantizeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12303 | (void)_rehasher; |
12304 | (void)_o; |
12305 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const DequantizeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12306 | return tflite::CreateDequantizeOptions( |
12307 | _fbb); |
12308 | } |
12309 | |
12310 | inline MaximumMinimumOptionsT *MaximumMinimumOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12311 | auto _o = new MaximumMinimumOptionsT(); |
12312 | UnPackTo(_o, _resolver); |
12313 | return _o; |
12314 | } |
12315 | |
12316 | inline void MaximumMinimumOptions::UnPackTo(MaximumMinimumOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12317 | (void)_o; |
12318 | (void)_resolver; |
12319 | } |
12320 | |
12321 | inline flatbuffers::Offset<MaximumMinimumOptions> MaximumMinimumOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const MaximumMinimumOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12322 | return CreateMaximumMinimumOptions(_fbb, _o, _rehasher); |
12323 | } |
12324 | |
12325 | inline flatbuffers::Offset<MaximumMinimumOptions> CreateMaximumMinimumOptions(flatbuffers::FlatBufferBuilder &_fbb, const MaximumMinimumOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12326 | (void)_rehasher; |
12327 | (void)_o; |
12328 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const MaximumMinimumOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12329 | return tflite::CreateMaximumMinimumOptions( |
12330 | _fbb); |
12331 | } |
12332 | |
12333 | inline TileOptionsT *TileOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12334 | auto _o = new TileOptionsT(); |
12335 | UnPackTo(_o, _resolver); |
12336 | return _o; |
12337 | } |
12338 | |
12339 | inline void TileOptions::UnPackTo(TileOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12340 | (void)_o; |
12341 | (void)_resolver; |
12342 | } |
12343 | |
12344 | inline flatbuffers::Offset<TileOptions> TileOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const TileOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12345 | return CreateTileOptions(_fbb, _o, _rehasher); |
12346 | } |
12347 | |
12348 | inline flatbuffers::Offset<TileOptions> CreateTileOptions(flatbuffers::FlatBufferBuilder &_fbb, const TileOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12349 | (void)_rehasher; |
12350 | (void)_o; |
12351 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const TileOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12352 | return tflite::CreateTileOptions( |
12353 | _fbb); |
12354 | } |
12355 | |
12356 | inline ArgMaxOptionsT *ArgMaxOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12357 | auto _o = new ArgMaxOptionsT(); |
12358 | UnPackTo(_o, _resolver); |
12359 | return _o; |
12360 | } |
12361 | |
12362 | inline void ArgMaxOptions::UnPackTo(ArgMaxOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12363 | (void)_o; |
12364 | (void)_resolver; |
12365 | { auto _e = output_type(); _o->output_type = _e; } |
12366 | } |
12367 | |
12368 | inline flatbuffers::Offset<ArgMaxOptions> ArgMaxOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ArgMaxOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12369 | return CreateArgMaxOptions(_fbb, _o, _rehasher); |
12370 | } |
12371 | |
12372 | inline flatbuffers::Offset<ArgMaxOptions> CreateArgMaxOptions(flatbuffers::FlatBufferBuilder &_fbb, const ArgMaxOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12373 | (void)_rehasher; |
12374 | (void)_o; |
12375 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ArgMaxOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12376 | auto _output_type = _o->output_type; |
12377 | return tflite::CreateArgMaxOptions( |
12378 | _fbb, |
12379 | _output_type); |
12380 | } |
12381 | |
12382 | inline ArgMinOptionsT *ArgMinOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12383 | auto _o = new ArgMinOptionsT(); |
12384 | UnPackTo(_o, _resolver); |
12385 | return _o; |
12386 | } |
12387 | |
12388 | inline void ArgMinOptions::UnPackTo(ArgMinOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12389 | (void)_o; |
12390 | (void)_resolver; |
12391 | { auto _e = output_type(); _o->output_type = _e; } |
12392 | } |
12393 | |
12394 | inline flatbuffers::Offset<ArgMinOptions> ArgMinOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ArgMinOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12395 | return CreateArgMinOptions(_fbb, _o, _rehasher); |
12396 | } |
12397 | |
12398 | inline flatbuffers::Offset<ArgMinOptions> CreateArgMinOptions(flatbuffers::FlatBufferBuilder &_fbb, const ArgMinOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12399 | (void)_rehasher; |
12400 | (void)_o; |
12401 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ArgMinOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12402 | auto _output_type = _o->output_type; |
12403 | return tflite::CreateArgMinOptions( |
12404 | _fbb, |
12405 | _output_type); |
12406 | } |
12407 | |
12408 | inline GreaterOptionsT *GreaterOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12409 | auto _o = new GreaterOptionsT(); |
12410 | UnPackTo(_o, _resolver); |
12411 | return _o; |
12412 | } |
12413 | |
12414 | inline void GreaterOptions::UnPackTo(GreaterOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12415 | (void)_o; |
12416 | (void)_resolver; |
12417 | } |
12418 | |
12419 | inline flatbuffers::Offset<GreaterOptions> GreaterOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const GreaterOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12420 | return CreateGreaterOptions(_fbb, _o, _rehasher); |
12421 | } |
12422 | |
12423 | inline flatbuffers::Offset<GreaterOptions> CreateGreaterOptions(flatbuffers::FlatBufferBuilder &_fbb, const GreaterOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12424 | (void)_rehasher; |
12425 | (void)_o; |
12426 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const GreaterOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12427 | return tflite::CreateGreaterOptions( |
12428 | _fbb); |
12429 | } |
12430 | |
12431 | inline GreaterEqualOptionsT *GreaterEqualOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12432 | auto _o = new GreaterEqualOptionsT(); |
12433 | UnPackTo(_o, _resolver); |
12434 | return _o; |
12435 | } |
12436 | |
12437 | inline void GreaterEqualOptions::UnPackTo(GreaterEqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12438 | (void)_o; |
12439 | (void)_resolver; |
12440 | } |
12441 | |
12442 | inline flatbuffers::Offset<GreaterEqualOptions> GreaterEqualOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const GreaterEqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12443 | return CreateGreaterEqualOptions(_fbb, _o, _rehasher); |
12444 | } |
12445 | |
12446 | inline flatbuffers::Offset<GreaterEqualOptions> CreateGreaterEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const GreaterEqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12447 | (void)_rehasher; |
12448 | (void)_o; |
12449 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const GreaterEqualOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12450 | return tflite::CreateGreaterEqualOptions( |
12451 | _fbb); |
12452 | } |
12453 | |
12454 | inline LessOptionsT *LessOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12455 | auto _o = new LessOptionsT(); |
12456 | UnPackTo(_o, _resolver); |
12457 | return _o; |
12458 | } |
12459 | |
12460 | inline void LessOptions::UnPackTo(LessOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12461 | (void)_o; |
12462 | (void)_resolver; |
12463 | } |
12464 | |
12465 | inline flatbuffers::Offset<LessOptions> LessOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LessOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12466 | return CreateLessOptions(_fbb, _o, _rehasher); |
12467 | } |
12468 | |
12469 | inline flatbuffers::Offset<LessOptions> CreateLessOptions(flatbuffers::FlatBufferBuilder &_fbb, const LessOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12470 | (void)_rehasher; |
12471 | (void)_o; |
12472 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LessOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12473 | return tflite::CreateLessOptions( |
12474 | _fbb); |
12475 | } |
12476 | |
12477 | inline LessEqualOptionsT *LessEqualOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12478 | auto _o = new LessEqualOptionsT(); |
12479 | UnPackTo(_o, _resolver); |
12480 | return _o; |
12481 | } |
12482 | |
12483 | inline void LessEqualOptions::UnPackTo(LessEqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12484 | (void)_o; |
12485 | (void)_resolver; |
12486 | } |
12487 | |
12488 | inline flatbuffers::Offset<LessEqualOptions> LessEqualOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LessEqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12489 | return CreateLessEqualOptions(_fbb, _o, _rehasher); |
12490 | } |
12491 | |
12492 | inline flatbuffers::Offset<LessEqualOptions> CreateLessEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const LessEqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12493 | (void)_rehasher; |
12494 | (void)_o; |
12495 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LessEqualOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12496 | return tflite::CreateLessEqualOptions( |
12497 | _fbb); |
12498 | } |
12499 | |
12500 | inline NegOptionsT *NegOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12501 | auto _o = new NegOptionsT(); |
12502 | UnPackTo(_o, _resolver); |
12503 | return _o; |
12504 | } |
12505 | |
12506 | inline void NegOptions::UnPackTo(NegOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12507 | (void)_o; |
12508 | (void)_resolver; |
12509 | } |
12510 | |
12511 | inline flatbuffers::Offset<NegOptions> NegOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const NegOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12512 | return CreateNegOptions(_fbb, _o, _rehasher); |
12513 | } |
12514 | |
12515 | inline flatbuffers::Offset<NegOptions> CreateNegOptions(flatbuffers::FlatBufferBuilder &_fbb, const NegOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12516 | (void)_rehasher; |
12517 | (void)_o; |
12518 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const NegOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12519 | return tflite::CreateNegOptions( |
12520 | _fbb); |
12521 | } |
12522 | |
12523 | inline SelectOptionsT *SelectOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12524 | auto _o = new SelectOptionsT(); |
12525 | UnPackTo(_o, _resolver); |
12526 | return _o; |
12527 | } |
12528 | |
12529 | inline void SelectOptions::UnPackTo(SelectOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12530 | (void)_o; |
12531 | (void)_resolver; |
12532 | } |
12533 | |
12534 | inline flatbuffers::Offset<SelectOptions> SelectOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SelectOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12535 | return CreateSelectOptions(_fbb, _o, _rehasher); |
12536 | } |
12537 | |
12538 | inline flatbuffers::Offset<SelectOptions> CreateSelectOptions(flatbuffers::FlatBufferBuilder &_fbb, const SelectOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12539 | (void)_rehasher; |
12540 | (void)_o; |
12541 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SelectOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12542 | return tflite::CreateSelectOptions( |
12543 | _fbb); |
12544 | } |
12545 | |
12546 | inline SliceOptionsT *SliceOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12547 | auto _o = new SliceOptionsT(); |
12548 | UnPackTo(_o, _resolver); |
12549 | return _o; |
12550 | } |
12551 | |
12552 | inline void SliceOptions::UnPackTo(SliceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12553 | (void)_o; |
12554 | (void)_resolver; |
12555 | } |
12556 | |
12557 | inline flatbuffers::Offset<SliceOptions> SliceOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SliceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12558 | return CreateSliceOptions(_fbb, _o, _rehasher); |
12559 | } |
12560 | |
12561 | inline flatbuffers::Offset<SliceOptions> CreateSliceOptions(flatbuffers::FlatBufferBuilder &_fbb, const SliceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12562 | (void)_rehasher; |
12563 | (void)_o; |
12564 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SliceOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12565 | return tflite::CreateSliceOptions( |
12566 | _fbb); |
12567 | } |
12568 | |
12569 | inline TransposeConvOptionsT *TransposeConvOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12570 | auto _o = new TransposeConvOptionsT(); |
12571 | UnPackTo(_o, _resolver); |
12572 | return _o; |
12573 | } |
12574 | |
12575 | inline void TransposeConvOptions::UnPackTo(TransposeConvOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12576 | (void)_o; |
12577 | (void)_resolver; |
12578 | { auto _e = padding(); _o->padding = _e; } |
12579 | { auto _e = stride_w(); _o->stride_w = _e; } |
12580 | { auto _e = stride_h(); _o->stride_h = _e; } |
12581 | } |
12582 | |
12583 | inline flatbuffers::Offset<TransposeConvOptions> TransposeConvOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const TransposeConvOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12584 | return CreateTransposeConvOptions(_fbb, _o, _rehasher); |
12585 | } |
12586 | |
12587 | inline flatbuffers::Offset<TransposeConvOptions> CreateTransposeConvOptions(flatbuffers::FlatBufferBuilder &_fbb, const TransposeConvOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12588 | (void)_rehasher; |
12589 | (void)_o; |
12590 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const TransposeConvOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12591 | auto _padding = _o->padding; |
12592 | auto _stride_w = _o->stride_w; |
12593 | auto _stride_h = _o->stride_h; |
12594 | return tflite::CreateTransposeConvOptions( |
12595 | _fbb, |
12596 | _padding, |
12597 | _stride_w, |
12598 | _stride_h); |
12599 | } |
12600 | |
12601 | inline ExpandDimsOptionsT *ExpandDimsOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12602 | auto _o = new ExpandDimsOptionsT(); |
12603 | UnPackTo(_o, _resolver); |
12604 | return _o; |
12605 | } |
12606 | |
12607 | inline void ExpandDimsOptions::UnPackTo(ExpandDimsOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12608 | (void)_o; |
12609 | (void)_resolver; |
12610 | } |
12611 | |
12612 | inline flatbuffers::Offset<ExpandDimsOptions> ExpandDimsOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ExpandDimsOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12613 | return CreateExpandDimsOptions(_fbb, _o, _rehasher); |
12614 | } |
12615 | |
12616 | inline flatbuffers::Offset<ExpandDimsOptions> CreateExpandDimsOptions(flatbuffers::FlatBufferBuilder &_fbb, const ExpandDimsOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12617 | (void)_rehasher; |
12618 | (void)_o; |
12619 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ExpandDimsOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12620 | return tflite::CreateExpandDimsOptions( |
12621 | _fbb); |
12622 | } |
12623 | |
12624 | inline SparseToDenseOptionsT *SparseToDenseOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12625 | auto _o = new SparseToDenseOptionsT(); |
12626 | UnPackTo(_o, _resolver); |
12627 | return _o; |
12628 | } |
12629 | |
12630 | inline void SparseToDenseOptions::UnPackTo(SparseToDenseOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12631 | (void)_o; |
12632 | (void)_resolver; |
12633 | { auto _e = validate_indices(); _o->validate_indices = _e; } |
12634 | } |
12635 | |
12636 | inline flatbuffers::Offset<SparseToDenseOptions> SparseToDenseOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SparseToDenseOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12637 | return CreateSparseToDenseOptions(_fbb, _o, _rehasher); |
12638 | } |
12639 | |
12640 | inline flatbuffers::Offset<SparseToDenseOptions> CreateSparseToDenseOptions(flatbuffers::FlatBufferBuilder &_fbb, const SparseToDenseOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12641 | (void)_rehasher; |
12642 | (void)_o; |
12643 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SparseToDenseOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12644 | auto _validate_indices = _o->validate_indices; |
12645 | return tflite::CreateSparseToDenseOptions( |
12646 | _fbb, |
12647 | _validate_indices); |
12648 | } |
12649 | |
12650 | inline EqualOptionsT *EqualOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12651 | auto _o = new EqualOptionsT(); |
12652 | UnPackTo(_o, _resolver); |
12653 | return _o; |
12654 | } |
12655 | |
12656 | inline void EqualOptions::UnPackTo(EqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12657 | (void)_o; |
12658 | (void)_resolver; |
12659 | } |
12660 | |
12661 | inline flatbuffers::Offset<EqualOptions> EqualOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const EqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12662 | return CreateEqualOptions(_fbb, _o, _rehasher); |
12663 | } |
12664 | |
12665 | inline flatbuffers::Offset<EqualOptions> CreateEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const EqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12666 | (void)_rehasher; |
12667 | (void)_o; |
12668 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const EqualOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12669 | return tflite::CreateEqualOptions( |
12670 | _fbb); |
12671 | } |
12672 | |
12673 | inline NotEqualOptionsT *NotEqualOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12674 | auto _o = new NotEqualOptionsT(); |
12675 | UnPackTo(_o, _resolver); |
12676 | return _o; |
12677 | } |
12678 | |
12679 | inline void NotEqualOptions::UnPackTo(NotEqualOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12680 | (void)_o; |
12681 | (void)_resolver; |
12682 | } |
12683 | |
12684 | inline flatbuffers::Offset<NotEqualOptions> NotEqualOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const NotEqualOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12685 | return CreateNotEqualOptions(_fbb, _o, _rehasher); |
12686 | } |
12687 | |
12688 | inline flatbuffers::Offset<NotEqualOptions> CreateNotEqualOptions(flatbuffers::FlatBufferBuilder &_fbb, const NotEqualOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12689 | (void)_rehasher; |
12690 | (void)_o; |
12691 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const NotEqualOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12692 | return tflite::CreateNotEqualOptions( |
12693 | _fbb); |
12694 | } |
12695 | |
12696 | inline ShapeOptionsT *ShapeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12697 | auto _o = new ShapeOptionsT(); |
12698 | UnPackTo(_o, _resolver); |
12699 | return _o; |
12700 | } |
12701 | |
12702 | inline void ShapeOptions::UnPackTo(ShapeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12703 | (void)_o; |
12704 | (void)_resolver; |
12705 | { auto _e = out_type(); _o->out_type = _e; } |
12706 | } |
12707 | |
12708 | inline flatbuffers::Offset<ShapeOptions> ShapeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ShapeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12709 | return CreateShapeOptions(_fbb, _o, _rehasher); |
12710 | } |
12711 | |
12712 | inline flatbuffers::Offset<ShapeOptions> CreateShapeOptions(flatbuffers::FlatBufferBuilder &_fbb, const ShapeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12713 | (void)_rehasher; |
12714 | (void)_o; |
12715 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ShapeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12716 | auto _out_type = _o->out_type; |
12717 | return tflite::CreateShapeOptions( |
12718 | _fbb, |
12719 | _out_type); |
12720 | } |
12721 | |
12722 | inline RankOptionsT *RankOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12723 | auto _o = new RankOptionsT(); |
12724 | UnPackTo(_o, _resolver); |
12725 | return _o; |
12726 | } |
12727 | |
12728 | inline void RankOptions::UnPackTo(RankOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12729 | (void)_o; |
12730 | (void)_resolver; |
12731 | } |
12732 | |
12733 | inline flatbuffers::Offset<RankOptions> RankOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const RankOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12734 | return CreateRankOptions(_fbb, _o, _rehasher); |
12735 | } |
12736 | |
12737 | inline flatbuffers::Offset<RankOptions> CreateRankOptions(flatbuffers::FlatBufferBuilder &_fbb, const RankOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12738 | (void)_rehasher; |
12739 | (void)_o; |
12740 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const RankOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12741 | return tflite::CreateRankOptions( |
12742 | _fbb); |
12743 | } |
12744 | |
12745 | inline PowOptionsT *PowOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12746 | auto _o = new PowOptionsT(); |
12747 | UnPackTo(_o, _resolver); |
12748 | return _o; |
12749 | } |
12750 | |
12751 | inline void PowOptions::UnPackTo(PowOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12752 | (void)_o; |
12753 | (void)_resolver; |
12754 | } |
12755 | |
12756 | inline flatbuffers::Offset<PowOptions> PowOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const PowOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12757 | return CreatePowOptions(_fbb, _o, _rehasher); |
12758 | } |
12759 | |
12760 | inline flatbuffers::Offset<PowOptions> CreatePowOptions(flatbuffers::FlatBufferBuilder &_fbb, const PowOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12761 | (void)_rehasher; |
12762 | (void)_o; |
12763 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const PowOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12764 | return tflite::CreatePowOptions( |
12765 | _fbb); |
12766 | } |
12767 | |
12768 | inline FakeQuantOptionsT *FakeQuantOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12769 | auto _o = new FakeQuantOptionsT(); |
12770 | UnPackTo(_o, _resolver); |
12771 | return _o; |
12772 | } |
12773 | |
12774 | inline void FakeQuantOptions::UnPackTo(FakeQuantOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12775 | (void)_o; |
12776 | (void)_resolver; |
12777 | { auto _e = min(); _o->min = _e; } |
12778 | { auto _e = max(); _o->max = _e; } |
12779 | { auto _e = num_bits(); _o->num_bits = _e; } |
12780 | { auto _e = narrow_range(); _o->narrow_range = _e; } |
12781 | } |
12782 | |
12783 | inline flatbuffers::Offset<FakeQuantOptions> FakeQuantOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const FakeQuantOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12784 | return CreateFakeQuantOptions(_fbb, _o, _rehasher); |
12785 | } |
12786 | |
12787 | inline flatbuffers::Offset<FakeQuantOptions> CreateFakeQuantOptions(flatbuffers::FlatBufferBuilder &_fbb, const FakeQuantOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12788 | (void)_rehasher; |
12789 | (void)_o; |
12790 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const FakeQuantOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12791 | auto _min = _o->min; |
12792 | auto _max = _o->max; |
12793 | auto _num_bits = _o->num_bits; |
12794 | auto _narrow_range = _o->narrow_range; |
12795 | return tflite::CreateFakeQuantOptions( |
12796 | _fbb, |
12797 | _min, |
12798 | _max, |
12799 | _num_bits, |
12800 | _narrow_range); |
12801 | } |
12802 | |
12803 | inline PackOptionsT *PackOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12804 | auto _o = new PackOptionsT(); |
12805 | UnPackTo(_o, _resolver); |
12806 | return _o; |
12807 | } |
12808 | |
12809 | inline void PackOptions::UnPackTo(PackOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12810 | (void)_o; |
12811 | (void)_resolver; |
12812 | { auto _e = values_count(); _o->values_count = _e; } |
12813 | { auto _e = axis(); _o->axis = _e; } |
12814 | } |
12815 | |
12816 | inline flatbuffers::Offset<PackOptions> PackOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const PackOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12817 | return CreatePackOptions(_fbb, _o, _rehasher); |
12818 | } |
12819 | |
12820 | inline flatbuffers::Offset<PackOptions> CreatePackOptions(flatbuffers::FlatBufferBuilder &_fbb, const PackOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12821 | (void)_rehasher; |
12822 | (void)_o; |
12823 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const PackOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12824 | auto _values_count = _o->values_count; |
12825 | auto _axis = _o->axis; |
12826 | return tflite::CreatePackOptions( |
12827 | _fbb, |
12828 | _values_count, |
12829 | _axis); |
12830 | } |
12831 | |
12832 | inline LogicalOrOptionsT *LogicalOrOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12833 | auto _o = new LogicalOrOptionsT(); |
12834 | UnPackTo(_o, _resolver); |
12835 | return _o; |
12836 | } |
12837 | |
12838 | inline void LogicalOrOptions::UnPackTo(LogicalOrOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12839 | (void)_o; |
12840 | (void)_resolver; |
12841 | } |
12842 | |
12843 | inline flatbuffers::Offset<LogicalOrOptions> LogicalOrOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogicalOrOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12844 | return CreateLogicalOrOptions(_fbb, _o, _rehasher); |
12845 | } |
12846 | |
12847 | inline flatbuffers::Offset<LogicalOrOptions> CreateLogicalOrOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogicalOrOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12848 | (void)_rehasher; |
12849 | (void)_o; |
12850 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LogicalOrOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12851 | return tflite::CreateLogicalOrOptions( |
12852 | _fbb); |
12853 | } |
12854 | |
12855 | inline OneHotOptionsT *OneHotOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12856 | auto _o = new OneHotOptionsT(); |
12857 | UnPackTo(_o, _resolver); |
12858 | return _o; |
12859 | } |
12860 | |
12861 | inline void OneHotOptions::UnPackTo(OneHotOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12862 | (void)_o; |
12863 | (void)_resolver; |
12864 | { auto _e = axis(); _o->axis = _e; } |
12865 | } |
12866 | |
12867 | inline flatbuffers::Offset<OneHotOptions> OneHotOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const OneHotOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12868 | return CreateOneHotOptions(_fbb, _o, _rehasher); |
12869 | } |
12870 | |
12871 | inline flatbuffers::Offset<OneHotOptions> CreateOneHotOptions(flatbuffers::FlatBufferBuilder &_fbb, const OneHotOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12872 | (void)_rehasher; |
12873 | (void)_o; |
12874 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const OneHotOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12875 | auto _axis = _o->axis; |
12876 | return tflite::CreateOneHotOptions( |
12877 | _fbb, |
12878 | _axis); |
12879 | } |
12880 | |
12881 | inline AbsOptionsT *AbsOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12882 | auto _o = new AbsOptionsT(); |
12883 | UnPackTo(_o, _resolver); |
12884 | return _o; |
12885 | } |
12886 | |
12887 | inline void AbsOptions::UnPackTo(AbsOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12888 | (void)_o; |
12889 | (void)_resolver; |
12890 | } |
12891 | |
12892 | inline flatbuffers::Offset<AbsOptions> AbsOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AbsOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12893 | return CreateAbsOptions(_fbb, _o, _rehasher); |
12894 | } |
12895 | |
12896 | inline flatbuffers::Offset<AbsOptions> CreateAbsOptions(flatbuffers::FlatBufferBuilder &_fbb, const AbsOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12897 | (void)_rehasher; |
12898 | (void)_o; |
12899 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AbsOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12900 | return tflite::CreateAbsOptions( |
12901 | _fbb); |
12902 | } |
12903 | |
12904 | inline HardSwishOptionsT *HardSwishOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12905 | auto _o = new HardSwishOptionsT(); |
12906 | UnPackTo(_o, _resolver); |
12907 | return _o; |
12908 | } |
12909 | |
12910 | inline void HardSwishOptions::UnPackTo(HardSwishOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12911 | (void)_o; |
12912 | (void)_resolver; |
12913 | } |
12914 | |
12915 | inline flatbuffers::Offset<HardSwishOptions> HardSwishOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const HardSwishOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12916 | return CreateHardSwishOptions(_fbb, _o, _rehasher); |
12917 | } |
12918 | |
12919 | inline flatbuffers::Offset<HardSwishOptions> CreateHardSwishOptions(flatbuffers::FlatBufferBuilder &_fbb, const HardSwishOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12920 | (void)_rehasher; |
12921 | (void)_o; |
12922 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const HardSwishOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12923 | return tflite::CreateHardSwishOptions( |
12924 | _fbb); |
12925 | } |
12926 | |
12927 | inline LogicalAndOptionsT *LogicalAndOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12928 | auto _o = new LogicalAndOptionsT(); |
12929 | UnPackTo(_o, _resolver); |
12930 | return _o; |
12931 | } |
12932 | |
12933 | inline void LogicalAndOptions::UnPackTo(LogicalAndOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12934 | (void)_o; |
12935 | (void)_resolver; |
12936 | } |
12937 | |
12938 | inline flatbuffers::Offset<LogicalAndOptions> LogicalAndOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogicalAndOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12939 | return CreateLogicalAndOptions(_fbb, _o, _rehasher); |
12940 | } |
12941 | |
12942 | inline flatbuffers::Offset<LogicalAndOptions> CreateLogicalAndOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogicalAndOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12943 | (void)_rehasher; |
12944 | (void)_o; |
12945 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LogicalAndOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12946 | return tflite::CreateLogicalAndOptions( |
12947 | _fbb); |
12948 | } |
12949 | |
12950 | inline LogicalNotOptionsT *LogicalNotOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12951 | auto _o = new LogicalNotOptionsT(); |
12952 | UnPackTo(_o, _resolver); |
12953 | return _o; |
12954 | } |
12955 | |
12956 | inline void LogicalNotOptions::UnPackTo(LogicalNotOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12957 | (void)_o; |
12958 | (void)_resolver; |
12959 | } |
12960 | |
12961 | inline flatbuffers::Offset<LogicalNotOptions> LogicalNotOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LogicalNotOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12962 | return CreateLogicalNotOptions(_fbb, _o, _rehasher); |
12963 | } |
12964 | |
12965 | inline flatbuffers::Offset<LogicalNotOptions> CreateLogicalNotOptions(flatbuffers::FlatBufferBuilder &_fbb, const LogicalNotOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12966 | (void)_rehasher; |
12967 | (void)_o; |
12968 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LogicalNotOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12969 | return tflite::CreateLogicalNotOptions( |
12970 | _fbb); |
12971 | } |
12972 | |
12973 | inline UnpackOptionsT *UnpackOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
12974 | auto _o = new UnpackOptionsT(); |
12975 | UnPackTo(_o, _resolver); |
12976 | return _o; |
12977 | } |
12978 | |
12979 | inline void UnpackOptions::UnPackTo(UnpackOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
12980 | (void)_o; |
12981 | (void)_resolver; |
12982 | { auto _e = num(); _o->num = _e; } |
12983 | { auto _e = axis(); _o->axis = _e; } |
12984 | } |
12985 | |
12986 | inline flatbuffers::Offset<UnpackOptions> UnpackOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const UnpackOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
12987 | return CreateUnpackOptions(_fbb, _o, _rehasher); |
12988 | } |
12989 | |
12990 | inline flatbuffers::Offset<UnpackOptions> CreateUnpackOptions(flatbuffers::FlatBufferBuilder &_fbb, const UnpackOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
12991 | (void)_rehasher; |
12992 | (void)_o; |
12993 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const UnpackOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
12994 | auto _num = _o->num; |
12995 | auto _axis = _o->axis; |
12996 | return tflite::CreateUnpackOptions( |
12997 | _fbb, |
12998 | _num, |
12999 | _axis); |
13000 | } |
13001 | |
13002 | inline FloorDivOptionsT *FloorDivOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13003 | auto _o = new FloorDivOptionsT(); |
13004 | UnPackTo(_o, _resolver); |
13005 | return _o; |
13006 | } |
13007 | |
13008 | inline void FloorDivOptions::UnPackTo(FloorDivOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13009 | (void)_o; |
13010 | (void)_resolver; |
13011 | } |
13012 | |
13013 | inline flatbuffers::Offset<FloorDivOptions> FloorDivOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const FloorDivOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13014 | return CreateFloorDivOptions(_fbb, _o, _rehasher); |
13015 | } |
13016 | |
13017 | inline flatbuffers::Offset<FloorDivOptions> CreateFloorDivOptions(flatbuffers::FlatBufferBuilder &_fbb, const FloorDivOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13018 | (void)_rehasher; |
13019 | (void)_o; |
13020 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const FloorDivOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13021 | return tflite::CreateFloorDivOptions( |
13022 | _fbb); |
13023 | } |
13024 | |
13025 | inline SquareOptionsT *SquareOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13026 | auto _o = new SquareOptionsT(); |
13027 | UnPackTo(_o, _resolver); |
13028 | return _o; |
13029 | } |
13030 | |
13031 | inline void SquareOptions::UnPackTo(SquareOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13032 | (void)_o; |
13033 | (void)_resolver; |
13034 | } |
13035 | |
13036 | inline flatbuffers::Offset<SquareOptions> SquareOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SquareOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13037 | return CreateSquareOptions(_fbb, _o, _rehasher); |
13038 | } |
13039 | |
13040 | inline flatbuffers::Offset<SquareOptions> CreateSquareOptions(flatbuffers::FlatBufferBuilder &_fbb, const SquareOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13041 | (void)_rehasher; |
13042 | (void)_o; |
13043 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SquareOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13044 | return tflite::CreateSquareOptions( |
13045 | _fbb); |
13046 | } |
13047 | |
13048 | inline ZerosLikeOptionsT *ZerosLikeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13049 | auto _o = new ZerosLikeOptionsT(); |
13050 | UnPackTo(_o, _resolver); |
13051 | return _o; |
13052 | } |
13053 | |
13054 | inline void ZerosLikeOptions::UnPackTo(ZerosLikeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13055 | (void)_o; |
13056 | (void)_resolver; |
13057 | } |
13058 | |
13059 | inline flatbuffers::Offset<ZerosLikeOptions> ZerosLikeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ZerosLikeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13060 | return CreateZerosLikeOptions(_fbb, _o, _rehasher); |
13061 | } |
13062 | |
13063 | inline flatbuffers::Offset<ZerosLikeOptions> CreateZerosLikeOptions(flatbuffers::FlatBufferBuilder &_fbb, const ZerosLikeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13064 | (void)_rehasher; |
13065 | (void)_o; |
13066 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ZerosLikeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13067 | return tflite::CreateZerosLikeOptions( |
13068 | _fbb); |
13069 | } |
13070 | |
13071 | inline FillOptionsT *FillOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13072 | auto _o = new FillOptionsT(); |
13073 | UnPackTo(_o, _resolver); |
13074 | return _o; |
13075 | } |
13076 | |
13077 | inline void FillOptions::UnPackTo(FillOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13078 | (void)_o; |
13079 | (void)_resolver; |
13080 | } |
13081 | |
13082 | inline flatbuffers::Offset<FillOptions> FillOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const FillOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13083 | return CreateFillOptions(_fbb, _o, _rehasher); |
13084 | } |
13085 | |
13086 | inline flatbuffers::Offset<FillOptions> CreateFillOptions(flatbuffers::FlatBufferBuilder &_fbb, const FillOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13087 | (void)_rehasher; |
13088 | (void)_o; |
13089 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const FillOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13090 | return tflite::CreateFillOptions( |
13091 | _fbb); |
13092 | } |
13093 | |
13094 | inline FloorModOptionsT *FloorModOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13095 | auto _o = new FloorModOptionsT(); |
13096 | UnPackTo(_o, _resolver); |
13097 | return _o; |
13098 | } |
13099 | |
13100 | inline void FloorModOptions::UnPackTo(FloorModOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13101 | (void)_o; |
13102 | (void)_resolver; |
13103 | } |
13104 | |
13105 | inline flatbuffers::Offset<FloorModOptions> FloorModOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const FloorModOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13106 | return CreateFloorModOptions(_fbb, _o, _rehasher); |
13107 | } |
13108 | |
13109 | inline flatbuffers::Offset<FloorModOptions> CreateFloorModOptions(flatbuffers::FlatBufferBuilder &_fbb, const FloorModOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13110 | (void)_rehasher; |
13111 | (void)_o; |
13112 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const FloorModOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13113 | return tflite::CreateFloorModOptions( |
13114 | _fbb); |
13115 | } |
13116 | |
13117 | inline RangeOptionsT *RangeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13118 | auto _o = new RangeOptionsT(); |
13119 | UnPackTo(_o, _resolver); |
13120 | return _o; |
13121 | } |
13122 | |
13123 | inline void RangeOptions::UnPackTo(RangeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13124 | (void)_o; |
13125 | (void)_resolver; |
13126 | } |
13127 | |
13128 | inline flatbuffers::Offset<RangeOptions> RangeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const RangeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13129 | return CreateRangeOptions(_fbb, _o, _rehasher); |
13130 | } |
13131 | |
13132 | inline flatbuffers::Offset<RangeOptions> CreateRangeOptions(flatbuffers::FlatBufferBuilder &_fbb, const RangeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13133 | (void)_rehasher; |
13134 | (void)_o; |
13135 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const RangeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13136 | return tflite::CreateRangeOptions( |
13137 | _fbb); |
13138 | } |
13139 | |
13140 | inline LeakyReluOptionsT *LeakyReluOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13141 | auto _o = new LeakyReluOptionsT(); |
13142 | UnPackTo(_o, _resolver); |
13143 | return _o; |
13144 | } |
13145 | |
13146 | inline void LeakyReluOptions::UnPackTo(LeakyReluOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13147 | (void)_o; |
13148 | (void)_resolver; |
13149 | { auto _e = alpha(); _o->alpha = _e; } |
13150 | } |
13151 | |
13152 | inline flatbuffers::Offset<LeakyReluOptions> LeakyReluOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const LeakyReluOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13153 | return CreateLeakyReluOptions(_fbb, _o, _rehasher); |
13154 | } |
13155 | |
13156 | inline flatbuffers::Offset<LeakyReluOptions> CreateLeakyReluOptions(flatbuffers::FlatBufferBuilder &_fbb, const LeakyReluOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13157 | (void)_rehasher; |
13158 | (void)_o; |
13159 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const LeakyReluOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13160 | auto _alpha = _o->alpha; |
13161 | return tflite::CreateLeakyReluOptions( |
13162 | _fbb, |
13163 | _alpha); |
13164 | } |
13165 | |
13166 | inline SquaredDifferenceOptionsT *SquaredDifferenceOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13167 | auto _o = new SquaredDifferenceOptionsT(); |
13168 | UnPackTo(_o, _resolver); |
13169 | return _o; |
13170 | } |
13171 | |
13172 | inline void SquaredDifferenceOptions::UnPackTo(SquaredDifferenceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13173 | (void)_o; |
13174 | (void)_resolver; |
13175 | } |
13176 | |
13177 | inline flatbuffers::Offset<SquaredDifferenceOptions> SquaredDifferenceOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SquaredDifferenceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13178 | return CreateSquaredDifferenceOptions(_fbb, _o, _rehasher); |
13179 | } |
13180 | |
13181 | inline flatbuffers::Offset<SquaredDifferenceOptions> CreateSquaredDifferenceOptions(flatbuffers::FlatBufferBuilder &_fbb, const SquaredDifferenceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13182 | (void)_rehasher; |
13183 | (void)_o; |
13184 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SquaredDifferenceOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13185 | return tflite::CreateSquaredDifferenceOptions( |
13186 | _fbb); |
13187 | } |
13188 | |
13189 | inline MirrorPadOptionsT *MirrorPadOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13190 | auto _o = new MirrorPadOptionsT(); |
13191 | UnPackTo(_o, _resolver); |
13192 | return _o; |
13193 | } |
13194 | |
13195 | inline void MirrorPadOptions::UnPackTo(MirrorPadOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13196 | (void)_o; |
13197 | (void)_resolver; |
13198 | { auto _e = mode(); _o->mode = _e; } |
13199 | } |
13200 | |
13201 | inline flatbuffers::Offset<MirrorPadOptions> MirrorPadOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const MirrorPadOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13202 | return CreateMirrorPadOptions(_fbb, _o, _rehasher); |
13203 | } |
13204 | |
13205 | inline flatbuffers::Offset<MirrorPadOptions> CreateMirrorPadOptions(flatbuffers::FlatBufferBuilder &_fbb, const MirrorPadOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13206 | (void)_rehasher; |
13207 | (void)_o; |
13208 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const MirrorPadOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13209 | auto _mode = _o->mode; |
13210 | return tflite::CreateMirrorPadOptions( |
13211 | _fbb, |
13212 | _mode); |
13213 | } |
13214 | |
13215 | inline UniqueOptionsT *UniqueOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13216 | auto _o = new UniqueOptionsT(); |
13217 | UnPackTo(_o, _resolver); |
13218 | return _o; |
13219 | } |
13220 | |
13221 | inline void UniqueOptions::UnPackTo(UniqueOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13222 | (void)_o; |
13223 | (void)_resolver; |
13224 | { auto _e = idx_out_type(); _o->idx_out_type = _e; } |
13225 | } |
13226 | |
13227 | inline flatbuffers::Offset<UniqueOptions> UniqueOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const UniqueOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13228 | return CreateUniqueOptions(_fbb, _o, _rehasher); |
13229 | } |
13230 | |
13231 | inline flatbuffers::Offset<UniqueOptions> CreateUniqueOptions(flatbuffers::FlatBufferBuilder &_fbb, const UniqueOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13232 | (void)_rehasher; |
13233 | (void)_o; |
13234 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const UniqueOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13235 | auto _idx_out_type = _o->idx_out_type; |
13236 | return tflite::CreateUniqueOptions( |
13237 | _fbb, |
13238 | _idx_out_type); |
13239 | } |
13240 | |
13241 | inline ReverseV2OptionsT *ReverseV2Options::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13242 | auto _o = new ReverseV2OptionsT(); |
13243 | UnPackTo(_o, _resolver); |
13244 | return _o; |
13245 | } |
13246 | |
13247 | inline void ReverseV2Options::UnPackTo(ReverseV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13248 | (void)_o; |
13249 | (void)_resolver; |
13250 | } |
13251 | |
13252 | inline flatbuffers::Offset<ReverseV2Options> ReverseV2Options::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReverseV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13253 | return CreateReverseV2Options(_fbb, _o, _rehasher); |
13254 | } |
13255 | |
13256 | inline flatbuffers::Offset<ReverseV2Options> CreateReverseV2Options(flatbuffers::FlatBufferBuilder &_fbb, const ReverseV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13257 | (void)_rehasher; |
13258 | (void)_o; |
13259 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ReverseV2OptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13260 | return tflite::CreateReverseV2Options( |
13261 | _fbb); |
13262 | } |
13263 | |
13264 | inline AddNOptionsT *AddNOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13265 | auto _o = new AddNOptionsT(); |
13266 | UnPackTo(_o, _resolver); |
13267 | return _o; |
13268 | } |
13269 | |
13270 | inline void AddNOptions::UnPackTo(AddNOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13271 | (void)_o; |
13272 | (void)_resolver; |
13273 | } |
13274 | |
13275 | inline flatbuffers::Offset<AddNOptions> AddNOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AddNOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13276 | return CreateAddNOptions(_fbb, _o, _rehasher); |
13277 | } |
13278 | |
13279 | inline flatbuffers::Offset<AddNOptions> CreateAddNOptions(flatbuffers::FlatBufferBuilder &_fbb, const AddNOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13280 | (void)_rehasher; |
13281 | (void)_o; |
13282 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AddNOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13283 | return tflite::CreateAddNOptions( |
13284 | _fbb); |
13285 | } |
13286 | |
13287 | inline GatherNdOptionsT *GatherNdOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13288 | auto _o = new GatherNdOptionsT(); |
13289 | UnPackTo(_o, _resolver); |
13290 | return _o; |
13291 | } |
13292 | |
13293 | inline void GatherNdOptions::UnPackTo(GatherNdOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13294 | (void)_o; |
13295 | (void)_resolver; |
13296 | } |
13297 | |
13298 | inline flatbuffers::Offset<GatherNdOptions> GatherNdOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const GatherNdOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13299 | return CreateGatherNdOptions(_fbb, _o, _rehasher); |
13300 | } |
13301 | |
13302 | inline flatbuffers::Offset<GatherNdOptions> CreateGatherNdOptions(flatbuffers::FlatBufferBuilder &_fbb, const GatherNdOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13303 | (void)_rehasher; |
13304 | (void)_o; |
13305 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const GatherNdOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13306 | return tflite::CreateGatherNdOptions( |
13307 | _fbb); |
13308 | } |
13309 | |
13310 | inline WhereOptionsT *WhereOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13311 | auto _o = new WhereOptionsT(); |
13312 | UnPackTo(_o, _resolver); |
13313 | return _o; |
13314 | } |
13315 | |
13316 | inline void WhereOptions::UnPackTo(WhereOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13317 | (void)_o; |
13318 | (void)_resolver; |
13319 | } |
13320 | |
13321 | inline flatbuffers::Offset<WhereOptions> WhereOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const WhereOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13322 | return CreateWhereOptions(_fbb, _o, _rehasher); |
13323 | } |
13324 | |
13325 | inline flatbuffers::Offset<WhereOptions> CreateWhereOptions(flatbuffers::FlatBufferBuilder &_fbb, const WhereOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13326 | (void)_rehasher; |
13327 | (void)_o; |
13328 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const WhereOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13329 | return tflite::CreateWhereOptions( |
13330 | _fbb); |
13331 | } |
13332 | |
13333 | inline ReverseSequenceOptionsT *ReverseSequenceOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13334 | auto _o = new ReverseSequenceOptionsT(); |
13335 | UnPackTo(_o, _resolver); |
13336 | return _o; |
13337 | } |
13338 | |
13339 | inline void ReverseSequenceOptions::UnPackTo(ReverseSequenceOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13340 | (void)_o; |
13341 | (void)_resolver; |
13342 | { auto _e = seq_dim(); _o->seq_dim = _e; } |
13343 | { auto _e = batch_dim(); _o->batch_dim = _e; } |
13344 | } |
13345 | |
13346 | inline flatbuffers::Offset<ReverseSequenceOptions> ReverseSequenceOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ReverseSequenceOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13347 | return CreateReverseSequenceOptions(_fbb, _o, _rehasher); |
13348 | } |
13349 | |
13350 | inline flatbuffers::Offset<ReverseSequenceOptions> CreateReverseSequenceOptions(flatbuffers::FlatBufferBuilder &_fbb, const ReverseSequenceOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13351 | (void)_rehasher; |
13352 | (void)_o; |
13353 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ReverseSequenceOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13354 | auto _seq_dim = _o->seq_dim; |
13355 | auto _batch_dim = _o->batch_dim; |
13356 | return tflite::CreateReverseSequenceOptions( |
13357 | _fbb, |
13358 | _seq_dim, |
13359 | _batch_dim); |
13360 | } |
13361 | |
13362 | inline MatrixDiagOptionsT *MatrixDiagOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13363 | auto _o = new MatrixDiagOptionsT(); |
13364 | UnPackTo(_o, _resolver); |
13365 | return _o; |
13366 | } |
13367 | |
13368 | inline void MatrixDiagOptions::UnPackTo(MatrixDiagOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13369 | (void)_o; |
13370 | (void)_resolver; |
13371 | } |
13372 | |
13373 | inline flatbuffers::Offset<MatrixDiagOptions> MatrixDiagOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const MatrixDiagOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13374 | return CreateMatrixDiagOptions(_fbb, _o, _rehasher); |
13375 | } |
13376 | |
13377 | inline flatbuffers::Offset<MatrixDiagOptions> CreateMatrixDiagOptions(flatbuffers::FlatBufferBuilder &_fbb, const MatrixDiagOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13378 | (void)_rehasher; |
13379 | (void)_o; |
13380 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const MatrixDiagOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13381 | return tflite::CreateMatrixDiagOptions( |
13382 | _fbb); |
13383 | } |
13384 | |
13385 | inline QuantizeOptionsT *QuantizeOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13386 | auto _o = new QuantizeOptionsT(); |
13387 | UnPackTo(_o, _resolver); |
13388 | return _o; |
13389 | } |
13390 | |
13391 | inline void QuantizeOptions::UnPackTo(QuantizeOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13392 | (void)_o; |
13393 | (void)_resolver; |
13394 | } |
13395 | |
13396 | inline flatbuffers::Offset<QuantizeOptions> QuantizeOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const QuantizeOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13397 | return CreateQuantizeOptions(_fbb, _o, _rehasher); |
13398 | } |
13399 | |
13400 | inline flatbuffers::Offset<QuantizeOptions> CreateQuantizeOptions(flatbuffers::FlatBufferBuilder &_fbb, const QuantizeOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13401 | (void)_rehasher; |
13402 | (void)_o; |
13403 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const QuantizeOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13404 | return tflite::CreateQuantizeOptions( |
13405 | _fbb); |
13406 | } |
13407 | |
13408 | inline MatrixSetDiagOptionsT *MatrixSetDiagOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13409 | auto _o = new MatrixSetDiagOptionsT(); |
13410 | UnPackTo(_o, _resolver); |
13411 | return _o; |
13412 | } |
13413 | |
13414 | inline void MatrixSetDiagOptions::UnPackTo(MatrixSetDiagOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13415 | (void)_o; |
13416 | (void)_resolver; |
13417 | } |
13418 | |
13419 | inline flatbuffers::Offset<MatrixSetDiagOptions> MatrixSetDiagOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const MatrixSetDiagOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13420 | return CreateMatrixSetDiagOptions(_fbb, _o, _rehasher); |
13421 | } |
13422 | |
13423 | inline flatbuffers::Offset<MatrixSetDiagOptions> CreateMatrixSetDiagOptions(flatbuffers::FlatBufferBuilder &_fbb, const MatrixSetDiagOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13424 | (void)_rehasher; |
13425 | (void)_o; |
13426 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const MatrixSetDiagOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13427 | return tflite::CreateMatrixSetDiagOptions( |
13428 | _fbb); |
13429 | } |
13430 | |
13431 | inline IfOptionsT *IfOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13432 | auto _o = new IfOptionsT(); |
13433 | UnPackTo(_o, _resolver); |
13434 | return _o; |
13435 | } |
13436 | |
13437 | inline void IfOptions::UnPackTo(IfOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13438 | (void)_o; |
13439 | (void)_resolver; |
13440 | { auto _e = then_subgraph_index(); _o->then_subgraph_index = _e; } |
13441 | { auto _e = else_subgraph_index(); _o->else_subgraph_index = _e; } |
13442 | } |
13443 | |
13444 | inline flatbuffers::Offset<IfOptions> IfOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const IfOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13445 | return CreateIfOptions(_fbb, _o, _rehasher); |
13446 | } |
13447 | |
13448 | inline flatbuffers::Offset<IfOptions> CreateIfOptions(flatbuffers::FlatBufferBuilder &_fbb, const IfOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13449 | (void)_rehasher; |
13450 | (void)_o; |
13451 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const IfOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13452 | auto _then_subgraph_index = _o->then_subgraph_index; |
13453 | auto _else_subgraph_index = _o->else_subgraph_index; |
13454 | return tflite::CreateIfOptions( |
13455 | _fbb, |
13456 | _then_subgraph_index, |
13457 | _else_subgraph_index); |
13458 | } |
13459 | |
13460 | inline WhileOptionsT *WhileOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13461 | auto _o = new WhileOptionsT(); |
13462 | UnPackTo(_o, _resolver); |
13463 | return _o; |
13464 | } |
13465 | |
13466 | inline void WhileOptions::UnPackTo(WhileOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13467 | (void)_o; |
13468 | (void)_resolver; |
13469 | { auto _e = cond_subgraph_index(); _o->cond_subgraph_index = _e; } |
13470 | { auto _e = body_subgraph_index(); _o->body_subgraph_index = _e; } |
13471 | } |
13472 | |
13473 | inline flatbuffers::Offset<WhileOptions> WhileOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const WhileOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13474 | return CreateWhileOptions(_fbb, _o, _rehasher); |
13475 | } |
13476 | |
13477 | inline flatbuffers::Offset<WhileOptions> CreateWhileOptions(flatbuffers::FlatBufferBuilder &_fbb, const WhileOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13478 | (void)_rehasher; |
13479 | (void)_o; |
13480 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const WhileOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13481 | auto _cond_subgraph_index = _o->cond_subgraph_index; |
13482 | auto _body_subgraph_index = _o->body_subgraph_index; |
13483 | return tflite::CreateWhileOptions( |
13484 | _fbb, |
13485 | _cond_subgraph_index, |
13486 | _body_subgraph_index); |
13487 | } |
13488 | |
13489 | inline NonMaxSuppressionV4OptionsT *NonMaxSuppressionV4Options::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13490 | auto _o = new NonMaxSuppressionV4OptionsT(); |
13491 | UnPackTo(_o, _resolver); |
13492 | return _o; |
13493 | } |
13494 | |
13495 | inline void NonMaxSuppressionV4Options::UnPackTo(NonMaxSuppressionV4OptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13496 | (void)_o; |
13497 | (void)_resolver; |
13498 | } |
13499 | |
13500 | inline flatbuffers::Offset<NonMaxSuppressionV4Options> NonMaxSuppressionV4Options::Pack(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV4OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13501 | return CreateNonMaxSuppressionV4Options(_fbb, _o, _rehasher); |
13502 | } |
13503 | |
13504 | inline flatbuffers::Offset<NonMaxSuppressionV4Options> CreateNonMaxSuppressionV4Options(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV4OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13505 | (void)_rehasher; |
13506 | (void)_o; |
13507 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const NonMaxSuppressionV4OptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13508 | return tflite::CreateNonMaxSuppressionV4Options( |
13509 | _fbb); |
13510 | } |
13511 | |
13512 | inline NonMaxSuppressionV5OptionsT *NonMaxSuppressionV5Options::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13513 | auto _o = new NonMaxSuppressionV5OptionsT(); |
13514 | UnPackTo(_o, _resolver); |
13515 | return _o; |
13516 | } |
13517 | |
13518 | inline void NonMaxSuppressionV5Options::UnPackTo(NonMaxSuppressionV5OptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13519 | (void)_o; |
13520 | (void)_resolver; |
13521 | } |
13522 | |
13523 | inline flatbuffers::Offset<NonMaxSuppressionV5Options> NonMaxSuppressionV5Options::Pack(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV5OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13524 | return CreateNonMaxSuppressionV5Options(_fbb, _o, _rehasher); |
13525 | } |
13526 | |
13527 | inline flatbuffers::Offset<NonMaxSuppressionV5Options> CreateNonMaxSuppressionV5Options(flatbuffers::FlatBufferBuilder &_fbb, const NonMaxSuppressionV5OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13528 | (void)_rehasher; |
13529 | (void)_o; |
13530 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const NonMaxSuppressionV5OptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13531 | return tflite::CreateNonMaxSuppressionV5Options( |
13532 | _fbb); |
13533 | } |
13534 | |
13535 | inline ScatterNdOptionsT *ScatterNdOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13536 | auto _o = new ScatterNdOptionsT(); |
13537 | UnPackTo(_o, _resolver); |
13538 | return _o; |
13539 | } |
13540 | |
13541 | inline void ScatterNdOptions::UnPackTo(ScatterNdOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13542 | (void)_o; |
13543 | (void)_resolver; |
13544 | } |
13545 | |
13546 | inline flatbuffers::Offset<ScatterNdOptions> ScatterNdOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ScatterNdOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13547 | return CreateScatterNdOptions(_fbb, _o, _rehasher); |
13548 | } |
13549 | |
13550 | inline flatbuffers::Offset<ScatterNdOptions> CreateScatterNdOptions(flatbuffers::FlatBufferBuilder &_fbb, const ScatterNdOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13551 | (void)_rehasher; |
13552 | (void)_o; |
13553 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ScatterNdOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13554 | return tflite::CreateScatterNdOptions( |
13555 | _fbb); |
13556 | } |
13557 | |
13558 | inline SelectV2OptionsT *SelectV2Options::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13559 | auto _o = new SelectV2OptionsT(); |
13560 | UnPackTo(_o, _resolver); |
13561 | return _o; |
13562 | } |
13563 | |
13564 | inline void SelectV2Options::UnPackTo(SelectV2OptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13565 | (void)_o; |
13566 | (void)_resolver; |
13567 | } |
13568 | |
13569 | inline flatbuffers::Offset<SelectV2Options> SelectV2Options::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SelectV2OptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13570 | return CreateSelectV2Options(_fbb, _o, _rehasher); |
13571 | } |
13572 | |
13573 | inline flatbuffers::Offset<SelectV2Options> CreateSelectV2Options(flatbuffers::FlatBufferBuilder &_fbb, const SelectV2OptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13574 | (void)_rehasher; |
13575 | (void)_o; |
13576 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SelectV2OptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13577 | return tflite::CreateSelectV2Options( |
13578 | _fbb); |
13579 | } |
13580 | |
13581 | inline DensifyOptionsT *DensifyOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13582 | auto _o = new DensifyOptionsT(); |
13583 | UnPackTo(_o, _resolver); |
13584 | return _o; |
13585 | } |
13586 | |
13587 | inline void DensifyOptions::UnPackTo(DensifyOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13588 | (void)_o; |
13589 | (void)_resolver; |
13590 | } |
13591 | |
13592 | inline flatbuffers::Offset<DensifyOptions> DensifyOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const DensifyOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13593 | return CreateDensifyOptions(_fbb, _o, _rehasher); |
13594 | } |
13595 | |
13596 | inline flatbuffers::Offset<DensifyOptions> CreateDensifyOptions(flatbuffers::FlatBufferBuilder &_fbb, const DensifyOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13597 | (void)_rehasher; |
13598 | (void)_o; |
13599 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const DensifyOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13600 | return tflite::CreateDensifyOptions( |
13601 | _fbb); |
13602 | } |
13603 | |
13604 | inline SegmentSumOptionsT *SegmentSumOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13605 | auto _o = new SegmentSumOptionsT(); |
13606 | UnPackTo(_o, _resolver); |
13607 | return _o; |
13608 | } |
13609 | |
13610 | inline void SegmentSumOptions::UnPackTo(SegmentSumOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13611 | (void)_o; |
13612 | (void)_resolver; |
13613 | } |
13614 | |
13615 | inline flatbuffers::Offset<SegmentSumOptions> SegmentSumOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SegmentSumOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13616 | return CreateSegmentSumOptions(_fbb, _o, _rehasher); |
13617 | } |
13618 | |
13619 | inline flatbuffers::Offset<SegmentSumOptions> CreateSegmentSumOptions(flatbuffers::FlatBufferBuilder &_fbb, const SegmentSumOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13620 | (void)_rehasher; |
13621 | (void)_o; |
13622 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SegmentSumOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13623 | return tflite::CreateSegmentSumOptions( |
13624 | _fbb); |
13625 | } |
13626 | |
13627 | inline BatchMatMulOptionsT *BatchMatMulOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13628 | auto _o = new BatchMatMulOptionsT(); |
13629 | UnPackTo(_o, _resolver); |
13630 | return _o; |
13631 | } |
13632 | |
13633 | inline void BatchMatMulOptions::UnPackTo(BatchMatMulOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13634 | (void)_o; |
13635 | (void)_resolver; |
13636 | { auto _e = adj_x(); _o->adj_x = _e; } |
13637 | { auto _e = adj_y(); _o->adj_y = _e; } |
13638 | } |
13639 | |
13640 | inline flatbuffers::Offset<BatchMatMulOptions> BatchMatMulOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const BatchMatMulOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13641 | return CreateBatchMatMulOptions(_fbb, _o, _rehasher); |
13642 | } |
13643 | |
13644 | inline flatbuffers::Offset<BatchMatMulOptions> CreateBatchMatMulOptions(flatbuffers::FlatBufferBuilder &_fbb, const BatchMatMulOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13645 | (void)_rehasher; |
13646 | (void)_o; |
13647 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const BatchMatMulOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13648 | auto _adj_x = _o->adj_x; |
13649 | auto _adj_y = _o->adj_y; |
13650 | return tflite::CreateBatchMatMulOptions( |
13651 | _fbb, |
13652 | _adj_x, |
13653 | _adj_y); |
13654 | } |
13655 | |
13656 | inline OperatorCodeT *OperatorCode::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13657 | auto _o = new OperatorCodeT(); |
13658 | UnPackTo(_o, _resolver); |
13659 | return _o; |
13660 | } |
13661 | |
13662 | inline void OperatorCode::UnPackTo(OperatorCodeT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13663 | (void)_o; |
13664 | (void)_resolver; |
13665 | { auto _e = builtin_code(); _o->builtin_code = _e; } |
13666 | { auto _e = custom_code(); if (_e) _o->custom_code = _e->str(); } |
13667 | { auto _e = version(); _o->version = _e; } |
13668 | } |
13669 | |
13670 | inline flatbuffers::Offset<OperatorCode> OperatorCode::Pack(flatbuffers::FlatBufferBuilder &_fbb, const OperatorCodeT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13671 | return CreateOperatorCode(_fbb, _o, _rehasher); |
13672 | } |
13673 | |
13674 | inline flatbuffers::Offset<OperatorCode> CreateOperatorCode(flatbuffers::FlatBufferBuilder &_fbb, const OperatorCodeT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13675 | (void)_rehasher; |
13676 | (void)_o; |
13677 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const OperatorCodeT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13678 | auto _builtin_code = _o->builtin_code; |
13679 | auto _custom_code = _o->custom_code.empty() ? 0 : _fbb.CreateString(_o->custom_code); |
13680 | auto _version = _o->version; |
13681 | return tflite::CreateOperatorCode( |
13682 | _fbb, |
13683 | _builtin_code, |
13684 | _custom_code, |
13685 | _version); |
13686 | } |
13687 | |
13688 | inline OperatorT *Operator::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13689 | auto _o = new OperatorT(); |
13690 | UnPackTo(_o, _resolver); |
13691 | return _o; |
13692 | } |
13693 | |
13694 | inline void Operator::UnPackTo(OperatorT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13695 | (void)_o; |
13696 | (void)_resolver; |
13697 | { auto _e = opcode_index(); _o->opcode_index = _e; } |
13698 | { auto _e = inputs(); if (_e) { _o->inputs.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->inputs[_i] = _e->Get(_i); } } } |
13699 | { auto _e = outputs(); if (_e) { _o->outputs.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->outputs[_i] = _e->Get(_i); } } } |
13700 | { auto _e = builtin_options_type(); _o->builtin_options.type = _e; } |
13701 | { auto _e = builtin_options(); if (_e) _o->builtin_options.value = tflite::BuiltinOptionsUnion::UnPack(_e, builtin_options_type(), _resolver); } |
13702 | { auto _e = custom_options(); if (_e) { _o->custom_options.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->custom_options[_i] = _e->Get(_i); } } } |
13703 | { auto _e = custom_options_format(); _o->custom_options_format = _e; } |
13704 | { auto _e = mutating_variable_inputs(); if (_e) { _o->mutating_variable_inputs.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->mutating_variable_inputs[_i] = _e->Get(_i) != 0; } } } |
13705 | { auto _e = intermediates(); if (_e) { _o->intermediates.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->intermediates[_i] = _e->Get(_i); } } } |
13706 | } |
13707 | |
13708 | inline flatbuffers::Offset<Operator> Operator::Pack(flatbuffers::FlatBufferBuilder &_fbb, const OperatorT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13709 | return CreateOperator(_fbb, _o, _rehasher); |
13710 | } |
13711 | |
13712 | inline flatbuffers::Offset<Operator> CreateOperator(flatbuffers::FlatBufferBuilder &_fbb, const OperatorT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13713 | (void)_rehasher; |
13714 | (void)_o; |
13715 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const OperatorT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13716 | auto _opcode_index = _o->opcode_index; |
13717 | auto _inputs = _o->inputs.size() ? _fbb.CreateVector(_o->inputs) : 0; |
13718 | auto _outputs = _o->outputs.size() ? _fbb.CreateVector(_o->outputs) : 0; |
13719 | auto _builtin_options_type = _o->builtin_options.type; |
13720 | auto _builtin_options = _o->builtin_options.Pack(_fbb); |
13721 | auto _custom_options = _o->custom_options.size() ? _fbb.CreateVector(_o->custom_options) : 0; |
13722 | auto _custom_options_format = _o->custom_options_format; |
13723 | auto _mutating_variable_inputs = _o->mutating_variable_inputs.size() ? _fbb.CreateVector(_o->mutating_variable_inputs) : 0; |
13724 | auto _intermediates = _o->intermediates.size() ? _fbb.CreateVector(_o->intermediates) : 0; |
13725 | return tflite::CreateOperator( |
13726 | _fbb, |
13727 | _opcode_index, |
13728 | _inputs, |
13729 | _outputs, |
13730 | _builtin_options_type, |
13731 | _builtin_options, |
13732 | _custom_options, |
13733 | _custom_options_format, |
13734 | _mutating_variable_inputs, |
13735 | _intermediates); |
13736 | } |
13737 | |
13738 | inline SubGraphT *SubGraph::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13739 | auto _o = new SubGraphT(); |
13740 | UnPackTo(_o, _resolver); |
13741 | return _o; |
13742 | } |
13743 | |
13744 | inline void SubGraph::UnPackTo(SubGraphT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13745 | (void)_o; |
13746 | (void)_resolver; |
13747 | { auto _e = tensors(); if (_e) { _o->tensors.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->tensors[_i] = std::unique_ptr<tflite::TensorT>(_e->Get(_i)->UnPack(_resolver)); } } } |
13748 | { auto _e = inputs(); if (_e) { _o->inputs.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->inputs[_i] = _e->Get(_i); } } } |
13749 | { auto _e = outputs(); if (_e) { _o->outputs.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->outputs[_i] = _e->Get(_i); } } } |
13750 | { auto _e = operators(); if (_e) { _o->operators.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->operators[_i] = std::unique_ptr<tflite::OperatorT>(_e->Get(_i)->UnPack(_resolver)); } } } |
13751 | { auto _e = name(); if (_e) _o->name = _e->str(); } |
13752 | } |
13753 | |
13754 | inline flatbuffers::Offset<SubGraph> SubGraph::Pack(flatbuffers::FlatBufferBuilder &_fbb, const SubGraphT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13755 | return CreateSubGraph(_fbb, _o, _rehasher); |
13756 | } |
13757 | |
13758 | inline flatbuffers::Offset<SubGraph> CreateSubGraph(flatbuffers::FlatBufferBuilder &_fbb, const SubGraphT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13759 | (void)_rehasher; |
13760 | (void)_o; |
13761 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const SubGraphT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13762 | auto _tensors = _o->tensors.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::Tensor>> (_o->tensors.size(), [](size_t i, _VectorArgs *__va) { return CreateTensor(*__va->__fbb, __va->__o->tensors[i].get(), __va->__rehasher); }, &_va ) : 0; |
13763 | auto _inputs = _o->inputs.size() ? _fbb.CreateVector(_o->inputs) : 0; |
13764 | auto _outputs = _o->outputs.size() ? _fbb.CreateVector(_o->outputs) : 0; |
13765 | auto _operators = _o->operators.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::Operator>> (_o->operators.size(), [](size_t i, _VectorArgs *__va) { return CreateOperator(*__va->__fbb, __va->__o->operators[i].get(), __va->__rehasher); }, &_va ) : 0; |
13766 | auto _name = _o->name.empty() ? 0 : _fbb.CreateString(_o->name); |
13767 | return tflite::CreateSubGraph( |
13768 | _fbb, |
13769 | _tensors, |
13770 | _inputs, |
13771 | _outputs, |
13772 | _operators, |
13773 | _name); |
13774 | } |
13775 | |
13776 | inline BufferT *Buffer::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13777 | auto _o = new BufferT(); |
13778 | UnPackTo(_o, _resolver); |
13779 | return _o; |
13780 | } |
13781 | |
13782 | inline void Buffer::UnPackTo(BufferT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13783 | (void)_o; |
13784 | (void)_resolver; |
13785 | { auto _e = data(); if (_e) { _o->data.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->data[_i] = _e->Get(_i); } } } |
13786 | } |
13787 | |
13788 | inline flatbuffers::Offset<Buffer> Buffer::Pack(flatbuffers::FlatBufferBuilder &_fbb, const BufferT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13789 | return CreateBuffer(_fbb, _o, _rehasher); |
13790 | } |
13791 | |
13792 | inline flatbuffers::Offset<Buffer> CreateBuffer(flatbuffers::FlatBufferBuilder &_fbb, const BufferT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13793 | (void)_rehasher; |
13794 | (void)_o; |
13795 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const BufferT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13796 | _fbb.ForceVectorAlignment(_o->data.size(), sizeof(uint8_t), 16); |
13797 | auto _data = _o->data.size() ? _fbb.CreateVector(_o->data) : 0; |
13798 | return tflite::CreateBuffer( |
13799 | _fbb, |
13800 | _data); |
13801 | } |
13802 | |
13803 | inline MetadataT *Metadata::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13804 | auto _o = new MetadataT(); |
13805 | UnPackTo(_o, _resolver); |
13806 | return _o; |
13807 | } |
13808 | |
13809 | inline void Metadata::UnPackTo(MetadataT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13810 | (void)_o; |
13811 | (void)_resolver; |
13812 | { auto _e = name(); if (_e) _o->name = _e->str(); } |
13813 | { auto _e = buffer(); _o->buffer = _e; } |
13814 | } |
13815 | |
13816 | inline flatbuffers::Offset<Metadata> Metadata::Pack(flatbuffers::FlatBufferBuilder &_fbb, const MetadataT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13817 | return CreateMetadata(_fbb, _o, _rehasher); |
13818 | } |
13819 | |
13820 | inline flatbuffers::Offset<Metadata> CreateMetadata(flatbuffers::FlatBufferBuilder &_fbb, const MetadataT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13821 | (void)_rehasher; |
13822 | (void)_o; |
13823 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const MetadataT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13824 | auto _name = _o->name.empty() ? 0 : _fbb.CreateString(_o->name); |
13825 | auto _buffer = _o->buffer; |
13826 | return tflite::CreateMetadata( |
13827 | _fbb, |
13828 | _name, |
13829 | _buffer); |
13830 | } |
13831 | |
13832 | inline ModelT *Model::UnPack(const flatbuffers::resolver_function_t *_resolver) const { |
13833 | auto _o = new ModelT(); |
13834 | UnPackTo(_o, _resolver); |
13835 | return _o; |
13836 | } |
13837 | |
13838 | inline void Model::UnPackTo(ModelT *_o, const flatbuffers::resolver_function_t *_resolver) const { |
13839 | (void)_o; |
13840 | (void)_resolver; |
13841 | { auto _e = version(); _o->version = _e; } |
13842 | { auto _e = operator_codes(); if (_e) { _o->operator_codes.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->operator_codes[_i] = std::unique_ptr<tflite::OperatorCodeT>(_e->Get(_i)->UnPack(_resolver)); } } } |
13843 | { auto _e = subgraphs(); if (_e) { _o->subgraphs.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->subgraphs[_i] = std::unique_ptr<tflite::SubGraphT>(_e->Get(_i)->UnPack(_resolver)); } } } |
13844 | { auto _e = description(); if (_e) _o->description = _e->str(); } |
13845 | { auto _e = buffers(); if (_e) { _o->buffers.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->buffers[_i] = std::unique_ptr<tflite::BufferT>(_e->Get(_i)->UnPack(_resolver)); } } } |
13846 | { auto _e = metadata_buffer(); if (_e) { _o->metadata_buffer.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->metadata_buffer[_i] = _e->Get(_i); } } } |
13847 | { auto _e = metadata(); if (_e) { _o->metadata.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->metadata[_i] = std::unique_ptr<tflite::MetadataT>(_e->Get(_i)->UnPack(_resolver)); } } } |
13848 | } |
13849 | |
13850 | inline flatbuffers::Offset<Model> Model::Pack(flatbuffers::FlatBufferBuilder &_fbb, const ModelT* _o, const flatbuffers::rehasher_function_t *_rehasher) { |
13851 | return CreateModel(_fbb, _o, _rehasher); |
13852 | } |
13853 | |
13854 | inline flatbuffers::Offset<Model> CreateModel(flatbuffers::FlatBufferBuilder &_fbb, const ModelT *_o, const flatbuffers::rehasher_function_t *_rehasher) { |
13855 | (void)_rehasher; |
13856 | (void)_o; |
13857 | struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const ModelT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va; |
13858 | auto _version = _o->version; |
13859 | auto _operator_codes = _o->operator_codes.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::OperatorCode>> (_o->operator_codes.size(), [](size_t i, _VectorArgs *__va) { return CreateOperatorCode(*__va->__fbb, __va->__o->operator_codes[i].get(), __va->__rehasher); }, &_va ) : 0; |
13860 | auto _subgraphs = _o->subgraphs.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::SubGraph>> (_o->subgraphs.size(), [](size_t i, _VectorArgs *__va) { return CreateSubGraph(*__va->__fbb, __va->__o->subgraphs[i].get(), __va->__rehasher); }, &_va ) : 0; |
13861 | auto _description = _o->description.empty() ? 0 : _fbb.CreateString(_o->description); |
13862 | auto _buffers = _o->buffers.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::Buffer>> (_o->buffers.size(), [](size_t i, _VectorArgs *__va) { return CreateBuffer(*__va->__fbb, __va->__o->buffers[i].get(), __va->__rehasher); }, &_va ) : 0; |
13863 | auto _metadata_buffer = _o->metadata_buffer.size() ? _fbb.CreateVector(_o->metadata_buffer) : 0; |
13864 | auto _metadata = _o->metadata.size() ? _fbb.CreateVector<flatbuffers::Offset<tflite::Metadata>> (_o->metadata.size(), [](size_t i, _VectorArgs *__va) { return CreateMetadata(*__va->__fbb, __va->__o->metadata[i].get(), __va->__rehasher); }, &_va ) : 0; |
13865 | return tflite::CreateModel( |
13866 | _fbb, |
13867 | _version, |
13868 | _operator_codes, |
13869 | _subgraphs, |
13870 | _description, |
13871 | _buffers, |
13872 | _metadata_buffer, |
13873 | _metadata); |
13874 | } |
13875 | |
13876 | inline bool VerifyQuantizationDetails(flatbuffers::Verifier &verifier, const void *obj, QuantizationDetails type) { |
13877 | switch (type) { |
13878 | case QuantizationDetails_NONE: { |
13879 | return true; |
13880 | } |
13881 | case QuantizationDetails_CustomQuantization: { |
13882 | auto ptr = reinterpret_cast<const tflite::CustomQuantization *>(obj); |
13883 | return verifier.VerifyTable(ptr); |
13884 | } |
13885 | default: return true; |
13886 | } |
13887 | } |
13888 | |
13889 | inline bool VerifyQuantizationDetailsVector(flatbuffers::Verifier &verifier, const flatbuffers::Vector<flatbuffers::Offset<void>> *values, const flatbuffers::Vector<uint8_t> *types) { |
13890 | if (!values || !types) return !values && !types; |
13891 | if (values->size() != types->size()) return false; |
13892 | for (flatbuffers::uoffset_t i = 0; i < values->size(); ++i) { |
13893 | if (!VerifyQuantizationDetails( |
13894 | verifier, values->Get(i), types->GetEnum<QuantizationDetails>(i))) { |
13895 | return false; |
13896 | } |
13897 | } |
13898 | return true; |
13899 | } |
13900 | |
13901 | inline void *QuantizationDetailsUnion::UnPack(const void *obj, QuantizationDetails type, const flatbuffers::resolver_function_t *resolver) { |
13902 | switch (type) { |
13903 | case QuantizationDetails_CustomQuantization: { |
13904 | auto ptr = reinterpret_cast<const tflite::CustomQuantization *>(obj); |
13905 | return ptr->UnPack(resolver); |
13906 | } |
13907 | default: return nullptr; |
13908 | } |
13909 | } |
13910 | |
13911 | inline flatbuffers::Offset<void> QuantizationDetailsUnion::Pack(flatbuffers::FlatBufferBuilder &_fbb, const flatbuffers::rehasher_function_t *_rehasher) const { |
13912 | switch (type) { |
13913 | case QuantizationDetails_CustomQuantization: { |
13914 | auto ptr = reinterpret_cast<const tflite::CustomQuantizationT *>(value); |
13915 | return CreateCustomQuantization(_fbb, ptr, _rehasher).Union(); |
13916 | } |
13917 | default: return 0; |
13918 | } |
13919 | } |
13920 | |
13921 | inline QuantizationDetailsUnion::QuantizationDetailsUnion(const QuantizationDetailsUnion &u) FLATBUFFERS_NOEXCEPT : type(u.type), value(nullptr) { |
13922 | switch (type) { |
13923 | case QuantizationDetails_CustomQuantization: { |
13924 | value = new tflite::CustomQuantizationT(*reinterpret_cast<tflite::CustomQuantizationT *>(u.value)); |
13925 | break; |
13926 | } |
13927 | default: |
13928 | break; |
13929 | } |
13930 | } |
13931 | |
13932 | inline void QuantizationDetailsUnion::Reset() { |
13933 | switch (type) { |
13934 | case QuantizationDetails_CustomQuantization: { |
13935 | auto ptr = reinterpret_cast<tflite::CustomQuantizationT *>(value); |
13936 | delete ptr; |
13937 | break; |
13938 | } |
13939 | default: break; |
13940 | } |
13941 | value = nullptr; |
13942 | type = QuantizationDetails_NONE; |
13943 | } |
13944 | |
13945 | inline bool VerifySparseIndexVector(flatbuffers::Verifier &verifier, const void *obj, SparseIndexVector type) { |
13946 | switch (type) { |
13947 | case SparseIndexVector_NONE: { |
13948 | return true; |
13949 | } |
13950 | case SparseIndexVector_Int32Vector: { |
13951 | auto ptr = reinterpret_cast<const tflite::Int32Vector *>(obj); |
13952 | return verifier.VerifyTable(ptr); |
13953 | } |
13954 | case SparseIndexVector_Uint16Vector: { |
13955 | auto ptr = reinterpret_cast<const tflite::Uint16Vector *>(obj); |
13956 | return verifier.VerifyTable(ptr); |
13957 | } |
13958 | case SparseIndexVector_Uint8Vector: { |
13959 | auto ptr = reinterpret_cast<const tflite::Uint8Vector *>(obj); |
13960 | return verifier.VerifyTable(ptr); |
13961 | } |
13962 | default: return true; |
13963 | } |
13964 | } |
13965 | |
13966 | inline bool VerifySparseIndexVectorVector(flatbuffers::Verifier &verifier, const flatbuffers::Vector<flatbuffers::Offset<void>> *values, const flatbuffers::Vector<uint8_t> *types) { |
13967 | if (!values || !types) return !values && !types; |
13968 | if (values->size() != types->size()) return false; |
13969 | for (flatbuffers::uoffset_t i = 0; i < values->size(); ++i) { |
13970 | if (!VerifySparseIndexVector( |
13971 | verifier, values->Get(i), types->GetEnum<SparseIndexVector>(i))) { |
13972 | return false; |
13973 | } |
13974 | } |
13975 | return true; |
13976 | } |
13977 | |
13978 | inline void *SparseIndexVectorUnion::UnPack(const void *obj, SparseIndexVector type, const flatbuffers::resolver_function_t *resolver) { |
13979 | switch (type) { |
13980 | case SparseIndexVector_Int32Vector: { |
13981 | auto ptr = reinterpret_cast<const tflite::Int32Vector *>(obj); |
13982 | return ptr->UnPack(resolver); |
13983 | } |
13984 | case SparseIndexVector_Uint16Vector: { |
13985 | auto ptr = reinterpret_cast<const tflite::Uint16Vector *>(obj); |
13986 | return ptr->UnPack(resolver); |
13987 | } |
13988 | case SparseIndexVector_Uint8Vector: { |
13989 | auto ptr = reinterpret_cast<const tflite::Uint8Vector *>(obj); |
13990 | return ptr->UnPack(resolver); |
13991 | } |
13992 | default: return nullptr; |
13993 | } |
13994 | } |
13995 | |
13996 | inline flatbuffers::Offset<void> SparseIndexVectorUnion::Pack(flatbuffers::FlatBufferBuilder &_fbb, const flatbuffers::rehasher_function_t *_rehasher) const { |
13997 | switch (type) { |
13998 | case SparseIndexVector_Int32Vector: { |
13999 | auto ptr = reinterpret_cast<const tflite::Int32VectorT *>(value); |
14000 | return CreateInt32Vector(_fbb, ptr, _rehasher).Union(); |
14001 | } |
14002 | case SparseIndexVector_Uint16Vector: { |
14003 | auto ptr = reinterpret_cast<const tflite::Uint16VectorT *>(value); |
14004 | return CreateUint16Vector(_fbb, ptr, _rehasher).Union(); |
14005 | } |
14006 | case SparseIndexVector_Uint8Vector: { |
14007 | auto ptr = reinterpret_cast<const tflite::Uint8VectorT *>(value); |
14008 | return CreateUint8Vector(_fbb, ptr, _rehasher).Union(); |
14009 | } |
14010 | default: return 0; |
14011 | } |
14012 | } |
14013 | |
14014 | inline SparseIndexVectorUnion::SparseIndexVectorUnion(const SparseIndexVectorUnion &u) FLATBUFFERS_NOEXCEPT : type(u.type), value(nullptr) { |
14015 | switch (type) { |
14016 | case SparseIndexVector_Int32Vector: { |
14017 | value = new tflite::Int32VectorT(*reinterpret_cast<tflite::Int32VectorT *>(u.value)); |
14018 | break; |
14019 | } |
14020 | case SparseIndexVector_Uint16Vector: { |
14021 | value = new tflite::Uint16VectorT(*reinterpret_cast<tflite::Uint16VectorT *>(u.value)); |
14022 | break; |
14023 | } |
14024 | case SparseIndexVector_Uint8Vector: { |
14025 | value = new tflite::Uint8VectorT(*reinterpret_cast<tflite::Uint8VectorT *>(u.value)); |
14026 | break; |
14027 | } |
14028 | default: |
14029 | break; |
14030 | } |
14031 | } |
14032 | |
14033 | inline void SparseIndexVectorUnion::Reset() { |
14034 | switch (type) { |
14035 | case SparseIndexVector_Int32Vector: { |
14036 | auto ptr = reinterpret_cast<tflite::Int32VectorT *>(value); |
14037 | delete ptr; |
14038 | break; |
14039 | } |
14040 | case SparseIndexVector_Uint16Vector: { |
14041 | auto ptr = reinterpret_cast<tflite::Uint16VectorT *>(value); |
14042 | delete ptr; |
14043 | break; |
14044 | } |
14045 | case SparseIndexVector_Uint8Vector: { |
14046 | auto ptr = reinterpret_cast<tflite::Uint8VectorT *>(value); |
14047 | delete ptr; |
14048 | break; |
14049 | } |
14050 | default: break; |
14051 | } |
14052 | value = nullptr; |
14053 | type = SparseIndexVector_NONE; |
14054 | } |
14055 | |
14056 | inline bool VerifyBuiltinOptions(flatbuffers::Verifier &verifier, const void *obj, BuiltinOptions type) { |
14057 | switch (type) { |
14058 | case BuiltinOptions_NONE: { |
14059 | return true; |
14060 | } |
14061 | case BuiltinOptions_Conv2DOptions: { |
14062 | auto ptr = reinterpret_cast<const tflite::Conv2DOptions *>(obj); |
14063 | return verifier.VerifyTable(ptr); |
14064 | } |
14065 | case BuiltinOptions_DepthwiseConv2DOptions: { |
14066 | auto ptr = reinterpret_cast<const tflite::DepthwiseConv2DOptions *>(obj); |
14067 | return verifier.VerifyTable(ptr); |
14068 | } |
14069 | case BuiltinOptions_ConcatEmbeddingsOptions: { |
14070 | auto ptr = reinterpret_cast<const tflite::ConcatEmbeddingsOptions *>(obj); |
14071 | return verifier.VerifyTable(ptr); |
14072 | } |
14073 | case BuiltinOptions_LSHProjectionOptions: { |
14074 | auto ptr = reinterpret_cast<const tflite::LSHProjectionOptions *>(obj); |
14075 | return verifier.VerifyTable(ptr); |
14076 | } |
14077 | case BuiltinOptions_Pool2DOptions: { |
14078 | auto ptr = reinterpret_cast<const tflite::Pool2DOptions *>(obj); |
14079 | return verifier.VerifyTable(ptr); |
14080 | } |
14081 | case BuiltinOptions_SVDFOptions: { |
14082 | auto ptr = reinterpret_cast<const tflite::SVDFOptions *>(obj); |
14083 | return verifier.VerifyTable(ptr); |
14084 | } |
14085 | case BuiltinOptions_RNNOptions: { |
14086 | auto ptr = reinterpret_cast<const tflite::RNNOptions *>(obj); |
14087 | return verifier.VerifyTable(ptr); |
14088 | } |
14089 | case BuiltinOptions_FullyConnectedOptions: { |
14090 | auto ptr = reinterpret_cast<const tflite::FullyConnectedOptions *>(obj); |
14091 | return verifier.VerifyTable(ptr); |
14092 | } |
14093 | case BuiltinOptions_SoftmaxOptions: { |
14094 | auto ptr = reinterpret_cast<const tflite::SoftmaxOptions *>(obj); |
14095 | return verifier.VerifyTable(ptr); |
14096 | } |
14097 | case BuiltinOptions_ConcatenationOptions: { |
14098 | auto ptr = reinterpret_cast<const tflite::ConcatenationOptions *>(obj); |
14099 | return verifier.VerifyTable(ptr); |
14100 | } |
14101 | case BuiltinOptions_AddOptions: { |
14102 | auto ptr = reinterpret_cast<const tflite::AddOptions *>(obj); |
14103 | return verifier.VerifyTable(ptr); |
14104 | } |
14105 | case BuiltinOptions_L2NormOptions: { |
14106 | auto ptr = reinterpret_cast<const tflite::L2NormOptions *>(obj); |
14107 | return verifier.VerifyTable(ptr); |
14108 | } |
14109 | case BuiltinOptions_LocalResponseNormalizationOptions: { |
14110 | auto ptr = reinterpret_cast<const tflite::LocalResponseNormalizationOptions *>(obj); |
14111 | return verifier.VerifyTable(ptr); |
14112 | } |
14113 | case BuiltinOptions_LSTMOptions: { |
14114 | auto ptr = reinterpret_cast<const tflite::LSTMOptions *>(obj); |
14115 | return verifier.VerifyTable(ptr); |
14116 | } |
14117 | case BuiltinOptions_ResizeBilinearOptions: { |
14118 | auto ptr = reinterpret_cast<const tflite::ResizeBilinearOptions *>(obj); |
14119 | return verifier.VerifyTable(ptr); |
14120 | } |
14121 | case BuiltinOptions_CallOptions: { |
14122 | auto ptr = reinterpret_cast<const tflite::CallOptions *>(obj); |
14123 | return verifier.VerifyTable(ptr); |
14124 | } |
14125 | case BuiltinOptions_ReshapeOptions: { |
14126 | auto ptr = reinterpret_cast<const tflite::ReshapeOptions *>(obj); |
14127 | return verifier.VerifyTable(ptr); |
14128 | } |
14129 | case BuiltinOptions_SkipGramOptions: { |
14130 | auto ptr = reinterpret_cast<const tflite::SkipGramOptions *>(obj); |
14131 | return verifier.VerifyTable(ptr); |
14132 | } |
14133 | case BuiltinOptions_SpaceToDepthOptions: { |
14134 | auto ptr = reinterpret_cast<const tflite::SpaceToDepthOptions *>(obj); |
14135 | return verifier.VerifyTable(ptr); |
14136 | } |
14137 | case BuiltinOptions_EmbeddingLookupSparseOptions: { |
14138 | auto ptr = reinterpret_cast<const tflite::EmbeddingLookupSparseOptions *>(obj); |
14139 | return verifier.VerifyTable(ptr); |
14140 | } |
14141 | case BuiltinOptions_MulOptions: { |
14142 | auto ptr = reinterpret_cast<const tflite::MulOptions *>(obj); |
14143 | return verifier.VerifyTable(ptr); |
14144 | } |
14145 | case BuiltinOptions_PadOptions: { |
14146 | auto ptr = reinterpret_cast<const tflite::PadOptions *>(obj); |
14147 | return verifier.VerifyTable(ptr); |
14148 | } |
14149 | case BuiltinOptions_GatherOptions: { |
14150 | auto ptr = reinterpret_cast<const tflite::GatherOptions *>(obj); |
14151 | return verifier.VerifyTable(ptr); |
14152 | } |
14153 | case BuiltinOptions_BatchToSpaceNDOptions: { |
14154 | auto ptr = reinterpret_cast<const tflite::BatchToSpaceNDOptions *>(obj); |
14155 | return verifier.VerifyTable(ptr); |
14156 | } |
14157 | case BuiltinOptions_SpaceToBatchNDOptions: { |
14158 | auto ptr = reinterpret_cast<const tflite::SpaceToBatchNDOptions *>(obj); |
14159 | return verifier.VerifyTable(ptr); |
14160 | } |
14161 | case BuiltinOptions_TransposeOptions: { |
14162 | auto ptr = reinterpret_cast<const tflite::TransposeOptions *>(obj); |
14163 | return verifier.VerifyTable(ptr); |
14164 | } |
14165 | case BuiltinOptions_ReducerOptions: { |
14166 | auto ptr = reinterpret_cast<const tflite::ReducerOptions *>(obj); |
14167 | return verifier.VerifyTable(ptr); |
14168 | } |
14169 | case BuiltinOptions_SubOptions: { |
14170 | auto ptr = reinterpret_cast<const tflite::SubOptions *>(obj); |
14171 | return verifier.VerifyTable(ptr); |
14172 | } |
14173 | case BuiltinOptions_DivOptions: { |
14174 | auto ptr = reinterpret_cast<const tflite::DivOptions *>(obj); |
14175 | return verifier.VerifyTable(ptr); |
14176 | } |
14177 | case BuiltinOptions_SqueezeOptions: { |
14178 | auto ptr = reinterpret_cast<const tflite::SqueezeOptions *>(obj); |
14179 | return verifier.VerifyTable(ptr); |
14180 | } |
14181 | case BuiltinOptions_SequenceRNNOptions: { |
14182 | auto ptr = reinterpret_cast<const tflite::SequenceRNNOptions *>(obj); |
14183 | return verifier.VerifyTable(ptr); |
14184 | } |
14185 | case BuiltinOptions_StridedSliceOptions: { |
14186 | auto ptr = reinterpret_cast<const tflite::StridedSliceOptions *>(obj); |
14187 | return verifier.VerifyTable(ptr); |
14188 | } |
14189 | case BuiltinOptions_ExpOptions: { |
14190 | auto ptr = reinterpret_cast<const tflite::ExpOptions *>(obj); |
14191 | return verifier.VerifyTable(ptr); |
14192 | } |
14193 | case BuiltinOptions_TopKV2Options: { |
14194 | auto ptr = reinterpret_cast<const tflite::TopKV2Options *>(obj); |
14195 | return verifier.VerifyTable(ptr); |
14196 | } |
14197 | case BuiltinOptions_SplitOptions: { |
14198 | auto ptr = reinterpret_cast<const tflite::SplitOptions *>(obj); |
14199 | return verifier.VerifyTable(ptr); |
14200 | } |
14201 | case BuiltinOptions_LogSoftmaxOptions: { |
14202 | auto ptr = reinterpret_cast<const tflite::LogSoftmaxOptions *>(obj); |
14203 | return verifier.VerifyTable(ptr); |
14204 | } |
14205 | case BuiltinOptions_CastOptions: { |
14206 | auto ptr = reinterpret_cast<const tflite::CastOptions *>(obj); |
14207 | return verifier.VerifyTable(ptr); |
14208 | } |
14209 | case BuiltinOptions_DequantizeOptions: { |
14210 | auto ptr = reinterpret_cast<const tflite::DequantizeOptions *>(obj); |
14211 | return verifier.VerifyTable(ptr); |
14212 | } |
14213 | case BuiltinOptions_MaximumMinimumOptions: { |
14214 | auto ptr = reinterpret_cast<const tflite::MaximumMinimumOptions *>(obj); |
14215 | return verifier.VerifyTable(ptr); |
14216 | } |
14217 | case BuiltinOptions_ArgMaxOptions: { |
14218 | auto ptr = reinterpret_cast<const tflite::ArgMaxOptions *>(obj); |
14219 | return verifier.VerifyTable(ptr); |
14220 | } |
14221 | case BuiltinOptions_LessOptions: { |
14222 | auto ptr = reinterpret_cast<const tflite::LessOptions *>(obj); |
14223 | return verifier.VerifyTable(ptr); |
14224 | } |
14225 | case BuiltinOptions_NegOptions: { |
14226 | auto ptr = reinterpret_cast<const tflite::NegOptions *>(obj); |
14227 | return verifier.VerifyTable(ptr); |
14228 | } |
14229 | case BuiltinOptions_PadV2Options: { |
14230 | auto ptr = reinterpret_cast<const tflite::PadV2Options *>(obj); |
14231 | return verifier.VerifyTable(ptr); |
14232 | } |
14233 | case BuiltinOptions_GreaterOptions: { |
14234 | auto ptr = reinterpret_cast<const tflite::GreaterOptions *>(obj); |
14235 | return verifier.VerifyTable(ptr); |
14236 | } |
14237 | case BuiltinOptions_GreaterEqualOptions: { |
14238 | auto ptr = reinterpret_cast<const tflite::GreaterEqualOptions *>(obj); |
14239 | return verifier.VerifyTable(ptr); |
14240 | } |
14241 | case BuiltinOptions_LessEqualOptions: { |
14242 | auto ptr = reinterpret_cast<const tflite::LessEqualOptions *>(obj); |
14243 | return verifier.VerifyTable(ptr); |
14244 | } |
14245 | case BuiltinOptions_SelectOptions: { |
14246 | auto ptr = reinterpret_cast<const tflite::SelectOptions *>(obj); |
14247 | return verifier.VerifyTable(ptr); |
14248 | } |
14249 | case BuiltinOptions_SliceOptions: { |
14250 | auto ptr = reinterpret_cast<const tflite::SliceOptions *>(obj); |
14251 | return verifier.VerifyTable(ptr); |
14252 | } |
14253 | case BuiltinOptions_TransposeConvOptions: { |
14254 | auto ptr = reinterpret_cast<const tflite::TransposeConvOptions *>(obj); |
14255 | return verifier.VerifyTable(ptr); |
14256 | } |
14257 | case BuiltinOptions_SparseToDenseOptions: { |
14258 | auto ptr = reinterpret_cast<const tflite::SparseToDenseOptions *>(obj); |
14259 | return verifier.VerifyTable(ptr); |
14260 | } |
14261 | case BuiltinOptions_TileOptions: { |
14262 | auto ptr = reinterpret_cast<const tflite::TileOptions *>(obj); |
14263 | return verifier.VerifyTable(ptr); |
14264 | } |
14265 | case BuiltinOptions_ExpandDimsOptions: { |
14266 | auto ptr = reinterpret_cast<const tflite::ExpandDimsOptions *>(obj); |
14267 | return verifier.VerifyTable(ptr); |
14268 | } |
14269 | case BuiltinOptions_EqualOptions: { |
14270 | auto ptr = reinterpret_cast<const tflite::EqualOptions *>(obj); |
14271 | return verifier.VerifyTable(ptr); |
14272 | } |
14273 | case BuiltinOptions_NotEqualOptions: { |
14274 | auto ptr = reinterpret_cast<const tflite::NotEqualOptions *>(obj); |
14275 | return verifier.VerifyTable(ptr); |
14276 | } |
14277 | case BuiltinOptions_ShapeOptions: { |
14278 | auto ptr = reinterpret_cast<const tflite::ShapeOptions *>(obj); |
14279 | return verifier.VerifyTable(ptr); |
14280 | } |
14281 | case BuiltinOptions_PowOptions: { |
14282 | auto ptr = reinterpret_cast<const tflite::PowOptions *>(obj); |
14283 | return verifier.VerifyTable(ptr); |
14284 | } |
14285 | case BuiltinOptions_ArgMinOptions: { |
14286 | auto ptr = reinterpret_cast<const tflite::ArgMinOptions *>(obj); |
14287 | return verifier.VerifyTable(ptr); |
14288 | } |
14289 | case BuiltinOptions_FakeQuantOptions: { |
14290 | auto ptr = reinterpret_cast<const tflite::FakeQuantOptions *>(obj); |
14291 | return verifier.VerifyTable(ptr); |
14292 | } |
14293 | case BuiltinOptions_PackOptions: { |
14294 | auto ptr = reinterpret_cast<const tflite::PackOptions *>(obj); |
14295 | return verifier.VerifyTable(ptr); |
14296 | } |
14297 | case BuiltinOptions_LogicalOrOptions: { |
14298 | auto ptr = reinterpret_cast<const tflite::LogicalOrOptions *>(obj); |
14299 | return verifier.VerifyTable(ptr); |
14300 | } |
14301 | case BuiltinOptions_OneHotOptions: { |
14302 | auto ptr = reinterpret_cast<const tflite::OneHotOptions *>(obj); |
14303 | return verifier.VerifyTable(ptr); |
14304 | } |
14305 | case BuiltinOptions_LogicalAndOptions: { |
14306 | auto ptr = reinterpret_cast<const tflite::LogicalAndOptions *>(obj); |
14307 | return verifier.VerifyTable(ptr); |
14308 | } |
14309 | case BuiltinOptions_LogicalNotOptions: { |
14310 | auto ptr = reinterpret_cast<const tflite::LogicalNotOptions *>(obj); |
14311 | return verifier.VerifyTable(ptr); |
14312 | } |
14313 | case BuiltinOptions_UnpackOptions: { |
14314 | auto ptr = reinterpret_cast<const tflite::UnpackOptions *>(obj); |
14315 | return verifier.VerifyTable(ptr); |
14316 | } |
14317 | case BuiltinOptions_FloorDivOptions: { |
14318 | auto ptr = reinterpret_cast<const tflite::FloorDivOptions *>(obj); |
14319 | return verifier.VerifyTable(ptr); |
14320 | } |
14321 | case BuiltinOptions_SquareOptions: { |
14322 | auto ptr = reinterpret_cast<const tflite::SquareOptions *>(obj); |
14323 | return verifier.VerifyTable(ptr); |
14324 | } |
14325 | case BuiltinOptions_ZerosLikeOptions: { |
14326 | auto ptr = reinterpret_cast<const tflite::ZerosLikeOptions *>(obj); |
14327 | return verifier.VerifyTable(ptr); |
14328 | } |
14329 | case BuiltinOptions_FillOptions: { |
14330 | auto ptr = reinterpret_cast<const tflite::FillOptions *>(obj); |
14331 | return verifier.VerifyTable(ptr); |
14332 | } |
14333 | case BuiltinOptions_BidirectionalSequenceLSTMOptions: { |
14334 | auto ptr = reinterpret_cast<const tflite::BidirectionalSequenceLSTMOptions *>(obj); |
14335 | return verifier.VerifyTable(ptr); |
14336 | } |
14337 | case BuiltinOptions_BidirectionalSequenceRNNOptions: { |
14338 | auto ptr = reinterpret_cast<const tflite::BidirectionalSequenceRNNOptions *>(obj); |
14339 | return verifier.VerifyTable(ptr); |
14340 | } |
14341 | case BuiltinOptions_UnidirectionalSequenceLSTMOptions: { |
14342 | auto ptr = reinterpret_cast<const tflite::UnidirectionalSequenceLSTMOptions *>(obj); |
14343 | return verifier.VerifyTable(ptr); |
14344 | } |
14345 | case BuiltinOptions_FloorModOptions: { |
14346 | auto ptr = reinterpret_cast<const tflite::FloorModOptions *>(obj); |
14347 | return verifier.VerifyTable(ptr); |
14348 | } |
14349 | case BuiltinOptions_RangeOptions: { |
14350 | auto ptr = reinterpret_cast<const tflite::RangeOptions *>(obj); |
14351 | return verifier.VerifyTable(ptr); |
14352 | } |
14353 | case BuiltinOptions_ResizeNearestNeighborOptions: { |
14354 | auto ptr = reinterpret_cast<const tflite::ResizeNearestNeighborOptions *>(obj); |
14355 | return verifier.VerifyTable(ptr); |
14356 | } |
14357 | case BuiltinOptions_LeakyReluOptions: { |
14358 | auto ptr = reinterpret_cast<const tflite::LeakyReluOptions *>(obj); |
14359 | return verifier.VerifyTable(ptr); |
14360 | } |
14361 | case BuiltinOptions_SquaredDifferenceOptions: { |
14362 | auto ptr = reinterpret_cast<const tflite::SquaredDifferenceOptions *>(obj); |
14363 | return verifier.VerifyTable(ptr); |
14364 | } |
14365 | case BuiltinOptions_MirrorPadOptions: { |
14366 | auto ptr = reinterpret_cast<const tflite::MirrorPadOptions *>(obj); |
14367 | return verifier.VerifyTable(ptr); |
14368 | } |
14369 | case BuiltinOptions_AbsOptions: { |
14370 | auto ptr = reinterpret_cast<const tflite::AbsOptions *>(obj); |
14371 | return verifier.VerifyTable(ptr); |
14372 | } |
14373 | case BuiltinOptions_SplitVOptions: { |
14374 | auto ptr = reinterpret_cast<const tflite::SplitVOptions *>(obj); |
14375 | return verifier.VerifyTable(ptr); |
14376 | } |
14377 | case BuiltinOptions_UniqueOptions: { |
14378 | auto ptr = reinterpret_cast<const tflite::UniqueOptions *>(obj); |
14379 | return verifier.VerifyTable(ptr); |
14380 | } |
14381 | case BuiltinOptions_ReverseV2Options: { |
14382 | auto ptr = reinterpret_cast<const tflite::ReverseV2Options *>(obj); |
14383 | return verifier.VerifyTable(ptr); |
14384 | } |
14385 | case BuiltinOptions_AddNOptions: { |
14386 | auto ptr = reinterpret_cast<const tflite::AddNOptions *>(obj); |
14387 | return verifier.VerifyTable(ptr); |
14388 | } |
14389 | case BuiltinOptions_GatherNdOptions: { |
14390 | auto ptr = reinterpret_cast<const tflite::GatherNdOptions *>(obj); |
14391 | return verifier.VerifyTable(ptr); |
14392 | } |
14393 | case BuiltinOptions_CosOptions: { |
14394 | auto ptr = reinterpret_cast<const tflite::CosOptions *>(obj); |
14395 | return verifier.VerifyTable(ptr); |
14396 | } |
14397 | case BuiltinOptions_WhereOptions: { |
14398 | auto ptr = reinterpret_cast<const tflite::WhereOptions *>(obj); |
14399 | return verifier.VerifyTable(ptr); |
14400 | } |
14401 | case BuiltinOptions_RankOptions: { |
14402 | auto ptr = reinterpret_cast<const tflite::RankOptions *>(obj); |
14403 | return verifier.VerifyTable(ptr); |
14404 | } |
14405 | case BuiltinOptions_ReverseSequenceOptions: { |
14406 | auto ptr = reinterpret_cast<const tflite::ReverseSequenceOptions *>(obj); |
14407 | return verifier.VerifyTable(ptr); |
14408 | } |
14409 | case BuiltinOptions_MatrixDiagOptions: { |
14410 | auto ptr = reinterpret_cast<const tflite::MatrixDiagOptions *>(obj); |
14411 | return verifier.VerifyTable(ptr); |
14412 | } |
14413 | case BuiltinOptions_QuantizeOptions: { |
14414 | auto ptr = reinterpret_cast<const tflite::QuantizeOptions *>(obj); |
14415 | return verifier.VerifyTable(ptr); |
14416 | } |
14417 | case BuiltinOptions_MatrixSetDiagOptions: { |
14418 | auto ptr = reinterpret_cast<const tflite::MatrixSetDiagOptions *>(obj); |
14419 | return verifier.VerifyTable(ptr); |
14420 | } |
14421 | case BuiltinOptions_HardSwishOptions: { |
14422 | auto ptr = reinterpret_cast<const tflite::HardSwishOptions *>(obj); |
14423 | return verifier.VerifyTable(ptr); |
14424 | } |
14425 | case BuiltinOptions_IfOptions: { |
14426 | auto ptr = reinterpret_cast<const tflite::IfOptions *>(obj); |
14427 | return verifier.VerifyTable(ptr); |
14428 | } |
14429 | case BuiltinOptions_WhileOptions: { |
14430 | auto ptr = reinterpret_cast<const tflite::WhileOptions *>(obj); |
14431 | return verifier.VerifyTable(ptr); |
14432 | } |
14433 | case BuiltinOptions_DepthToSpaceOptions: { |
14434 | auto ptr = reinterpret_cast<const tflite::DepthToSpaceOptions *>(obj); |
14435 | return verifier.VerifyTable(ptr); |
14436 | } |
14437 | case BuiltinOptions_NonMaxSuppressionV4Options: { |
14438 | auto ptr = reinterpret_cast<const tflite::NonMaxSuppressionV4Options *>(obj); |
14439 | return verifier.VerifyTable(ptr); |
14440 | } |
14441 | case BuiltinOptions_NonMaxSuppressionV5Options: { |
14442 | auto ptr = reinterpret_cast<const tflite::NonMaxSuppressionV5Options *>(obj); |
14443 | return verifier.VerifyTable(ptr); |
14444 | } |
14445 | case BuiltinOptions_ScatterNdOptions: { |
14446 | auto ptr = reinterpret_cast<const tflite::ScatterNdOptions *>(obj); |
14447 | return verifier.VerifyTable(ptr); |
14448 | } |
14449 | case BuiltinOptions_SelectV2Options: { |
14450 | auto ptr = reinterpret_cast<const tflite::SelectV2Options *>(obj); |
14451 | return verifier.VerifyTable(ptr); |
14452 | } |
14453 | case BuiltinOptions_DensifyOptions: { |
14454 | auto ptr = reinterpret_cast<const tflite::DensifyOptions *>(obj); |
14455 | return verifier.VerifyTable(ptr); |
14456 | } |
14457 | case BuiltinOptions_SegmentSumOptions: { |
14458 | auto ptr = reinterpret_cast<const tflite::SegmentSumOptions *>(obj); |
14459 | return verifier.VerifyTable(ptr); |
14460 | } |
14461 | case BuiltinOptions_BatchMatMulOptions: { |
14462 | auto ptr = reinterpret_cast<const tflite::BatchMatMulOptions *>(obj); |
14463 | return verifier.VerifyTable(ptr); |
14464 | } |
14465 | default: return true; |
14466 | } |
14467 | } |
14468 | |
14469 | inline bool VerifyBuiltinOptionsVector(flatbuffers::Verifier &verifier, const flatbuffers::Vector<flatbuffers::Offset<void>> *values, const flatbuffers::Vector<uint8_t> *types) { |
14470 | if (!values || !types) return !values && !types; |
14471 | if (values->size() != types->size()) return false; |
14472 | for (flatbuffers::uoffset_t i = 0; i < values->size(); ++i) { |
14473 | if (!VerifyBuiltinOptions( |
14474 | verifier, values->Get(i), types->GetEnum<BuiltinOptions>(i))) { |
14475 | return false; |
14476 | } |
14477 | } |
14478 | return true; |
14479 | } |
14480 | |
14481 | inline void *BuiltinOptionsUnion::UnPack(const void *obj, BuiltinOptions type, const flatbuffers::resolver_function_t *resolver) { |
14482 | switch (type) { |
14483 | case BuiltinOptions_Conv2DOptions: { |
14484 | auto ptr = reinterpret_cast<const tflite::Conv2DOptions *>(obj); |
14485 | return ptr->UnPack(resolver); |
14486 | } |
14487 | case BuiltinOptions_DepthwiseConv2DOptions: { |
14488 | auto ptr = reinterpret_cast<const tflite::DepthwiseConv2DOptions *>(obj); |
14489 | return ptr->UnPack(resolver); |
14490 | } |
14491 | case BuiltinOptions_ConcatEmbeddingsOptions: { |
14492 | auto ptr = reinterpret_cast<const tflite::ConcatEmbeddingsOptions *>(obj); |
14493 | return ptr->UnPack(resolver); |
14494 | } |
14495 | case BuiltinOptions_LSHProjectionOptions: { |
14496 | auto ptr = reinterpret_cast<const tflite::LSHProjectionOptions *>(obj); |
14497 | return ptr->UnPack(resolver); |
14498 | } |
14499 | case BuiltinOptions_Pool2DOptions: { |
14500 | auto ptr = reinterpret_cast<const tflite::Pool2DOptions *>(obj); |
14501 | return ptr->UnPack(resolver); |
14502 | } |
14503 | case BuiltinOptions_SVDFOptions: { |
14504 | auto ptr = reinterpret_cast<const tflite::SVDFOptions *>(obj); |
14505 | return ptr->UnPack(resolver); |
14506 | } |
14507 | case BuiltinOptions_RNNOptions: { |
14508 | auto ptr = reinterpret_cast<const tflite::RNNOptions *>(obj); |
14509 | return ptr->UnPack(resolver); |
14510 | } |
14511 | case BuiltinOptions_FullyConnectedOptions: { |
14512 | auto ptr = reinterpret_cast<const tflite::FullyConnectedOptions *>(obj); |
14513 | return ptr->UnPack(resolver); |
14514 | } |
14515 | case BuiltinOptions_SoftmaxOptions: { |
14516 | auto ptr = reinterpret_cast<const tflite::SoftmaxOptions *>(obj); |
14517 | return ptr->UnPack(resolver); |
14518 | } |
14519 | case BuiltinOptions_ConcatenationOptions: { |
14520 | auto ptr = reinterpret_cast<const tflite::ConcatenationOptions *>(obj); |
14521 | return ptr->UnPack(resolver); |
14522 | } |
14523 | case BuiltinOptions_AddOptions: { |
14524 | auto ptr = reinterpret_cast<const tflite::AddOptions *>(obj); |
14525 | return ptr->UnPack(resolver); |
14526 | } |
14527 | case BuiltinOptions_L2NormOptions: { |
14528 | auto ptr = reinterpret_cast<const tflite::L2NormOptions *>(obj); |
14529 | return ptr->UnPack(resolver); |
14530 | } |
14531 | case BuiltinOptions_LocalResponseNormalizationOptions: { |
14532 | auto ptr = reinterpret_cast<const tflite::LocalResponseNormalizationOptions *>(obj); |
14533 | return ptr->UnPack(resolver); |
14534 | } |
14535 | case BuiltinOptions_LSTMOptions: { |
14536 | auto ptr = reinterpret_cast<const tflite::LSTMOptions *>(obj); |
14537 | return ptr->UnPack(resolver); |
14538 | } |
14539 | case BuiltinOptions_ResizeBilinearOptions: { |
14540 | auto ptr = reinterpret_cast<const tflite::ResizeBilinearOptions *>(obj); |
14541 | return ptr->UnPack(resolver); |
14542 | } |
14543 | case BuiltinOptions_CallOptions: { |
14544 | auto ptr = reinterpret_cast<const tflite::CallOptions *>(obj); |
14545 | return ptr->UnPack(resolver); |
14546 | } |
14547 | case BuiltinOptions_ReshapeOptions: { |
14548 | auto ptr = reinterpret_cast<const tflite::ReshapeOptions *>(obj); |
14549 | return ptr->UnPack(resolver); |
14550 | } |
14551 | case BuiltinOptions_SkipGramOptions: { |
14552 | auto ptr = reinterpret_cast<const tflite::SkipGramOptions *>(obj); |
14553 | return ptr->UnPack(resolver); |
14554 | } |
14555 | case BuiltinOptions_SpaceToDepthOptions: { |
14556 | auto ptr = reinterpret_cast<const tflite::SpaceToDepthOptions *>(obj); |
14557 | return ptr->UnPack(resolver); |
14558 | } |
14559 | case BuiltinOptions_EmbeddingLookupSparseOptions: { |
14560 | auto ptr = reinterpret_cast<const tflite::EmbeddingLookupSparseOptions *>(obj); |
14561 | return ptr->UnPack(resolver); |
14562 | } |
14563 | case BuiltinOptions_MulOptions: { |
14564 | auto ptr = reinterpret_cast<const tflite::MulOptions *>(obj); |
14565 | return ptr->UnPack(resolver); |
14566 | } |
14567 | case BuiltinOptions_PadOptions: { |
14568 | auto ptr = reinterpret_cast<const tflite::PadOptions *>(obj); |
14569 | return ptr->UnPack(resolver); |
14570 | } |
14571 | case BuiltinOptions_GatherOptions: { |
14572 | auto ptr = reinterpret_cast<const tflite::GatherOptions *>(obj); |
14573 | return ptr->UnPack(resolver); |
14574 | } |
14575 | case BuiltinOptions_BatchToSpaceNDOptions: { |
14576 | auto ptr = reinterpret_cast<const tflite::BatchToSpaceNDOptions *>(obj); |
14577 | return ptr->UnPack(resolver); |
14578 | } |
14579 | case BuiltinOptions_SpaceToBatchNDOptions: { |
14580 | auto ptr = reinterpret_cast<const tflite::SpaceToBatchNDOptions *>(obj); |
14581 | return ptr->UnPack(resolver); |
14582 | } |
14583 | case BuiltinOptions_TransposeOptions: { |
14584 | auto ptr = reinterpret_cast<const tflite::TransposeOptions *>(obj); |
14585 | return ptr->UnPack(resolver); |
14586 | } |
14587 | case BuiltinOptions_ReducerOptions: { |
14588 | auto ptr = reinterpret_cast<const tflite::ReducerOptions *>(obj); |
14589 | return ptr->UnPack(resolver); |
14590 | } |
14591 | case BuiltinOptions_SubOptions: { |
14592 | auto ptr = reinterpret_cast<const tflite::SubOptions *>(obj); |
14593 | return ptr->UnPack(resolver); |
14594 | } |
14595 | case BuiltinOptions_DivOptions: { |
14596 | auto ptr = reinterpret_cast<const tflite::DivOptions *>(obj); |
14597 | return ptr->UnPack(resolver); |
14598 | } |
14599 | case BuiltinOptions_SqueezeOptions: { |
14600 | auto ptr = reinterpret_cast<const tflite::SqueezeOptions *>(obj); |
14601 | return ptr->UnPack(resolver); |
14602 | } |
14603 | case BuiltinOptions_SequenceRNNOptions: { |
14604 | auto ptr = reinterpret_cast<const tflite::SequenceRNNOptions *>(obj); |
14605 | return ptr->UnPack(resolver); |
14606 | } |
14607 | case BuiltinOptions_StridedSliceOptions: { |
14608 | auto ptr = reinterpret_cast<const tflite::StridedSliceOptions *>(obj); |
14609 | return ptr->UnPack(resolver); |
14610 | } |
14611 | case BuiltinOptions_ExpOptions: { |
14612 | auto ptr = reinterpret_cast<const tflite::ExpOptions *>(obj); |
14613 | return ptr->UnPack(resolver); |
14614 | } |
14615 | case BuiltinOptions_TopKV2Options: { |
14616 | auto ptr = reinterpret_cast<const tflite::TopKV2Options *>(obj); |
14617 | return ptr->UnPack(resolver); |
14618 | } |
14619 | case BuiltinOptions_SplitOptions: { |
14620 | auto ptr = reinterpret_cast<const tflite::SplitOptions *>(obj); |
14621 | return ptr->UnPack(resolver); |
14622 | } |
14623 | case BuiltinOptions_LogSoftmaxOptions: { |
14624 | auto ptr = reinterpret_cast<const tflite::LogSoftmaxOptions *>(obj); |
14625 | return ptr->UnPack(resolver); |
14626 | } |
14627 | case BuiltinOptions_CastOptions: { |
14628 | auto ptr = reinterpret_cast<const tflite::CastOptions *>(obj); |
14629 | return ptr->UnPack(resolver); |
14630 | } |
14631 | case BuiltinOptions_DequantizeOptions: { |
14632 | auto ptr = reinterpret_cast<const tflite::DequantizeOptions *>(obj); |
14633 | return ptr->UnPack(resolver); |
14634 | } |
14635 | case BuiltinOptions_MaximumMinimumOptions: { |
14636 | auto ptr = reinterpret_cast<const tflite::MaximumMinimumOptions *>(obj); |
14637 | return ptr->UnPack(resolver); |
14638 | } |
14639 | case BuiltinOptions_ArgMaxOptions: { |
14640 | auto ptr = reinterpret_cast<const tflite::ArgMaxOptions *>(obj); |
14641 | return ptr->UnPack(resolver); |
14642 | } |
14643 | case BuiltinOptions_LessOptions: { |
14644 | auto ptr = reinterpret_cast<const tflite::LessOptions *>(obj); |
14645 | return ptr->UnPack(resolver); |
14646 | } |
14647 | case BuiltinOptions_NegOptions: { |
14648 | auto ptr = reinterpret_cast<const tflite::NegOptions *>(obj); |
14649 | return ptr->UnPack(resolver); |
14650 | } |
14651 | case BuiltinOptions_PadV2Options: { |
14652 | auto ptr = reinterpret_cast<const tflite::PadV2Options *>(obj); |
14653 | return ptr->UnPack(resolver); |
14654 | } |
14655 | case BuiltinOptions_GreaterOptions: { |
14656 | auto ptr = reinterpret_cast<const tflite::GreaterOptions *>(obj); |
14657 | return ptr->UnPack(resolver); |
14658 | } |
14659 | case BuiltinOptions_GreaterEqualOptions: { |
14660 | auto ptr = reinterpret_cast<const tflite::GreaterEqualOptions *>(obj); |
14661 | return ptr->UnPack(resolver); |
14662 | } |
14663 | case BuiltinOptions_LessEqualOptions: { |
14664 | auto ptr = reinterpret_cast<const tflite::LessEqualOptions *>(obj); |
14665 | return ptr->UnPack(resolver); |
14666 | } |
14667 | case BuiltinOptions_SelectOptions: { |
14668 | auto ptr = reinterpret_cast<const tflite::SelectOptions *>(obj); |
14669 | return ptr->UnPack(resolver); |
14670 | } |
14671 | case BuiltinOptions_SliceOptions: { |
14672 | auto ptr = reinterpret_cast<const tflite::SliceOptions *>(obj); |
14673 | return ptr->UnPack(resolver); |
14674 | } |
14675 | case BuiltinOptions_TransposeConvOptions: { |
14676 | auto ptr = reinterpret_cast<const tflite::TransposeConvOptions *>(obj); |
14677 | return ptr->UnPack(resolver); |
14678 | } |
14679 | case BuiltinOptions_SparseToDenseOptions: { |
14680 | auto ptr = reinterpret_cast<const tflite::SparseToDenseOptions *>(obj); |
14681 | return ptr->UnPack(resolver); |
14682 | } |
14683 | case BuiltinOptions_TileOptions: { |
14684 | auto ptr = reinterpret_cast<const tflite::TileOptions *>(obj); |
14685 | return ptr->UnPack(resolver); |
14686 | } |
14687 | case BuiltinOptions_ExpandDimsOptions: { |
14688 | auto ptr = reinterpret_cast<const tflite::ExpandDimsOptions *>(obj); |
14689 | return ptr->UnPack(resolver); |
14690 | } |
14691 | case BuiltinOptions_EqualOptions: { |
14692 | auto ptr = reinterpret_cast<const tflite::EqualOptions *>(obj); |
14693 | return ptr->UnPack(resolver); |
14694 | } |
14695 | case BuiltinOptions_NotEqualOptions: { |
14696 | auto ptr = reinterpret_cast<const tflite::NotEqualOptions *>(obj); |
14697 | return ptr->UnPack(resolver); |
14698 | } |
14699 | case BuiltinOptions_ShapeOptions: { |
14700 | auto ptr = reinterpret_cast<const tflite::ShapeOptions *>(obj); |
14701 | return ptr->UnPack(resolver); |
14702 | } |
14703 | case BuiltinOptions_PowOptions: { |
14704 | auto ptr = reinterpret_cast<const tflite::PowOptions *>(obj); |
14705 | return ptr->UnPack(resolver); |
14706 | } |
14707 | case BuiltinOptions_ArgMinOptions: { |
14708 | auto ptr = reinterpret_cast<const tflite::ArgMinOptions *>(obj); |
14709 | return ptr->UnPack(resolver); |
14710 | } |
14711 | case BuiltinOptions_FakeQuantOptions: { |
14712 | auto ptr = reinterpret_cast<const tflite::FakeQuantOptions *>(obj); |
14713 | return ptr->UnPack(resolver); |
14714 | } |
14715 | case BuiltinOptions_PackOptions: { |
14716 | auto ptr = reinterpret_cast<const tflite::PackOptions *>(obj); |
14717 | return ptr->UnPack(resolver); |
14718 | } |
14719 | case BuiltinOptions_LogicalOrOptions: { |
14720 | auto ptr = reinterpret_cast<const tflite::LogicalOrOptions *>(obj); |
14721 | return ptr->UnPack(resolver); |
14722 | } |
14723 | case BuiltinOptions_OneHotOptions: { |
14724 | auto ptr = reinterpret_cast<const tflite::OneHotOptions *>(obj); |
14725 | return ptr->UnPack(resolver); |
14726 | } |
14727 | case BuiltinOptions_LogicalAndOptions: { |
14728 | auto ptr = reinterpret_cast<const tflite::LogicalAndOptions *>(obj); |
14729 | return ptr->UnPack(resolver); |
14730 | } |
14731 | case BuiltinOptions_LogicalNotOptions: { |
14732 | auto ptr = reinterpret_cast<const tflite::LogicalNotOptions *>(obj); |
14733 | return ptr->UnPack(resolver); |
14734 | } |
14735 | case BuiltinOptions_UnpackOptions: { |
14736 | auto ptr = reinterpret_cast<const tflite::UnpackOptions *>(obj); |
14737 | return ptr->UnPack(resolver); |
14738 | } |
14739 | case BuiltinOptions_FloorDivOptions: { |
14740 | auto ptr = reinterpret_cast<const tflite::FloorDivOptions *>(obj); |
14741 | return ptr->UnPack(resolver); |
14742 | } |
14743 | case BuiltinOptions_SquareOptions: { |
14744 | auto ptr = reinterpret_cast<const tflite::SquareOptions *>(obj); |
14745 | return ptr->UnPack(resolver); |
14746 | } |
14747 | case BuiltinOptions_ZerosLikeOptions: { |
14748 | auto ptr = reinterpret_cast<const tflite::ZerosLikeOptions *>(obj); |
14749 | return ptr->UnPack(resolver); |
14750 | } |
14751 | case BuiltinOptions_FillOptions: { |
14752 | auto ptr = reinterpret_cast<const tflite::FillOptions *>(obj); |
14753 | return ptr->UnPack(resolver); |
14754 | } |
14755 | case BuiltinOptions_BidirectionalSequenceLSTMOptions: { |
14756 | auto ptr = reinterpret_cast<const tflite::BidirectionalSequenceLSTMOptions *>(obj); |
14757 | return ptr->UnPack(resolver); |
14758 | } |
14759 | case BuiltinOptions_BidirectionalSequenceRNNOptions: { |
14760 | auto ptr = reinterpret_cast<const tflite::BidirectionalSequenceRNNOptions *>(obj); |
14761 | return ptr->UnPack(resolver); |
14762 | } |
14763 | case BuiltinOptions_UnidirectionalSequenceLSTMOptions: { |
14764 | auto ptr = reinterpret_cast<const tflite::UnidirectionalSequenceLSTMOptions *>(obj); |
14765 | return ptr->UnPack(resolver); |
14766 | } |
14767 | case BuiltinOptions_FloorModOptions: { |
14768 | auto ptr = reinterpret_cast<const tflite::FloorModOptions *>(obj); |
14769 | return ptr->UnPack(resolver); |
14770 | } |
14771 | case BuiltinOptions_RangeOptions: { |
14772 | auto ptr = reinterpret_cast<const tflite::RangeOptions *>(obj); |
14773 | return ptr->UnPack(resolver); |
14774 | } |
14775 | case BuiltinOptions_ResizeNearestNeighborOptions: { |
14776 | auto ptr = reinterpret_cast<const tflite::ResizeNearestNeighborOptions *>(obj); |
14777 | return ptr->UnPack(resolver); |
14778 | } |
14779 | case BuiltinOptions_LeakyReluOptions: { |
14780 | auto ptr = reinterpret_cast<const tflite::LeakyReluOptions *>(obj); |
14781 | return ptr->UnPack(resolver); |
14782 | } |
14783 | case BuiltinOptions_SquaredDifferenceOptions: { |
14784 | auto ptr = reinterpret_cast<const tflite::SquaredDifferenceOptions *>(obj); |
14785 | return ptr->UnPack(resolver); |
14786 | } |
14787 | case BuiltinOptions_MirrorPadOptions: { |
14788 | auto ptr = reinterpret_cast<const tflite::MirrorPadOptions *>(obj); |
14789 | return ptr->UnPack(resolver); |
14790 | } |
14791 | case BuiltinOptions_AbsOptions: { |
14792 | auto ptr = reinterpret_cast<const tflite::AbsOptions *>(obj); |
14793 | return ptr->UnPack(resolver); |
14794 | } |
14795 | case BuiltinOptions_SplitVOptions: { |
14796 | auto ptr = reinterpret_cast<const tflite::SplitVOptions *>(obj); |
14797 | return ptr->UnPack(resolver); |
14798 | } |
14799 | case BuiltinOptions_UniqueOptions: { |
14800 | auto ptr = reinterpret_cast<const tflite::UniqueOptions *>(obj); |
14801 | return ptr->UnPack(resolver); |
14802 | } |
14803 | case BuiltinOptions_ReverseV2Options: { |
14804 | auto ptr = reinterpret_cast<const tflite::ReverseV2Options *>(obj); |
14805 | return ptr->UnPack(resolver); |
14806 | } |
14807 | case BuiltinOptions_AddNOptions: { |
14808 | auto ptr = reinterpret_cast<const tflite::AddNOptions *>(obj); |
14809 | return ptr->UnPack(resolver); |
14810 | } |
14811 | case BuiltinOptions_GatherNdOptions: { |
14812 | auto ptr = reinterpret_cast<const tflite::GatherNdOptions *>(obj); |
14813 | return ptr->UnPack(resolver); |
14814 | } |
14815 | case BuiltinOptions_CosOptions: { |
14816 | auto ptr = reinterpret_cast<const tflite::CosOptions *>(obj); |
14817 | return ptr->UnPack(resolver); |
14818 | } |
14819 | case BuiltinOptions_WhereOptions: { |
14820 | auto ptr = reinterpret_cast<const tflite::WhereOptions *>(obj); |
14821 | return ptr->UnPack(resolver); |
14822 | } |
14823 | case BuiltinOptions_RankOptions: { |
14824 | auto ptr = reinterpret_cast<const tflite::RankOptions *>(obj); |
14825 | return ptr->UnPack(resolver); |
14826 | } |
14827 | case BuiltinOptions_ReverseSequenceOptions: { |
14828 | auto ptr = reinterpret_cast<const tflite::ReverseSequenceOptions *>(obj); |
14829 | return ptr->UnPack(resolver); |
14830 | } |
14831 | case BuiltinOptions_MatrixDiagOptions: { |
14832 | auto ptr = reinterpret_cast<const tflite::MatrixDiagOptions *>(obj); |
14833 | return ptr->UnPack(resolver); |
14834 | } |
14835 | case BuiltinOptions_QuantizeOptions: { |
14836 | auto ptr = reinterpret_cast<const tflite::QuantizeOptions *>(obj); |
14837 | return ptr->UnPack(resolver); |
14838 | } |
14839 | case BuiltinOptions_MatrixSetDiagOptions: { |
14840 | auto ptr = reinterpret_cast<const tflite::MatrixSetDiagOptions *>(obj); |
14841 | return ptr->UnPack(resolver); |
14842 | } |
14843 | case BuiltinOptions_HardSwishOptions: { |
14844 | auto ptr = reinterpret_cast<const tflite::HardSwishOptions *>(obj); |
14845 | return ptr->UnPack(resolver); |
14846 | } |
14847 | case BuiltinOptions_IfOptions: { |
14848 | auto ptr = reinterpret_cast<const tflite::IfOptions *>(obj); |
14849 | return ptr->UnPack(resolver); |
14850 | } |
14851 | case BuiltinOptions_WhileOptions: { |
14852 | auto ptr = reinterpret_cast<const tflite::WhileOptions *>(obj); |
14853 | return ptr->UnPack(resolver); |
14854 | } |
14855 | case BuiltinOptions_DepthToSpaceOptions: { |
14856 | auto ptr = reinterpret_cast<const tflite::DepthToSpaceOptions *>(obj); |
14857 | return ptr->UnPack(resolver); |
14858 | } |
14859 | case BuiltinOptions_NonMaxSuppressionV4Options: { |
14860 | auto ptr = reinterpret_cast<const tflite::NonMaxSuppressionV4Options *>(obj); |
14861 | return ptr->UnPack(resolver); |
14862 | } |
14863 | case BuiltinOptions_NonMaxSuppressionV5Options: { |
14864 | auto ptr = reinterpret_cast<const tflite::NonMaxSuppressionV5Options *>(obj); |
14865 | return ptr->UnPack(resolver); |
14866 | } |
14867 | case BuiltinOptions_ScatterNdOptions: { |
14868 | auto ptr = reinterpret_cast<const tflite::ScatterNdOptions *>(obj); |
14869 | return ptr->UnPack(resolver); |
14870 | } |
14871 | case BuiltinOptions_SelectV2Options: { |
14872 | auto ptr = reinterpret_cast<const tflite::SelectV2Options *>(obj); |
14873 | return ptr->UnPack(resolver); |
14874 | } |
14875 | case BuiltinOptions_DensifyOptions: { |
14876 | auto ptr = reinterpret_cast<const tflite::DensifyOptions *>(obj); |
14877 | return ptr->UnPack(resolver); |
14878 | } |
14879 | case BuiltinOptions_SegmentSumOptions: { |
14880 | auto ptr = reinterpret_cast<const tflite::SegmentSumOptions *>(obj); |
14881 | return ptr->UnPack(resolver); |
14882 | } |
14883 | case BuiltinOptions_BatchMatMulOptions: { |
14884 | auto ptr = reinterpret_cast<const tflite::BatchMatMulOptions *>(obj); |
14885 | return ptr->UnPack(resolver); |
14886 | } |
14887 | default: return nullptr; |
14888 | } |
14889 | } |
14890 | |
14891 | inline flatbuffers::Offset<void> BuiltinOptionsUnion::Pack(flatbuffers::FlatBufferBuilder &_fbb, const flatbuffers::rehasher_function_t *_rehasher) const { |
14892 | switch (type) { |
14893 | case BuiltinOptions_Conv2DOptions: { |
14894 | auto ptr = reinterpret_cast<const tflite::Conv2DOptionsT *>(value); |
14895 | return CreateConv2DOptions(_fbb, ptr, _rehasher).Union(); |
14896 | } |
14897 | case BuiltinOptions_DepthwiseConv2DOptions: { |
14898 | auto ptr = reinterpret_cast<const tflite::DepthwiseConv2DOptionsT *>(value); |
14899 | return CreateDepthwiseConv2DOptions(_fbb, ptr, _rehasher).Union(); |
14900 | } |
14901 | case BuiltinOptions_ConcatEmbeddingsOptions: { |
14902 | auto ptr = reinterpret_cast<const tflite::ConcatEmbeddingsOptionsT *>(value); |
14903 | return CreateConcatEmbeddingsOptions(_fbb, ptr, _rehasher).Union(); |
14904 | } |
14905 | case BuiltinOptions_LSHProjectionOptions: { |
14906 | auto ptr = reinterpret_cast<const tflite::LSHProjectionOptionsT *>(value); |
14907 | return CreateLSHProjectionOptions(_fbb, ptr, _rehasher).Union(); |
14908 | } |
14909 | case BuiltinOptions_Pool2DOptions: { |
14910 | auto ptr = reinterpret_cast<const tflite::Pool2DOptionsT *>(value); |
14911 | return CreatePool2DOptions(_fbb, ptr, _rehasher).Union(); |
14912 | } |
14913 | case BuiltinOptions_SVDFOptions: { |
14914 | auto ptr = reinterpret_cast<const tflite::SVDFOptionsT *>(value); |
14915 | return CreateSVDFOptions(_fbb, ptr, _rehasher).Union(); |
14916 | } |
14917 | case BuiltinOptions_RNNOptions: { |
14918 | auto ptr = reinterpret_cast<const tflite::RNNOptionsT *>(value); |
14919 | return CreateRNNOptions(_fbb, ptr, _rehasher).Union(); |
14920 | } |
14921 | case BuiltinOptions_FullyConnectedOptions: { |
14922 | auto ptr = reinterpret_cast<const tflite::FullyConnectedOptionsT *>(value); |
14923 | return CreateFullyConnectedOptions(_fbb, ptr, _rehasher).Union(); |
14924 | } |
14925 | case BuiltinOptions_SoftmaxOptions: { |
14926 | auto ptr = reinterpret_cast<const tflite::SoftmaxOptionsT *>(value); |
14927 | return CreateSoftmaxOptions(_fbb, ptr, _rehasher).Union(); |
14928 | } |
14929 | case BuiltinOptions_ConcatenationOptions: { |
14930 | auto ptr = reinterpret_cast<const tflite::ConcatenationOptionsT *>(value); |
14931 | return CreateConcatenationOptions(_fbb, ptr, _rehasher).Union(); |
14932 | } |
14933 | case BuiltinOptions_AddOptions: { |
14934 | auto ptr = reinterpret_cast<const tflite::AddOptionsT *>(value); |
14935 | return CreateAddOptions(_fbb, ptr, _rehasher).Union(); |
14936 | } |
14937 | case BuiltinOptions_L2NormOptions: { |
14938 | auto ptr = reinterpret_cast<const tflite::L2NormOptionsT *>(value); |
14939 | return CreateL2NormOptions(_fbb, ptr, _rehasher).Union(); |
14940 | } |
14941 | case BuiltinOptions_LocalResponseNormalizationOptions: { |
14942 | auto ptr = reinterpret_cast<const tflite::LocalResponseNormalizationOptionsT *>(value); |
14943 | return CreateLocalResponseNormalizationOptions(_fbb, ptr, _rehasher).Union(); |
14944 | } |
14945 | case BuiltinOptions_LSTMOptions: { |
14946 | auto ptr = reinterpret_cast<const tflite::LSTMOptionsT *>(value); |
14947 | return CreateLSTMOptions(_fbb, ptr, _rehasher).Union(); |
14948 | } |
14949 | case BuiltinOptions_ResizeBilinearOptions: { |
14950 | auto ptr = reinterpret_cast<const tflite::ResizeBilinearOptionsT *>(value); |
14951 | return CreateResizeBilinearOptions(_fbb, ptr, _rehasher).Union(); |
14952 | } |
14953 | case BuiltinOptions_CallOptions: { |
14954 | auto ptr = reinterpret_cast<const tflite::CallOptionsT *>(value); |
14955 | return CreateCallOptions(_fbb, ptr, _rehasher).Union(); |
14956 | } |
14957 | case BuiltinOptions_ReshapeOptions: { |
14958 | auto ptr = reinterpret_cast<const tflite::ReshapeOptionsT *>(value); |
14959 | return CreateReshapeOptions(_fbb, ptr, _rehasher).Union(); |
14960 | } |
14961 | case BuiltinOptions_SkipGramOptions: { |
14962 | auto ptr = reinterpret_cast<const tflite::SkipGramOptionsT *>(value); |
14963 | return CreateSkipGramOptions(_fbb, ptr, _rehasher).Union(); |
14964 | } |
14965 | case BuiltinOptions_SpaceToDepthOptions: { |
14966 | auto ptr = reinterpret_cast<const tflite::SpaceToDepthOptionsT *>(value); |
14967 | return CreateSpaceToDepthOptions(_fbb, ptr, _rehasher).Union(); |
14968 | } |
14969 | case BuiltinOptions_EmbeddingLookupSparseOptions: { |
14970 | auto ptr = reinterpret_cast<const tflite::EmbeddingLookupSparseOptionsT *>(value); |
14971 | return CreateEmbeddingLookupSparseOptions(_fbb, ptr, _rehasher).Union(); |
14972 | } |
14973 | case BuiltinOptions_MulOptions: { |
14974 | auto ptr = reinterpret_cast<const tflite::MulOptionsT *>(value); |
14975 | return CreateMulOptions(_fbb, ptr, _rehasher).Union(); |
14976 | } |
14977 | case BuiltinOptions_PadOptions: { |
14978 | auto ptr = reinterpret_cast<const tflite::PadOptionsT *>(value); |
14979 | return CreatePadOptions(_fbb, ptr, _rehasher).Union(); |
14980 | } |
14981 | case BuiltinOptions_GatherOptions: { |
14982 | auto ptr = reinterpret_cast<const tflite::GatherOptionsT *>(value); |
14983 | return CreateGatherOptions(_fbb, ptr, _rehasher).Union(); |
14984 | } |
14985 | case BuiltinOptions_BatchToSpaceNDOptions: { |
14986 | auto ptr = reinterpret_cast<const tflite::BatchToSpaceNDOptionsT *>(value); |
14987 | return CreateBatchToSpaceNDOptions(_fbb, ptr, _rehasher).Union(); |
14988 | } |
14989 | case BuiltinOptions_SpaceToBatchNDOptions: { |
14990 | auto ptr = reinterpret_cast<const tflite::SpaceToBatchNDOptionsT *>(value); |
14991 | return CreateSpaceToBatchNDOptions(_fbb, ptr, _rehasher).Union(); |
14992 | } |
14993 | case BuiltinOptions_TransposeOptions: { |
14994 | auto ptr = reinterpret_cast<const tflite::TransposeOptionsT *>(value); |
14995 | return CreateTransposeOptions(_fbb, ptr, _rehasher).Union(); |
14996 | } |
14997 | case BuiltinOptions_ReducerOptions: { |
14998 | auto ptr = reinterpret_cast<const tflite::ReducerOptionsT *>(value); |
14999 | return CreateReducerOptions(_fbb, ptr, _rehasher).Union(); |
15000 | } |
15001 | case BuiltinOptions_SubOptions: { |
15002 | auto ptr = reinterpret_cast<const tflite::SubOptionsT *>(value); |
15003 | return CreateSubOptions(_fbb, ptr, _rehasher).Union(); |
15004 | } |
15005 | case BuiltinOptions_DivOptions: { |
15006 | auto ptr = reinterpret_cast<const tflite::DivOptionsT *>(value); |
15007 | return CreateDivOptions(_fbb, ptr, _rehasher).Union(); |
15008 | } |
15009 | case BuiltinOptions_SqueezeOptions: { |
15010 | auto ptr = reinterpret_cast<const tflite::SqueezeOptionsT *>(value); |
15011 | return CreateSqueezeOptions(_fbb, ptr, _rehasher).Union(); |
15012 | } |
15013 | case BuiltinOptions_SequenceRNNOptions: { |
15014 | auto ptr = reinterpret_cast<const tflite::SequenceRNNOptionsT *>(value); |
15015 | return CreateSequenceRNNOptions(_fbb, ptr, _rehasher).Union(); |
15016 | } |
15017 | case BuiltinOptions_StridedSliceOptions: { |
15018 | auto ptr = reinterpret_cast<const tflite::StridedSliceOptionsT *>(value); |
15019 | return CreateStridedSliceOptions(_fbb, ptr, _rehasher).Union(); |
15020 | } |
15021 | case BuiltinOptions_ExpOptions: { |
15022 | auto ptr = reinterpret_cast<const tflite::ExpOptionsT *>(value); |
15023 | return CreateExpOptions(_fbb, ptr, _rehasher).Union(); |
15024 | } |
15025 | case BuiltinOptions_TopKV2Options: { |
15026 | auto ptr = reinterpret_cast<const tflite::TopKV2OptionsT *>(value); |
15027 | return CreateTopKV2Options(_fbb, ptr, _rehasher).Union(); |
15028 | } |
15029 | case BuiltinOptions_SplitOptions: { |
15030 | auto ptr = reinterpret_cast<const tflite::SplitOptionsT *>(value); |
15031 | return CreateSplitOptions(_fbb, ptr, _rehasher).Union(); |
15032 | } |
15033 | case BuiltinOptions_LogSoftmaxOptions: { |
15034 | auto ptr = reinterpret_cast<const tflite::LogSoftmaxOptionsT *>(value); |
15035 | return CreateLogSoftmaxOptions(_fbb, ptr, _rehasher).Union(); |
15036 | } |
15037 | case BuiltinOptions_CastOptions: { |
15038 | auto ptr = reinterpret_cast<const tflite::CastOptionsT *>(value); |
15039 | return CreateCastOptions(_fbb, ptr, _rehasher).Union(); |
15040 | } |
15041 | case BuiltinOptions_DequantizeOptions: { |
15042 | auto ptr = reinterpret_cast<const tflite::DequantizeOptionsT *>(value); |
15043 | return CreateDequantizeOptions(_fbb, ptr, _rehasher).Union(); |
15044 | } |
15045 | case BuiltinOptions_MaximumMinimumOptions: { |
15046 | auto ptr = reinterpret_cast<const tflite::MaximumMinimumOptionsT *>(value); |
15047 | return CreateMaximumMinimumOptions(_fbb, ptr, _rehasher).Union(); |
15048 | } |
15049 | case BuiltinOptions_ArgMaxOptions: { |
15050 | auto ptr = reinterpret_cast<const tflite::ArgMaxOptionsT *>(value); |
15051 | return CreateArgMaxOptions(_fbb, ptr, _rehasher).Union(); |
15052 | } |
15053 | case BuiltinOptions_LessOptions: { |
15054 | auto ptr = reinterpret_cast<const tflite::LessOptionsT *>(value); |
15055 | return CreateLessOptions(_fbb, ptr, _rehasher).Union(); |
15056 | } |
15057 | case BuiltinOptions_NegOptions: { |
15058 | auto ptr = reinterpret_cast<const tflite::NegOptionsT *>(value); |
15059 | return CreateNegOptions(_fbb, ptr, _rehasher).Union(); |
15060 | } |
15061 | case BuiltinOptions_PadV2Options: { |
15062 | auto ptr = reinterpret_cast<const tflite::PadV2OptionsT *>(value); |
15063 | return CreatePadV2Options(_fbb, ptr, _rehasher).Union(); |
15064 | } |
15065 | case BuiltinOptions_GreaterOptions: { |
15066 | auto ptr = reinterpret_cast<const tflite::GreaterOptionsT *>(value); |
15067 | return CreateGreaterOptions(_fbb, ptr, _rehasher).Union(); |
15068 | } |
15069 | case BuiltinOptions_GreaterEqualOptions: { |
15070 | auto ptr = reinterpret_cast<const tflite::GreaterEqualOptionsT *>(value); |
15071 | return CreateGreaterEqualOptions(_fbb, ptr, _rehasher).Union(); |
15072 | } |
15073 | case BuiltinOptions_LessEqualOptions: { |
15074 | auto ptr = reinterpret_cast<const tflite::LessEqualOptionsT *>(value); |
15075 | return CreateLessEqualOptions(_fbb, ptr, _rehasher).Union(); |
15076 | } |
15077 | case BuiltinOptions_SelectOptions: { |
15078 | auto ptr = reinterpret_cast<const tflite::SelectOptionsT *>(value); |
15079 | return CreateSelectOptions(_fbb, ptr, _rehasher).Union(); |
15080 | } |
15081 | case BuiltinOptions_SliceOptions: { |
15082 | auto ptr = reinterpret_cast<const tflite::SliceOptionsT *>(value); |
15083 | return CreateSliceOptions(_fbb, ptr, _rehasher).Union(); |
15084 | } |
15085 | case BuiltinOptions_TransposeConvOptions: { |
15086 | auto ptr = reinterpret_cast<const tflite::TransposeConvOptionsT *>(value); |
15087 | return CreateTransposeConvOptions(_fbb, ptr, _rehasher).Union(); |
15088 | } |
15089 | case BuiltinOptions_SparseToDenseOptions: { |
15090 | auto ptr = reinterpret_cast<const tflite::SparseToDenseOptionsT *>(value); |
15091 | return CreateSparseToDenseOptions(_fbb, ptr, _rehasher).Union(); |
15092 | } |
15093 | case BuiltinOptions_TileOptions: { |
15094 | auto ptr = reinterpret_cast<const tflite::TileOptionsT *>(value); |
15095 | return CreateTileOptions(_fbb, ptr, _rehasher).Union(); |
15096 | } |
15097 | case BuiltinOptions_ExpandDimsOptions: { |
15098 | auto ptr = reinterpret_cast<const tflite::ExpandDimsOptionsT *>(value); |
15099 | return CreateExpandDimsOptions(_fbb, ptr, _rehasher).Union(); |
15100 | } |
15101 | case BuiltinOptions_EqualOptions: { |
15102 | auto ptr = reinterpret_cast<const tflite::EqualOptionsT *>(value); |
15103 | return CreateEqualOptions(_fbb, ptr, _rehasher).Union(); |
15104 | } |
15105 | case BuiltinOptions_NotEqualOptions: { |
15106 | auto ptr = reinterpret_cast<const tflite::NotEqualOptionsT *>(value); |
15107 | return CreateNotEqualOptions(_fbb, ptr, _rehasher).Union(); |
15108 | } |
15109 | case BuiltinOptions_ShapeOptions: { |
15110 | auto ptr = reinterpret_cast<const tflite::ShapeOptionsT *>(value); |
15111 | return CreateShapeOptions(_fbb, ptr, _rehasher).Union(); |
15112 | } |
15113 | case BuiltinOptions_PowOptions: { |
15114 | auto ptr = reinterpret_cast<const tflite::PowOptionsT *>(value); |
15115 | return CreatePowOptions(_fbb, ptr, _rehasher).Union(); |
15116 | } |
15117 | case BuiltinOptions_ArgMinOptions: { |
15118 | auto ptr = reinterpret_cast<const tflite::ArgMinOptionsT *>(value); |
15119 | return CreateArgMinOptions(_fbb, ptr, _rehasher).Union(); |
15120 | } |
15121 | case BuiltinOptions_FakeQuantOptions: { |
15122 | auto ptr = reinterpret_cast<const tflite::FakeQuantOptionsT *>(value); |
15123 | return CreateFakeQuantOptions(_fbb, ptr, _rehasher).Union(); |
15124 | } |
15125 | case BuiltinOptions_PackOptions: { |
15126 | auto ptr = reinterpret_cast<const tflite::PackOptionsT *>(value); |
15127 | return CreatePackOptions(_fbb, ptr, _rehasher).Union(); |
15128 | } |
15129 | case BuiltinOptions_LogicalOrOptions: { |
15130 | auto ptr = reinterpret_cast<const tflite::LogicalOrOptionsT *>(value); |
15131 | return CreateLogicalOrOptions(_fbb, ptr, _rehasher).Union(); |
15132 | } |
15133 | case BuiltinOptions_OneHotOptions: { |
15134 | auto ptr = reinterpret_cast<const tflite::OneHotOptionsT *>(value); |
15135 | return CreateOneHotOptions(_fbb, ptr, _rehasher).Union(); |
15136 | } |
15137 | case BuiltinOptions_LogicalAndOptions: { |
15138 | auto ptr = reinterpret_cast<const tflite::LogicalAndOptionsT *>(value); |
15139 | return CreateLogicalAndOptions(_fbb, ptr, _rehasher).Union(); |
15140 | } |
15141 | case BuiltinOptions_LogicalNotOptions: { |
15142 | auto ptr = reinterpret_cast<const tflite::LogicalNotOptionsT *>(value); |
15143 | return CreateLogicalNotOptions(_fbb, ptr, _rehasher).Union(); |
15144 | } |
15145 | case BuiltinOptions_UnpackOptions: { |
15146 | auto ptr = reinterpret_cast<const tflite::UnpackOptionsT *>(value); |
15147 | return CreateUnpackOptions(_fbb, ptr, _rehasher).Union(); |
15148 | } |
15149 | case BuiltinOptions_FloorDivOptions: { |
15150 | auto ptr = reinterpret_cast<const tflite::FloorDivOptionsT *>(value); |
15151 | return CreateFloorDivOptions(_fbb, ptr, _rehasher).Union(); |
15152 | } |
15153 | case BuiltinOptions_SquareOptions: { |
15154 | auto ptr = reinterpret_cast<const tflite::SquareOptionsT *>(value); |
15155 | return CreateSquareOptions(_fbb, ptr, _rehasher).Union(); |
15156 | } |
15157 | case BuiltinOptions_ZerosLikeOptions: { |
15158 | auto ptr = reinterpret_cast<const tflite::ZerosLikeOptionsT *>(value); |
15159 | return CreateZerosLikeOptions(_fbb, ptr, _rehasher).Union(); |
15160 | } |
15161 | case BuiltinOptions_FillOptions: { |
15162 | auto ptr = reinterpret_cast<const tflite::FillOptionsT *>(value); |
15163 | return CreateFillOptions(_fbb, ptr, _rehasher).Union(); |
15164 | } |
15165 | case BuiltinOptions_BidirectionalSequenceLSTMOptions: { |
15166 | auto ptr = reinterpret_cast<const tflite::BidirectionalSequenceLSTMOptionsT *>(value); |
15167 | return CreateBidirectionalSequenceLSTMOptions(_fbb, ptr, _rehasher).Union(); |
15168 | } |
15169 | case BuiltinOptions_BidirectionalSequenceRNNOptions: { |
15170 | auto ptr = reinterpret_cast<const tflite::BidirectionalSequenceRNNOptionsT *>(value); |
15171 | return CreateBidirectionalSequenceRNNOptions(_fbb, ptr, _rehasher).Union(); |
15172 | } |
15173 | case BuiltinOptions_UnidirectionalSequenceLSTMOptions: { |
15174 | auto ptr = reinterpret_cast<const tflite::UnidirectionalSequenceLSTMOptionsT *>(value); |
15175 | return CreateUnidirectionalSequenceLSTMOptions(_fbb, ptr, _rehasher).Union(); |
15176 | } |
15177 | case BuiltinOptions_FloorModOptions: { |
15178 | auto ptr = reinterpret_cast<const tflite::FloorModOptionsT *>(value); |
15179 | return CreateFloorModOptions(_fbb, ptr, _rehasher).Union(); |
15180 | } |
15181 | case BuiltinOptions_RangeOptions: { |
15182 | auto ptr = reinterpret_cast<const tflite::RangeOptionsT *>(value); |
15183 | return CreateRangeOptions(_fbb, ptr, _rehasher).Union(); |
15184 | } |
15185 | case BuiltinOptions_ResizeNearestNeighborOptions: { |
15186 | auto ptr = reinterpret_cast<const tflite::ResizeNearestNeighborOptionsT *>(value); |
15187 | return CreateResizeNearestNeighborOptions(_fbb, ptr, _rehasher).Union(); |
15188 | } |
15189 | case BuiltinOptions_LeakyReluOptions: { |
15190 | auto ptr = reinterpret_cast<const tflite::LeakyReluOptionsT *>(value); |
15191 | return CreateLeakyReluOptions(_fbb, ptr, _rehasher).Union(); |
15192 | } |
15193 | case BuiltinOptions_SquaredDifferenceOptions: { |
15194 | auto ptr = reinterpret_cast<const tflite::SquaredDifferenceOptionsT *>(value); |
15195 | return CreateSquaredDifferenceOptions(_fbb, ptr, _rehasher).Union(); |
15196 | } |
15197 | case BuiltinOptions_MirrorPadOptions: { |
15198 | auto ptr = reinterpret_cast<const tflite::MirrorPadOptionsT *>(value); |
15199 | return CreateMirrorPadOptions(_fbb, ptr, _rehasher).Union(); |
15200 | } |
15201 | case BuiltinOptions_AbsOptions: { |
15202 | auto ptr = reinterpret_cast<const tflite::AbsOptionsT *>(value); |
15203 | return CreateAbsOptions(_fbb, ptr, _rehasher).Union(); |
15204 | } |
15205 | case BuiltinOptions_SplitVOptions: { |
15206 | auto ptr = reinterpret_cast<const tflite::SplitVOptionsT *>(value); |
15207 | return CreateSplitVOptions(_fbb, ptr, _rehasher).Union(); |
15208 | } |
15209 | case BuiltinOptions_UniqueOptions: { |
15210 | auto ptr = reinterpret_cast<const tflite::UniqueOptionsT *>(value); |
15211 | return CreateUniqueOptions(_fbb, ptr, _rehasher).Union(); |
15212 | } |
15213 | case BuiltinOptions_ReverseV2Options: { |
15214 | auto ptr = reinterpret_cast<const tflite::ReverseV2OptionsT *>(value); |
15215 | return CreateReverseV2Options(_fbb, ptr, _rehasher).Union(); |
15216 | } |
15217 | case BuiltinOptions_AddNOptions: { |
15218 | auto ptr = reinterpret_cast<const tflite::AddNOptionsT *>(value); |
15219 | return CreateAddNOptions(_fbb, ptr, _rehasher).Union(); |
15220 | } |
15221 | case BuiltinOptions_GatherNdOptions: { |
15222 | auto ptr = reinterpret_cast<const tflite::GatherNdOptionsT *>(value); |
15223 | return CreateGatherNdOptions(_fbb, ptr, _rehasher).Union(); |
15224 | } |
15225 | case BuiltinOptions_CosOptions: { |
15226 | auto ptr = reinterpret_cast<const tflite::CosOptionsT *>(value); |
15227 | return CreateCosOptions(_fbb, ptr, _rehasher).Union(); |
15228 | } |
15229 | case BuiltinOptions_WhereOptions: { |
15230 | auto ptr = reinterpret_cast<const tflite::WhereOptionsT *>(value); |
15231 | return CreateWhereOptions(_fbb, ptr, _rehasher).Union(); |
15232 | } |
15233 | case BuiltinOptions_RankOptions: { |
15234 | auto ptr = reinterpret_cast<const tflite::RankOptionsT *>(value); |
15235 | return CreateRankOptions(_fbb, ptr, _rehasher).Union(); |
15236 | } |
15237 | case BuiltinOptions_ReverseSequenceOptions: { |
15238 | auto ptr = reinterpret_cast<const tflite::ReverseSequenceOptionsT *>(value); |
15239 | return CreateReverseSequenceOptions(_fbb, ptr, _rehasher).Union(); |
15240 | } |
15241 | case BuiltinOptions_MatrixDiagOptions: { |
15242 | auto ptr = reinterpret_cast<const tflite::MatrixDiagOptionsT *>(value); |
15243 | return CreateMatrixDiagOptions(_fbb, ptr, _rehasher).Union(); |
15244 | } |
15245 | case BuiltinOptions_QuantizeOptions: { |
15246 | auto ptr = reinterpret_cast<const tflite::QuantizeOptionsT *>(value); |
15247 | return CreateQuantizeOptions(_fbb, ptr, _rehasher).Union(); |
15248 | } |
15249 | case BuiltinOptions_MatrixSetDiagOptions: { |
15250 | auto ptr = reinterpret_cast<const tflite::MatrixSetDiagOptionsT *>(value); |
15251 | return CreateMatrixSetDiagOptions(_fbb, ptr, _rehasher).Union(); |
15252 | } |
15253 | case BuiltinOptions_HardSwishOptions: { |
15254 | auto ptr = reinterpret_cast<const tflite::HardSwishOptionsT *>(value); |
15255 | return CreateHardSwishOptions(_fbb, ptr, _rehasher).Union(); |
15256 | } |
15257 | case BuiltinOptions_IfOptions: { |
15258 | auto ptr = reinterpret_cast<const tflite::IfOptionsT *>(value); |
15259 | return CreateIfOptions(_fbb, ptr, _rehasher).Union(); |
15260 | } |
15261 | case BuiltinOptions_WhileOptions: { |
15262 | auto ptr = reinterpret_cast<const tflite::WhileOptionsT *>(value); |
15263 | return CreateWhileOptions(_fbb, ptr, _rehasher).Union(); |
15264 | } |
15265 | case BuiltinOptions_DepthToSpaceOptions: { |
15266 | auto ptr = reinterpret_cast<const tflite::DepthToSpaceOptionsT *>(value); |
15267 | return CreateDepthToSpaceOptions(_fbb, ptr, _rehasher).Union(); |
15268 | } |
15269 | case BuiltinOptions_NonMaxSuppressionV4Options: { |
15270 | auto ptr = reinterpret_cast<const tflite::NonMaxSuppressionV4OptionsT *>(value); |
15271 | return CreateNonMaxSuppressionV4Options(_fbb, ptr, _rehasher).Union(); |
15272 | } |
15273 | case BuiltinOptions_NonMaxSuppressionV5Options: { |
15274 | auto ptr = reinterpret_cast<const tflite::NonMaxSuppressionV5OptionsT *>(value); |
15275 | return CreateNonMaxSuppressionV5Options(_fbb, ptr, _rehasher).Union(); |
15276 | } |
15277 | case BuiltinOptions_ScatterNdOptions: { |
15278 | auto ptr = reinterpret_cast<const tflite::ScatterNdOptionsT *>(value); |
15279 | return CreateScatterNdOptions(_fbb, ptr, _rehasher).Union(); |
15280 | } |
15281 | case BuiltinOptions_SelectV2Options: { |
15282 | auto ptr = reinterpret_cast<const tflite::SelectV2OptionsT *>(value); |
15283 | return CreateSelectV2Options(_fbb, ptr, _rehasher).Union(); |
15284 | } |
15285 | case BuiltinOptions_DensifyOptions: { |
15286 | auto ptr = reinterpret_cast<const tflite::DensifyOptionsT *>(value); |
15287 | return CreateDensifyOptions(_fbb, ptr, _rehasher).Union(); |
15288 | } |
15289 | case BuiltinOptions_SegmentSumOptions: { |
15290 | auto ptr = reinterpret_cast<const tflite::SegmentSumOptionsT *>(value); |
15291 | return CreateSegmentSumOptions(_fbb, ptr, _rehasher).Union(); |
15292 | } |
15293 | case BuiltinOptions_BatchMatMulOptions: { |
15294 | auto ptr = reinterpret_cast<const tflite::BatchMatMulOptionsT *>(value); |
15295 | return CreateBatchMatMulOptions(_fbb, ptr, _rehasher).Union(); |
15296 | } |
15297 | default: return 0; |
15298 | } |
15299 | } |
15300 | |
15301 | inline BuiltinOptionsUnion::BuiltinOptionsUnion(const BuiltinOptionsUnion &u) FLATBUFFERS_NOEXCEPT : type(u.type), value(nullptr) { |
15302 | switch (type) { |
15303 | case BuiltinOptions_Conv2DOptions: { |
15304 | value = new tflite::Conv2DOptionsT(*reinterpret_cast<tflite::Conv2DOptionsT *>(u.value)); |
15305 | break; |
15306 | } |
15307 | case BuiltinOptions_DepthwiseConv2DOptions: { |
15308 | value = new tflite::DepthwiseConv2DOptionsT(*reinterpret_cast<tflite::DepthwiseConv2DOptionsT *>(u.value)); |
15309 | break; |
15310 | } |
15311 | case BuiltinOptions_ConcatEmbeddingsOptions: { |
15312 | value = new tflite::ConcatEmbeddingsOptionsT(*reinterpret_cast<tflite::ConcatEmbeddingsOptionsT *>(u.value)); |
15313 | break; |
15314 | } |
15315 | case BuiltinOptions_LSHProjectionOptions: { |
15316 | value = new tflite::LSHProjectionOptionsT(*reinterpret_cast<tflite::LSHProjectionOptionsT *>(u.value)); |
15317 | break; |
15318 | } |
15319 | case BuiltinOptions_Pool2DOptions: { |
15320 | value = new tflite::Pool2DOptionsT(*reinterpret_cast<tflite::Pool2DOptionsT *>(u.value)); |
15321 | break; |
15322 | } |
15323 | case BuiltinOptions_SVDFOptions: { |
15324 | value = new tflite::SVDFOptionsT(*reinterpret_cast<tflite::SVDFOptionsT *>(u.value)); |
15325 | break; |
15326 | } |
15327 | case BuiltinOptions_RNNOptions: { |
15328 | value = new tflite::RNNOptionsT(*reinterpret_cast<tflite::RNNOptionsT *>(u.value)); |
15329 | break; |
15330 | } |
15331 | case BuiltinOptions_FullyConnectedOptions: { |
15332 | value = new tflite::FullyConnectedOptionsT(*reinterpret_cast<tflite::FullyConnectedOptionsT *>(u.value)); |
15333 | break; |
15334 | } |
15335 | case BuiltinOptions_SoftmaxOptions: { |
15336 | value = new tflite::SoftmaxOptionsT(*reinterpret_cast<tflite::SoftmaxOptionsT *>(u.value)); |
15337 | break; |
15338 | } |
15339 | case BuiltinOptions_ConcatenationOptions: { |
15340 | value = new tflite::ConcatenationOptionsT(*reinterpret_cast<tflite::ConcatenationOptionsT *>(u.value)); |
15341 | break; |
15342 | } |
15343 | case BuiltinOptions_AddOptions: { |
15344 | value = new tflite::AddOptionsT(*reinterpret_cast<tflite::AddOptionsT *>(u.value)); |
15345 | break; |
15346 | } |
15347 | case BuiltinOptions_L2NormOptions: { |
15348 | value = new tflite::L2NormOptionsT(*reinterpret_cast<tflite::L2NormOptionsT *>(u.value)); |
15349 | break; |
15350 | } |
15351 | case BuiltinOptions_LocalResponseNormalizationOptions: { |
15352 | value = new tflite::LocalResponseNormalizationOptionsT(*reinterpret_cast<tflite::LocalResponseNormalizationOptionsT *>(u.value)); |
15353 | break; |
15354 | } |
15355 | case BuiltinOptions_LSTMOptions: { |
15356 | value = new tflite::LSTMOptionsT(*reinterpret_cast<tflite::LSTMOptionsT *>(u.value)); |
15357 | break; |
15358 | } |
15359 | case BuiltinOptions_ResizeBilinearOptions: { |
15360 | value = new tflite::ResizeBilinearOptionsT(*reinterpret_cast<tflite::ResizeBilinearOptionsT *>(u.value)); |
15361 | break; |
15362 | } |
15363 | case BuiltinOptions_CallOptions: { |
15364 | value = new tflite::CallOptionsT(*reinterpret_cast<tflite::CallOptionsT *>(u.value)); |
15365 | break; |
15366 | } |
15367 | case BuiltinOptions_ReshapeOptions: { |
15368 | value = new tflite::ReshapeOptionsT(*reinterpret_cast<tflite::ReshapeOptionsT *>(u.value)); |
15369 | break; |
15370 | } |
15371 | case BuiltinOptions_SkipGramOptions: { |
15372 | value = new tflite::SkipGramOptionsT(*reinterpret_cast<tflite::SkipGramOptionsT *>(u.value)); |
15373 | break; |
15374 | } |
15375 | case BuiltinOptions_SpaceToDepthOptions: { |
15376 | value = new tflite::SpaceToDepthOptionsT(*reinterpret_cast<tflite::SpaceToDepthOptionsT *>(u.value)); |
15377 | break; |
15378 | } |
15379 | case BuiltinOptions_EmbeddingLookupSparseOptions: { |
15380 | value = new tflite::EmbeddingLookupSparseOptionsT(*reinterpret_cast<tflite::EmbeddingLookupSparseOptionsT *>(u.value)); |
15381 | break; |
15382 | } |
15383 | case BuiltinOptions_MulOptions: { |
15384 | value = new tflite::MulOptionsT(*reinterpret_cast<tflite::MulOptionsT *>(u.value)); |
15385 | break; |
15386 | } |
15387 | case BuiltinOptions_PadOptions: { |
15388 | value = new tflite::PadOptionsT(*reinterpret_cast<tflite::PadOptionsT *>(u.value)); |
15389 | break; |
15390 | } |
15391 | case BuiltinOptions_GatherOptions: { |
15392 | value = new tflite::GatherOptionsT(*reinterpret_cast<tflite::GatherOptionsT *>(u.value)); |
15393 | break; |
15394 | } |
15395 | case BuiltinOptions_BatchToSpaceNDOptions: { |
15396 | value = new tflite::BatchToSpaceNDOptionsT(*reinterpret_cast<tflite::BatchToSpaceNDOptionsT *>(u.value)); |
15397 | break; |
15398 | } |
15399 | case BuiltinOptions_SpaceToBatchNDOptions: { |
15400 | value = new tflite::SpaceToBatchNDOptionsT(*reinterpret_cast<tflite::SpaceToBatchNDOptionsT *>(u.value)); |
15401 | break; |
15402 | } |
15403 | case BuiltinOptions_TransposeOptions: { |
15404 | value = new tflite::TransposeOptionsT(*reinterpret_cast<tflite::TransposeOptionsT *>(u.value)); |
15405 | break; |
15406 | } |
15407 | case BuiltinOptions_ReducerOptions: { |
15408 | value = new tflite::ReducerOptionsT(*reinterpret_cast<tflite::ReducerOptionsT *>(u.value)); |
15409 | break; |
15410 | } |
15411 | case BuiltinOptions_SubOptions: { |
15412 | value = new tflite::SubOptionsT(*reinterpret_cast<tflite::SubOptionsT *>(u.value)); |
15413 | break; |
15414 | } |
15415 | case BuiltinOptions_DivOptions: { |
15416 | value = new tflite::DivOptionsT(*reinterpret_cast<tflite::DivOptionsT *>(u.value)); |
15417 | break; |
15418 | } |
15419 | case BuiltinOptions_SqueezeOptions: { |
15420 | value = new tflite::SqueezeOptionsT(*reinterpret_cast<tflite::SqueezeOptionsT *>(u.value)); |
15421 | break; |
15422 | } |
15423 | case BuiltinOptions_SequenceRNNOptions: { |
15424 | value = new tflite::SequenceRNNOptionsT(*reinterpret_cast<tflite::SequenceRNNOptionsT *>(u.value)); |
15425 | break; |
15426 | } |
15427 | case BuiltinOptions_StridedSliceOptions: { |
15428 | value = new tflite::StridedSliceOptionsT(*reinterpret_cast<tflite::StridedSliceOptionsT *>(u.value)); |
15429 | break; |
15430 | } |
15431 | case BuiltinOptions_ExpOptions: { |
15432 | value = new tflite::ExpOptionsT(*reinterpret_cast<tflite::ExpOptionsT *>(u.value)); |
15433 | break; |
15434 | } |
15435 | case BuiltinOptions_TopKV2Options: { |
15436 | value = new tflite::TopKV2OptionsT(*reinterpret_cast<tflite::TopKV2OptionsT *>(u.value)); |
15437 | break; |
15438 | } |
15439 | case BuiltinOptions_SplitOptions: { |
15440 | value = new tflite::SplitOptionsT(*reinterpret_cast<tflite::SplitOptionsT *>(u.value)); |
15441 | break; |
15442 | } |
15443 | case BuiltinOptions_LogSoftmaxOptions: { |
15444 | value = new tflite::LogSoftmaxOptionsT(*reinterpret_cast<tflite::LogSoftmaxOptionsT *>(u.value)); |
15445 | break; |
15446 | } |
15447 | case BuiltinOptions_CastOptions: { |
15448 | value = new tflite::CastOptionsT(*reinterpret_cast<tflite::CastOptionsT *>(u.value)); |
15449 | break; |
15450 | } |
15451 | case BuiltinOptions_DequantizeOptions: { |
15452 | value = new tflite::DequantizeOptionsT(*reinterpret_cast<tflite::DequantizeOptionsT *>(u.value)); |
15453 | break; |
15454 | } |
15455 | case BuiltinOptions_MaximumMinimumOptions: { |
15456 | value = new tflite::MaximumMinimumOptionsT(*reinterpret_cast<tflite::MaximumMinimumOptionsT *>(u.value)); |
15457 | break; |
15458 | } |
15459 | case BuiltinOptions_ArgMaxOptions: { |
15460 | value = new tflite::ArgMaxOptionsT(*reinterpret_cast<tflite::ArgMaxOptionsT *>(u.value)); |
15461 | break; |
15462 | } |
15463 | case BuiltinOptions_LessOptions: { |
15464 | value = new tflite::LessOptionsT(*reinterpret_cast<tflite::LessOptionsT *>(u.value)); |
15465 | break; |
15466 | } |
15467 | case BuiltinOptions_NegOptions: { |
15468 | value = new tflite::NegOptionsT(*reinterpret_cast<tflite::NegOptionsT *>(u.value)); |
15469 | break; |
15470 | } |
15471 | case BuiltinOptions_PadV2Options: { |
15472 | value = new tflite::PadV2OptionsT(*reinterpret_cast<tflite::PadV2OptionsT *>(u.value)); |
15473 | break; |
15474 | } |
15475 | case BuiltinOptions_GreaterOptions: { |
15476 | value = new tflite::GreaterOptionsT(*reinterpret_cast<tflite::GreaterOptionsT *>(u.value)); |
15477 | break; |
15478 | } |
15479 | case BuiltinOptions_GreaterEqualOptions: { |
15480 | value = new tflite::GreaterEqualOptionsT(*reinterpret_cast<tflite::GreaterEqualOptionsT *>(u.value)); |
15481 | break; |
15482 | } |
15483 | case BuiltinOptions_LessEqualOptions: { |
15484 | value = new tflite::LessEqualOptionsT(*reinterpret_cast<tflite::LessEqualOptionsT *>(u.value)); |
15485 | break; |
15486 | } |
15487 | case BuiltinOptions_SelectOptions: { |
15488 | value = new tflite::SelectOptionsT(*reinterpret_cast<tflite::SelectOptionsT *>(u.value)); |
15489 | break; |
15490 | } |
15491 | case BuiltinOptions_SliceOptions: { |
15492 | value = new tflite::SliceOptionsT(*reinterpret_cast<tflite::SliceOptionsT *>(u.value)); |
15493 | break; |
15494 | } |
15495 | case BuiltinOptions_TransposeConvOptions: { |
15496 | value = new tflite::TransposeConvOptionsT(*reinterpret_cast<tflite::TransposeConvOptionsT *>(u.value)); |
15497 | break; |
15498 | } |
15499 | case BuiltinOptions_SparseToDenseOptions: { |
15500 | value = new tflite::SparseToDenseOptionsT(*reinterpret_cast<tflite::SparseToDenseOptionsT *>(u.value)); |
15501 | break; |
15502 | } |
15503 | case BuiltinOptions_TileOptions: { |
15504 | value = new tflite::TileOptionsT(*reinterpret_cast<tflite::TileOptionsT *>(u.value)); |
15505 | break; |
15506 | } |
15507 | case BuiltinOptions_ExpandDimsOptions: { |
15508 | value = new tflite::ExpandDimsOptionsT(*reinterpret_cast<tflite::ExpandDimsOptionsT *>(u.value)); |
15509 | break; |
15510 | } |
15511 | case BuiltinOptions_EqualOptions: { |
15512 | value = new tflite::EqualOptionsT(*reinterpret_cast<tflite::EqualOptionsT *>(u.value)); |
15513 | break; |
15514 | } |
15515 | case BuiltinOptions_NotEqualOptions: { |
15516 | value = new tflite::NotEqualOptionsT(*reinterpret_cast<tflite::NotEqualOptionsT *>(u.value)); |
15517 | break; |
15518 | } |
15519 | case BuiltinOptions_ShapeOptions: { |
15520 | value = new tflite::ShapeOptionsT(*reinterpret_cast<tflite::ShapeOptionsT *>(u.value)); |
15521 | break; |
15522 | } |
15523 | case BuiltinOptions_PowOptions: { |
15524 | value = new tflite::PowOptionsT(*reinterpret_cast<tflite::PowOptionsT *>(u.value)); |
15525 | break; |
15526 | } |
15527 | case BuiltinOptions_ArgMinOptions: { |
15528 | value = new tflite::ArgMinOptionsT(*reinterpret_cast<tflite::ArgMinOptionsT *>(u.value)); |
15529 | break; |
15530 | } |
15531 | case BuiltinOptions_FakeQuantOptions: { |
15532 | value = new tflite::FakeQuantOptionsT(*reinterpret_cast<tflite::FakeQuantOptionsT *>(u.value)); |
15533 | break; |
15534 | } |
15535 | case BuiltinOptions_PackOptions: { |
15536 | value = new tflite::PackOptionsT(*reinterpret_cast<tflite::PackOptionsT *>(u.value)); |
15537 | break; |
15538 | } |
15539 | case BuiltinOptions_LogicalOrOptions: { |
15540 | value = new tflite::LogicalOrOptionsT(*reinterpret_cast<tflite::LogicalOrOptionsT *>(u.value)); |
15541 | break; |
15542 | } |
15543 | case BuiltinOptions_OneHotOptions: { |
15544 | value = new tflite::OneHotOptionsT(*reinterpret_cast<tflite::OneHotOptionsT *>(u.value)); |
15545 | break; |
15546 | } |
15547 | case BuiltinOptions_LogicalAndOptions: { |
15548 | value = new tflite::LogicalAndOptionsT(*reinterpret_cast<tflite::LogicalAndOptionsT *>(u.value)); |
15549 | break; |
15550 | } |
15551 | case BuiltinOptions_LogicalNotOptions: { |
15552 | value = new tflite::LogicalNotOptionsT(*reinterpret_cast<tflite::LogicalNotOptionsT *>(u.value)); |
15553 | break; |
15554 | } |
15555 | case BuiltinOptions_UnpackOptions: { |
15556 | value = new tflite::UnpackOptionsT(*reinterpret_cast<tflite::UnpackOptionsT *>(u.value)); |
15557 | break; |
15558 | } |
15559 | case BuiltinOptions_FloorDivOptions: { |
15560 | value = new tflite::FloorDivOptionsT(*reinterpret_cast<tflite::FloorDivOptionsT *>(u.value)); |
15561 | break; |
15562 | } |
15563 | case BuiltinOptions_SquareOptions: { |
15564 | value = new tflite::SquareOptionsT(*reinterpret_cast<tflite::SquareOptionsT *>(u.value)); |
15565 | break; |
15566 | } |
15567 | case BuiltinOptions_ZerosLikeOptions: { |
15568 | value = new tflite::ZerosLikeOptionsT(*reinterpret_cast<tflite::ZerosLikeOptionsT *>(u.value)); |
15569 | break; |
15570 | } |
15571 | case BuiltinOptions_FillOptions: { |
15572 | value = new tflite::FillOptionsT(*reinterpret_cast<tflite::FillOptionsT *>(u.value)); |
15573 | break; |
15574 | } |
15575 | case BuiltinOptions_BidirectionalSequenceLSTMOptions: { |
15576 | value = new tflite::BidirectionalSequenceLSTMOptionsT(*reinterpret_cast<tflite::BidirectionalSequenceLSTMOptionsT *>(u.value)); |
15577 | break; |
15578 | } |
15579 | case BuiltinOptions_BidirectionalSequenceRNNOptions: { |
15580 | value = new tflite::BidirectionalSequenceRNNOptionsT(*reinterpret_cast<tflite::BidirectionalSequenceRNNOptionsT *>(u.value)); |
15581 | break; |
15582 | } |
15583 | case BuiltinOptions_UnidirectionalSequenceLSTMOptions: { |
15584 | value = new tflite::UnidirectionalSequenceLSTMOptionsT(*reinterpret_cast<tflite::UnidirectionalSequenceLSTMOptionsT *>(u.value)); |
15585 | break; |
15586 | } |
15587 | case BuiltinOptions_FloorModOptions: { |
15588 | value = new tflite::FloorModOptionsT(*reinterpret_cast<tflite::FloorModOptionsT *>(u.value)); |
15589 | break; |
15590 | } |
15591 | case BuiltinOptions_RangeOptions: { |
15592 | value = new tflite::RangeOptionsT(*reinterpret_cast<tflite::RangeOptionsT *>(u.value)); |
15593 | break; |
15594 | } |
15595 | case BuiltinOptions_ResizeNearestNeighborOptions: { |
15596 | value = new tflite::ResizeNearestNeighborOptionsT(*reinterpret_cast<tflite::ResizeNearestNeighborOptionsT *>(u.value)); |
15597 | break; |
15598 | } |
15599 | case BuiltinOptions_LeakyReluOptions: { |
15600 | value = new tflite::LeakyReluOptionsT(*reinterpret_cast<tflite::LeakyReluOptionsT *>(u.value)); |
15601 | break; |
15602 | } |
15603 | case BuiltinOptions_SquaredDifferenceOptions: { |
15604 | value = new tflite::SquaredDifferenceOptionsT(*reinterpret_cast<tflite::SquaredDifferenceOptionsT *>(u.value)); |
15605 | break; |
15606 | } |
15607 | case BuiltinOptions_MirrorPadOptions: { |
15608 | value = new tflite::MirrorPadOptionsT(*reinterpret_cast<tflite::MirrorPadOptionsT *>(u.value)); |
15609 | break; |
15610 | } |
15611 | case BuiltinOptions_AbsOptions: { |
15612 | value = new tflite::AbsOptionsT(*reinterpret_cast<tflite::AbsOptionsT *>(u.value)); |
15613 | break; |
15614 | } |
15615 | case BuiltinOptions_SplitVOptions: { |
15616 | value = new tflite::SplitVOptionsT(*reinterpret_cast<tflite::SplitVOptionsT *>(u.value)); |
15617 | break; |
15618 | } |
15619 | case BuiltinOptions_UniqueOptions: { |
15620 | value = new tflite::UniqueOptionsT(*reinterpret_cast<tflite::UniqueOptionsT *>(u.value)); |
15621 | break; |
15622 | } |
15623 | case BuiltinOptions_ReverseV2Options: { |
15624 | value = new tflite::ReverseV2OptionsT(*reinterpret_cast<tflite::ReverseV2OptionsT *>(u.value)); |
15625 | break; |
15626 | } |
15627 | case BuiltinOptions_AddNOptions: { |
15628 | value = new tflite::AddNOptionsT(*reinterpret_cast<tflite::AddNOptionsT *>(u.value)); |
15629 | break; |
15630 | } |
15631 | case BuiltinOptions_GatherNdOptions: { |
15632 | value = new tflite::GatherNdOptionsT(*reinterpret_cast<tflite::GatherNdOptionsT *>(u.value)); |
15633 | break; |
15634 | } |
15635 | case BuiltinOptions_CosOptions: { |
15636 | value = new tflite::CosOptionsT(*reinterpret_cast<tflite::CosOptionsT *>(u.value)); |
15637 | break; |
15638 | } |
15639 | case BuiltinOptions_WhereOptions: { |
15640 | value = new tflite::WhereOptionsT(*reinterpret_cast<tflite::WhereOptionsT *>(u.value)); |
15641 | break; |
15642 | } |
15643 | case BuiltinOptions_RankOptions: { |
15644 | value = new tflite::RankOptionsT(*reinterpret_cast<tflite::RankOptionsT *>(u.value)); |
15645 | break; |
15646 | } |
15647 | case BuiltinOptions_ReverseSequenceOptions: { |
15648 | value = new tflite::ReverseSequenceOptionsT(*reinterpret_cast<tflite::ReverseSequenceOptionsT *>(u.value)); |
15649 | break; |
15650 | } |
15651 | case BuiltinOptions_MatrixDiagOptions: { |
15652 | value = new tflite::MatrixDiagOptionsT(*reinterpret_cast<tflite::MatrixDiagOptionsT *>(u.value)); |
15653 | break; |
15654 | } |
15655 | case BuiltinOptions_QuantizeOptions: { |
15656 | value = new tflite::QuantizeOptionsT(*reinterpret_cast<tflite::QuantizeOptionsT *>(u.value)); |
15657 | break; |
15658 | } |
15659 | case BuiltinOptions_MatrixSetDiagOptions: { |
15660 | value = new tflite::MatrixSetDiagOptionsT(*reinterpret_cast<tflite::MatrixSetDiagOptionsT *>(u.value)); |
15661 | break; |
15662 | } |
15663 | case BuiltinOptions_HardSwishOptions: { |
15664 | value = new tflite::HardSwishOptionsT(*reinterpret_cast<tflite::HardSwishOptionsT *>(u.value)); |
15665 | break; |
15666 | } |
15667 | case BuiltinOptions_IfOptions: { |
15668 | value = new tflite::IfOptionsT(*reinterpret_cast<tflite::IfOptionsT *>(u.value)); |
15669 | break; |
15670 | } |
15671 | case BuiltinOptions_WhileOptions: { |
15672 | value = new tflite::WhileOptionsT(*reinterpret_cast<tflite::WhileOptionsT *>(u.value)); |
15673 | break; |
15674 | } |
15675 | case BuiltinOptions_DepthToSpaceOptions: { |
15676 | value = new tflite::DepthToSpaceOptionsT(*reinterpret_cast<tflite::DepthToSpaceOptionsT *>(u.value)); |
15677 | break; |
15678 | } |
15679 | case BuiltinOptions_NonMaxSuppressionV4Options: { |
15680 | value = new tflite::NonMaxSuppressionV4OptionsT(*reinterpret_cast<tflite::NonMaxSuppressionV4OptionsT *>(u.value)); |
15681 | break; |
15682 | } |
15683 | case BuiltinOptions_NonMaxSuppressionV5Options: { |
15684 | value = new tflite::NonMaxSuppressionV5OptionsT(*reinterpret_cast<tflite::NonMaxSuppressionV5OptionsT *>(u.value)); |
15685 | break; |
15686 | } |
15687 | case BuiltinOptions_ScatterNdOptions: { |
15688 | value = new tflite::ScatterNdOptionsT(*reinterpret_cast<tflite::ScatterNdOptionsT *>(u.value)); |
15689 | break; |
15690 | } |
15691 | case BuiltinOptions_SelectV2Options: { |
15692 | value = new tflite::SelectV2OptionsT(*reinterpret_cast<tflite::SelectV2OptionsT *>(u.value)); |
15693 | break; |
15694 | } |
15695 | case BuiltinOptions_DensifyOptions: { |
15696 | value = new tflite::DensifyOptionsT(*reinterpret_cast<tflite::DensifyOptionsT *>(u.value)); |
15697 | break; |
15698 | } |
15699 | case BuiltinOptions_SegmentSumOptions: { |
15700 | value = new tflite::SegmentSumOptionsT(*reinterpret_cast<tflite::SegmentSumOptionsT *>(u.value)); |
15701 | break; |
15702 | } |
15703 | case BuiltinOptions_BatchMatMulOptions: { |
15704 | value = new tflite::BatchMatMulOptionsT(*reinterpret_cast<tflite::BatchMatMulOptionsT *>(u.value)); |
15705 | break; |
15706 | } |
15707 | default: |
15708 | break; |
15709 | } |
15710 | } |
15711 | |
15712 | inline void BuiltinOptionsUnion::Reset() { |
15713 | switch (type) { |
15714 | case BuiltinOptions_Conv2DOptions: { |
15715 | auto ptr = reinterpret_cast<tflite::Conv2DOptionsT *>(value); |
15716 | delete ptr; |
15717 | break; |
15718 | } |
15719 | case BuiltinOptions_DepthwiseConv2DOptions: { |
15720 | auto ptr = reinterpret_cast<tflite::DepthwiseConv2DOptionsT *>(value); |
15721 | delete ptr; |
15722 | break; |
15723 | } |
15724 | case BuiltinOptions_ConcatEmbeddingsOptions: { |
15725 | auto ptr = reinterpret_cast<tflite::ConcatEmbeddingsOptionsT *>(value); |
15726 | delete ptr; |
15727 | break; |
15728 | } |
15729 | case BuiltinOptions_LSHProjectionOptions: { |
15730 | auto ptr = reinterpret_cast<tflite::LSHProjectionOptionsT *>(value); |
15731 | delete ptr; |
15732 | break; |
15733 | } |
15734 | case BuiltinOptions_Pool2DOptions: { |
15735 | auto ptr = reinterpret_cast<tflite::Pool2DOptionsT *>(value); |
15736 | delete ptr; |
15737 | break; |
15738 | } |
15739 | case BuiltinOptions_SVDFOptions: { |
15740 | auto ptr = reinterpret_cast<tflite::SVDFOptionsT *>(value); |
15741 | delete ptr; |
15742 | break; |
15743 | } |
15744 | case BuiltinOptions_RNNOptions: { |
15745 | auto ptr = reinterpret_cast<tflite::RNNOptionsT *>(value); |
15746 | delete ptr; |
15747 | break; |
15748 | } |
15749 | case BuiltinOptions_FullyConnectedOptions: { |
15750 | auto ptr = reinterpret_cast<tflite::FullyConnectedOptionsT *>(value); |
15751 | delete ptr; |
15752 | break; |
15753 | } |
15754 | case BuiltinOptions_SoftmaxOptions: { |
15755 | auto ptr = reinterpret_cast<tflite::SoftmaxOptionsT *>(value); |
15756 | delete ptr; |
15757 | break; |
15758 | } |
15759 | case BuiltinOptions_ConcatenationOptions: { |
15760 | auto ptr = reinterpret_cast<tflite::ConcatenationOptionsT *>(value); |
15761 | delete ptr; |
15762 | break; |
15763 | } |
15764 | case BuiltinOptions_AddOptions: { |
15765 | auto ptr = reinterpret_cast<tflite::AddOptionsT *>(value); |
15766 | delete ptr; |
15767 | break; |
15768 | } |
15769 | case BuiltinOptions_L2NormOptions: { |
15770 | auto ptr = reinterpret_cast<tflite::L2NormOptionsT *>(value); |
15771 | delete ptr; |
15772 | break; |
15773 | } |
15774 | case BuiltinOptions_LocalResponseNormalizationOptions: { |
15775 | auto ptr = reinterpret_cast<tflite::LocalResponseNormalizationOptionsT *>(value); |
15776 | delete ptr; |
15777 | break; |
15778 | } |
15779 | case BuiltinOptions_LSTMOptions: { |
15780 | auto ptr = reinterpret_cast<tflite::LSTMOptionsT *>(value); |
15781 | delete ptr; |
15782 | break; |
15783 | } |
15784 | case BuiltinOptions_ResizeBilinearOptions: { |
15785 | auto ptr = reinterpret_cast<tflite::ResizeBilinearOptionsT *>(value); |
15786 | delete ptr; |
15787 | break; |
15788 | } |
15789 | case BuiltinOptions_CallOptions: { |
15790 | auto ptr = reinterpret_cast<tflite::CallOptionsT *>(value); |
15791 | delete ptr; |
15792 | break; |
15793 | } |
15794 | case BuiltinOptions_ReshapeOptions: { |
15795 | auto ptr = reinterpret_cast<tflite::ReshapeOptionsT *>(value); |
15796 | delete ptr; |
15797 | break; |
15798 | } |
15799 | case BuiltinOptions_SkipGramOptions: { |
15800 | auto ptr = reinterpret_cast<tflite::SkipGramOptionsT *>(value); |
15801 | delete ptr; |
15802 | break; |
15803 | } |
15804 | case BuiltinOptions_SpaceToDepthOptions: { |
15805 | auto ptr = reinterpret_cast<tflite::SpaceToDepthOptionsT *>(value); |
15806 | delete ptr; |
15807 | break; |
15808 | } |
15809 | case BuiltinOptions_EmbeddingLookupSparseOptions: { |
15810 | auto ptr = reinterpret_cast<tflite::EmbeddingLookupSparseOptionsT *>(value); |
15811 | delete ptr; |
15812 | break; |
15813 | } |
15814 | case BuiltinOptions_MulOptions: { |
15815 | auto ptr = reinterpret_cast<tflite::MulOptionsT *>(value); |
15816 | delete ptr; |
15817 | break; |
15818 | } |
15819 | case BuiltinOptions_PadOptions: { |
15820 | auto ptr = reinterpret_cast<tflite::PadOptionsT *>(value); |
15821 | delete ptr; |
15822 | break; |
15823 | } |
15824 | case BuiltinOptions_GatherOptions: { |
15825 | auto ptr = reinterpret_cast<tflite::GatherOptionsT *>(value); |
15826 | delete ptr; |
15827 | break; |
15828 | } |
15829 | case BuiltinOptions_BatchToSpaceNDOptions: { |
15830 | auto ptr = reinterpret_cast<tflite::BatchToSpaceNDOptionsT *>(value); |
15831 | delete ptr; |
15832 | break; |
15833 | } |
15834 | case BuiltinOptions_SpaceToBatchNDOptions: { |
15835 | auto ptr = reinterpret_cast<tflite::SpaceToBatchNDOptionsT *>(value); |
15836 | delete ptr; |
15837 | break; |
15838 | } |
15839 | case BuiltinOptions_TransposeOptions: { |
15840 | auto ptr = reinterpret_cast<tflite::TransposeOptionsT *>(value); |
15841 | delete ptr; |
15842 | break; |
15843 | } |
15844 | case BuiltinOptions_ReducerOptions: { |
15845 | auto ptr = reinterpret_cast<tflite::ReducerOptionsT *>(value); |
15846 | delete ptr; |
15847 | break; |
15848 | } |
15849 | case BuiltinOptions_SubOptions: { |
15850 | auto ptr = reinterpret_cast<tflite::SubOptionsT *>(value); |
15851 | delete ptr; |
15852 | break; |
15853 | } |
15854 | case BuiltinOptions_DivOptions: { |
15855 | auto ptr = reinterpret_cast<tflite::DivOptionsT *>(value); |
15856 | delete ptr; |
15857 | break; |
15858 | } |
15859 | case BuiltinOptions_SqueezeOptions: { |
15860 | auto ptr = reinterpret_cast<tflite::SqueezeOptionsT *>(value); |
15861 | delete ptr; |
15862 | break; |
15863 | } |
15864 | case BuiltinOptions_SequenceRNNOptions: { |
15865 | auto ptr = reinterpret_cast<tflite::SequenceRNNOptionsT *>(value); |
15866 | delete ptr; |
15867 | break; |
15868 | } |
15869 | case BuiltinOptions_StridedSliceOptions: { |
15870 | auto ptr = reinterpret_cast<tflite::StridedSliceOptionsT *>(value); |
15871 | delete ptr; |
15872 | break; |
15873 | } |
15874 | case BuiltinOptions_ExpOptions: { |
15875 | auto ptr = reinterpret_cast<tflite::ExpOptionsT *>(value); |
15876 | delete ptr; |
15877 | break; |
15878 | } |
15879 | case BuiltinOptions_TopKV2Options: { |
15880 | auto ptr = reinterpret_cast<tflite::TopKV2OptionsT *>(value); |
15881 | delete ptr; |
15882 | break; |
15883 | } |
15884 | case BuiltinOptions_SplitOptions: { |
15885 | auto ptr = reinterpret_cast<tflite::SplitOptionsT *>(value); |
15886 | delete ptr; |
15887 | break; |
15888 | } |
15889 | case BuiltinOptions_LogSoftmaxOptions: { |
15890 | auto ptr = reinterpret_cast<tflite::LogSoftmaxOptionsT *>(value); |
15891 | delete ptr; |
15892 | break; |
15893 | } |
15894 | case BuiltinOptions_CastOptions: { |
15895 | auto ptr = reinterpret_cast<tflite::CastOptionsT *>(value); |
15896 | delete ptr; |
15897 | break; |
15898 | } |
15899 | case BuiltinOptions_DequantizeOptions: { |
15900 | auto ptr = reinterpret_cast<tflite::DequantizeOptionsT *>(value); |
15901 | delete ptr; |
15902 | break; |
15903 | } |
15904 | case BuiltinOptions_MaximumMinimumOptions: { |
15905 | auto ptr = reinterpret_cast<tflite::MaximumMinimumOptionsT *>(value); |
15906 | delete ptr; |
15907 | break; |
15908 | } |
15909 | case BuiltinOptions_ArgMaxOptions: { |
15910 | auto ptr = reinterpret_cast<tflite::ArgMaxOptionsT *>(value); |
15911 | delete ptr; |
15912 | break; |
15913 | } |
15914 | case BuiltinOptions_LessOptions: { |
15915 | auto ptr = reinterpret_cast<tflite::LessOptionsT *>(value); |
15916 | delete ptr; |
15917 | break; |
15918 | } |
15919 | case BuiltinOptions_NegOptions: { |
15920 | auto ptr = reinterpret_cast<tflite::NegOptionsT *>(value); |
15921 | delete ptr; |
15922 | break; |
15923 | } |
15924 | case BuiltinOptions_PadV2Options: { |
15925 | auto ptr = reinterpret_cast<tflite::PadV2OptionsT *>(value); |
15926 | delete ptr; |
15927 | break; |
15928 | } |
15929 | case BuiltinOptions_GreaterOptions: { |
15930 | auto ptr = reinterpret_cast<tflite::GreaterOptionsT *>(value); |
15931 | delete ptr; |
15932 | break; |
15933 | } |
15934 | case BuiltinOptions_GreaterEqualOptions: { |
15935 | auto ptr = reinterpret_cast<tflite::GreaterEqualOptionsT *>(value); |
15936 | delete ptr; |
15937 | break; |
15938 | } |
15939 | case BuiltinOptions_LessEqualOptions: { |
15940 | auto ptr = reinterpret_cast<tflite::LessEqualOptionsT *>(value); |
15941 | delete ptr; |
15942 | break; |
15943 | } |
15944 | case BuiltinOptions_SelectOptions: { |
15945 | auto ptr = reinterpret_cast<tflite::SelectOptionsT *>(value); |
15946 | delete ptr; |
15947 | break; |
15948 | } |
15949 | case BuiltinOptions_SliceOptions: { |
15950 | auto ptr = reinterpret_cast<tflite::SliceOptionsT *>(value); |
15951 | delete ptr; |
15952 | break; |
15953 | } |
15954 | case BuiltinOptions_TransposeConvOptions: { |
15955 | auto ptr = reinterpret_cast<tflite::TransposeConvOptionsT *>(value); |
15956 | delete ptr; |
15957 | break; |
15958 | } |
15959 | case BuiltinOptions_SparseToDenseOptions: { |
15960 | auto ptr = reinterpret_cast<tflite::SparseToDenseOptionsT *>(value); |
15961 | delete ptr; |
15962 | break; |
15963 | } |
15964 | case BuiltinOptions_TileOptions: { |
15965 | auto ptr = reinterpret_cast<tflite::TileOptionsT *>(value); |
15966 | delete ptr; |
15967 | break; |
15968 | } |
15969 | case BuiltinOptions_ExpandDimsOptions: { |
15970 | auto ptr = reinterpret_cast<tflite::ExpandDimsOptionsT *>(value); |
15971 | delete ptr; |
15972 | break; |
15973 | } |
15974 | case BuiltinOptions_EqualOptions: { |
15975 | auto ptr = reinterpret_cast<tflite::EqualOptionsT *>(value); |
15976 | delete ptr; |
15977 | break; |
15978 | } |
15979 | case BuiltinOptions_NotEqualOptions: { |
15980 | auto ptr = reinterpret_cast<tflite::NotEqualOptionsT *>(value); |
15981 | delete ptr; |
15982 | break; |
15983 | } |
15984 | case BuiltinOptions_ShapeOptions: { |
15985 | auto ptr = reinterpret_cast<tflite::ShapeOptionsT *>(value); |
15986 | delete ptr; |
15987 | break; |
15988 | } |
15989 | case BuiltinOptions_PowOptions: { |
15990 | auto ptr = reinterpret_cast<tflite::PowOptionsT *>(value); |
15991 | delete ptr; |
15992 | break; |
15993 | } |
15994 | case BuiltinOptions_ArgMinOptions: { |
15995 | auto ptr = reinterpret_cast<tflite::ArgMinOptionsT *>(value); |
15996 | delete ptr; |
15997 | break; |
15998 | } |
15999 | case BuiltinOptions_FakeQuantOptions: { |
16000 | auto ptr = reinterpret_cast<tflite::FakeQuantOptionsT *>(value); |
16001 | delete ptr; |
16002 | break; |
16003 | } |
16004 | case BuiltinOptions_PackOptions: { |
16005 | auto ptr = reinterpret_cast<tflite::PackOptionsT *>(value); |
16006 | delete ptr; |
16007 | break; |
16008 | } |
16009 | case BuiltinOptions_LogicalOrOptions: { |
16010 | auto ptr = reinterpret_cast<tflite::LogicalOrOptionsT *>(value); |
16011 | delete ptr; |
16012 | break; |
16013 | } |
16014 | case BuiltinOptions_OneHotOptions: { |
16015 | auto ptr = reinterpret_cast<tflite::OneHotOptionsT *>(value); |
16016 | delete ptr; |
16017 | break; |
16018 | } |
16019 | case BuiltinOptions_LogicalAndOptions: { |
16020 | auto ptr = reinterpret_cast<tflite::LogicalAndOptionsT *>(value); |
16021 | delete ptr; |
16022 | break; |
16023 | } |
16024 | case BuiltinOptions_LogicalNotOptions: { |
16025 | auto ptr = reinterpret_cast<tflite::LogicalNotOptionsT *>(value); |
16026 | delete ptr; |
16027 | break; |
16028 | } |
16029 | case BuiltinOptions_UnpackOptions: { |
16030 | auto ptr = reinterpret_cast<tflite::UnpackOptionsT *>(value); |
16031 | delete ptr; |
16032 | break; |
16033 | } |
16034 | case BuiltinOptions_FloorDivOptions: { |
16035 | auto ptr = reinterpret_cast<tflite::FloorDivOptionsT *>(value); |
16036 | delete ptr; |
16037 | break; |
16038 | } |
16039 | case BuiltinOptions_SquareOptions: { |
16040 | auto ptr = reinterpret_cast<tflite::SquareOptionsT *>(value); |
16041 | delete ptr; |
16042 | break; |
16043 | } |
16044 | case BuiltinOptions_ZerosLikeOptions: { |
16045 | auto ptr = reinterpret_cast<tflite::ZerosLikeOptionsT *>(value); |
16046 | delete ptr; |
16047 | break; |
16048 | } |
16049 | case BuiltinOptions_FillOptions: { |
16050 | auto ptr = reinterpret_cast<tflite::FillOptionsT *>(value); |
16051 | delete ptr; |
16052 | break; |
16053 | } |
16054 | case BuiltinOptions_BidirectionalSequenceLSTMOptions: { |
16055 | auto ptr = reinterpret_cast<tflite::BidirectionalSequenceLSTMOptionsT *>(value); |
16056 | delete ptr; |
16057 | break; |
16058 | } |
16059 | case BuiltinOptions_BidirectionalSequenceRNNOptions: { |
16060 | auto ptr = reinterpret_cast<tflite::BidirectionalSequenceRNNOptionsT *>(value); |
16061 | delete ptr; |
16062 | break; |
16063 | } |
16064 | case BuiltinOptions_UnidirectionalSequenceLSTMOptions: { |
16065 | auto ptr = reinterpret_cast<tflite::UnidirectionalSequenceLSTMOptionsT *>(value); |
16066 | delete ptr; |
16067 | break; |
16068 | } |
16069 | case BuiltinOptions_FloorModOptions: { |
16070 | auto ptr = reinterpret_cast<tflite::FloorModOptionsT *>(value); |
16071 | delete ptr; |
16072 | break; |
16073 | } |
16074 | case BuiltinOptions_RangeOptions: { |
16075 | auto ptr = reinterpret_cast<tflite::RangeOptionsT *>(value); |
16076 | delete ptr; |
16077 | break; |
16078 | } |
16079 | case BuiltinOptions_ResizeNearestNeighborOptions: { |
16080 | auto ptr = reinterpret_cast<tflite::ResizeNearestNeighborOptionsT *>(value); |
16081 | delete ptr; |
16082 | break; |
16083 | } |
16084 | case BuiltinOptions_LeakyReluOptions: { |
16085 | auto ptr = reinterpret_cast<tflite::LeakyReluOptionsT *>(value); |
16086 | delete ptr; |
16087 | break; |
16088 | } |
16089 | case BuiltinOptions_SquaredDifferenceOptions: { |
16090 | auto ptr = reinterpret_cast<tflite::SquaredDifferenceOptionsT *>(value); |
16091 | delete ptr; |
16092 | break; |
16093 | } |
16094 | case BuiltinOptions_MirrorPadOptions: { |
16095 | auto ptr = reinterpret_cast<tflite::MirrorPadOptionsT *>(value); |
16096 | delete ptr; |
16097 | break; |
16098 | } |
16099 | case BuiltinOptions_AbsOptions: { |
16100 | auto ptr = reinterpret_cast<tflite::AbsOptionsT *>(value); |
16101 | delete ptr; |
16102 | break; |
16103 | } |
16104 | case BuiltinOptions_SplitVOptions: { |
16105 | auto ptr = reinterpret_cast<tflite::SplitVOptionsT *>(value); |
16106 | delete ptr; |
16107 | break; |
16108 | } |
16109 | case BuiltinOptions_UniqueOptions: { |
16110 | auto ptr = reinterpret_cast<tflite::UniqueOptionsT *>(value); |
16111 | delete ptr; |
16112 | break; |
16113 | } |
16114 | case BuiltinOptions_ReverseV2Options: { |
16115 | auto ptr = reinterpret_cast<tflite::ReverseV2OptionsT *>(value); |
16116 | delete ptr; |
16117 | break; |
16118 | } |
16119 | case BuiltinOptions_AddNOptions: { |
16120 | auto ptr = reinterpret_cast<tflite::AddNOptionsT *>(value); |
16121 | delete ptr; |
16122 | break; |
16123 | } |
16124 | case BuiltinOptions_GatherNdOptions: { |
16125 | auto ptr = reinterpret_cast<tflite::GatherNdOptionsT *>(value); |
16126 | delete ptr; |
16127 | break; |
16128 | } |
16129 | case BuiltinOptions_CosOptions: { |
16130 | auto ptr = reinterpret_cast<tflite::CosOptionsT *>(value); |
16131 | delete ptr; |
16132 | break; |
16133 | } |
16134 | case BuiltinOptions_WhereOptions: { |
16135 | auto ptr = reinterpret_cast<tflite::WhereOptionsT *>(value); |
16136 | delete ptr; |
16137 | break; |
16138 | } |
16139 | case BuiltinOptions_RankOptions: { |
16140 | auto ptr = reinterpret_cast<tflite::RankOptionsT *>(value); |
16141 | delete ptr; |
16142 | break; |
16143 | } |
16144 | case BuiltinOptions_ReverseSequenceOptions: { |
16145 | auto ptr = reinterpret_cast<tflite::ReverseSequenceOptionsT *>(value); |
16146 | delete ptr; |
16147 | break; |
16148 | } |
16149 | case BuiltinOptions_MatrixDiagOptions: { |
16150 | auto ptr = reinterpret_cast<tflite::MatrixDiagOptionsT *>(value); |
16151 | delete ptr; |
16152 | break; |
16153 | } |
16154 | case BuiltinOptions_QuantizeOptions: { |
16155 | auto ptr = reinterpret_cast<tflite::QuantizeOptionsT *>(value); |
16156 | delete ptr; |
16157 | break; |
16158 | } |
16159 | case BuiltinOptions_MatrixSetDiagOptions: { |
16160 | auto ptr = reinterpret_cast<tflite::MatrixSetDiagOptionsT *>(value); |
16161 | delete ptr; |
16162 | break; |
16163 | } |
16164 | case BuiltinOptions_HardSwishOptions: { |
16165 | auto ptr = reinterpret_cast<tflite::HardSwishOptionsT *>(value); |
16166 | delete ptr; |
16167 | break; |
16168 | } |
16169 | case BuiltinOptions_IfOptions: { |
16170 | auto ptr = reinterpret_cast<tflite::IfOptionsT *>(value); |
16171 | delete ptr; |
16172 | break; |
16173 | } |
16174 | case BuiltinOptions_WhileOptions: { |
16175 | auto ptr = reinterpret_cast<tflite::WhileOptionsT *>(value); |
16176 | delete ptr; |
16177 | break; |
16178 | } |
16179 | case BuiltinOptions_DepthToSpaceOptions: { |
16180 | auto ptr = reinterpret_cast<tflite::DepthToSpaceOptionsT *>(value); |
16181 | delete ptr; |
16182 | break; |
16183 | } |
16184 | case BuiltinOptions_NonMaxSuppressionV4Options: { |
16185 | auto ptr = reinterpret_cast<tflite::NonMaxSuppressionV4OptionsT *>(value); |
16186 | delete ptr; |
16187 | break; |
16188 | } |
16189 | case BuiltinOptions_NonMaxSuppressionV5Options: { |
16190 | auto ptr = reinterpret_cast<tflite::NonMaxSuppressionV5OptionsT *>(value); |
16191 | delete ptr; |
16192 | break; |
16193 | } |
16194 | case BuiltinOptions_ScatterNdOptions: { |
16195 | auto ptr = reinterpret_cast<tflite::ScatterNdOptionsT *>(value); |
16196 | delete ptr; |
16197 | break; |
16198 | } |
16199 | case BuiltinOptions_SelectV2Options: { |
16200 | auto ptr = reinterpret_cast<tflite::SelectV2OptionsT *>(value); |
16201 | delete ptr; |
16202 | break; |
16203 | } |
16204 | case BuiltinOptions_DensifyOptions: { |
16205 | auto ptr = reinterpret_cast<tflite::DensifyOptionsT *>(value); |
16206 | delete ptr; |
16207 | break; |
16208 | } |
16209 | case BuiltinOptions_SegmentSumOptions: { |
16210 | auto ptr = reinterpret_cast<tflite::SegmentSumOptionsT *>(value); |
16211 | delete ptr; |
16212 | break; |
16213 | } |
16214 | case BuiltinOptions_BatchMatMulOptions: { |
16215 | auto ptr = reinterpret_cast<tflite::BatchMatMulOptionsT *>(value); |
16216 | delete ptr; |
16217 | break; |
16218 | } |
16219 | default: break; |
16220 | } |
16221 | value = nullptr; |
16222 | type = BuiltinOptions_NONE; |
16223 | } |
16224 | |
16225 | inline const tflite::Model *GetModel(const void *buf) { |
16226 | return flatbuffers::GetRoot<tflite::Model>(buf); |
16227 | } |
16228 | |
16229 | inline const tflite::Model *GetSizePrefixedModel(const void *buf) { |
16230 | return flatbuffers::GetSizePrefixedRoot<tflite::Model>(buf); |
16231 | } |
16232 | |
16233 | inline const char *ModelIdentifier() { |
16234 | return "TFL3" ; |
16235 | } |
16236 | |
16237 | inline bool ModelBufferHasIdentifier(const void *buf) { |
16238 | return flatbuffers::BufferHasIdentifier( |
16239 | buf, ModelIdentifier()); |
16240 | } |
16241 | |
16242 | inline bool VerifyModelBuffer( |
16243 | flatbuffers::Verifier &verifier) { |
16244 | return verifier.VerifyBuffer<tflite::Model>(ModelIdentifier()); |
16245 | } |
16246 | |
16247 | inline bool VerifySizePrefixedModelBuffer( |
16248 | flatbuffers::Verifier &verifier) { |
16249 | return verifier.VerifySizePrefixedBuffer<tflite::Model>(ModelIdentifier()); |
16250 | } |
16251 | |
16252 | inline const char *ModelExtension() { |
16253 | return "tflite" ; |
16254 | } |
16255 | |
16256 | inline void FinishModelBuffer( |
16257 | flatbuffers::FlatBufferBuilder &fbb, |
16258 | flatbuffers::Offset<tflite::Model> root) { |
16259 | fbb.Finish(root, ModelIdentifier()); |
16260 | } |
16261 | |
16262 | inline void FinishSizePrefixedModelBuffer( |
16263 | flatbuffers::FlatBufferBuilder &fbb, |
16264 | flatbuffers::Offset<tflite::Model> root) { |
16265 | fbb.FinishSizePrefixed(root, ModelIdentifier()); |
16266 | } |
16267 | |
16268 | inline std::unique_ptr<tflite::ModelT> UnPackModel( |
16269 | const void *buf, |
16270 | const flatbuffers::resolver_function_t *res = nullptr) { |
16271 | return std::unique_ptr<tflite::ModelT>(GetModel(buf)->UnPack(res)); |
16272 | } |
16273 | |
16274 | inline std::unique_ptr<tflite::ModelT> UnPackSizePrefixedModel( |
16275 | const void *buf, |
16276 | const flatbuffers::resolver_function_t *res = nullptr) { |
16277 | return std::unique_ptr<tflite::ModelT>(GetSizePrefixedModel(buf)->UnPack(res)); |
16278 | } |
16279 | |
16280 | } // namespace tflite |
16281 | |
16282 | #endif // FLATBUFFERS_GENERATED_SCHEMA_TFLITE_H_ |
16283 | |