ONE - On-device Neural Engine
Loading...
Searching...
No Matches
L2Normalize Class Referencefinal

#include <L2Normalize.h>

Collaboration diagram for L2Normalize:

Public Member Functions

 L2Normalize (const tflchef::Operation *operation)
 
tflite::BuiltinOperator code (void) const override
 
tflite::BuiltinOptions type (void) const override
 
flatbuffers::Offset< void > value (flatbuffers::FlatBufferBuilder &fbb) const override
 
- Public Member Functions inherited from OpChef
virtual ~OpChef ()=default
 
virtual flatbuffers::Offset< flatbuffers::Vector< uint8_t > > custom_value (flatbuffers::FlatBufferBuilder &fbb) const
 
virtual ~OpChef ()=default
 
virtual flatbuffers::Offset< flatbuffers::Vector< uint8_t > > custom_value (flatbuffers::FlatBufferBuilder &fbb) const
 

Detailed Description

Definition at line 22 of file L2Normalize.h.

Constructor & Destructor Documentation

◆ L2Normalize()

L2Normalize::L2Normalize ( const tflchef::Operation *  operation)
inlineexplicit

Definition at line 25 of file L2Normalize.h.

25 : _operation{operation}
26 {
27 // DO NOTHING
28 }

Member Function Documentation

◆ code()

tflite::BuiltinOperator L2Normalize::code ( void  ) const
inlineoverridevirtual

Implements OpChef.

Definition at line 31 of file L2Normalize.h.

32 {
33 return tflite::BuiltinOperator_L2_NORMALIZATION;
34 }

◆ type()

tflite::BuiltinOptions L2Normalize::type ( void  ) const
inlineoverridevirtual

Implements OpChef.

Definition at line 36 of file L2Normalize.h.

36{ return tflite::BuiltinOptions_L2NormOptions; }

◆ value()

flatbuffers::Offset< void > L2Normalize::value ( flatbuffers::FlatBufferBuilder fbb) const
overridevirtual

Implements OpChef.

Definition at line 20 of file L2Normalize.cpp.

21{
22 auto &operation = (*_operation);
23
24 tflite::L2NormOptionsBuilder l2norm_options_builder{fbb};
25 auto tflite_activation = as_tflite_activation(operation.l2norm_options().activation());
26 l2norm_options_builder.add_fused_activation_function(tflite_activation);
27 return l2norm_options_builder.Finish().Union();
28}
tflite::ActivationFunctionType as_tflite_activation(const tflchef::Activation &value)
Definition Convert.cpp:37

References as_tflite_activation().


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