ONE - On-device Neural Engine
|
Decribe how to build a (convolution) feature map from a tensor. More...
#include <FeatureCodec.h>
Public Member Functions | |
virtual | ~FeatureEncoder ()=default |
virtual FeatureShape | shape (const TensorShape &shape) const =0 |
virtual TensorIndex | value (const FeatureIndex &index) const =0 |
virtual std::unique_ptr< FeatureEncoder > | clone (void) const =0 |
Decribe how to build a (convolution) feature map from a tensor.
Let us assume that "enc" is a feature encoder.
Given a tensor "inp" and its shape "inp.shape", "enc" builds a feature map "out" as follows:
for each valid feature index (referred to as feature_idx below) for enc.shape(inp.shape) out.at(feature_index) = inp.at(enc.value(feature_index))
Definition at line 44 of file FeatureCodec.h.
|
virtualdefault |
|
pure virtual |
Implemented in loco::PermutingEncoder< Domain::Feature >.
|
pure virtual |
|
pure virtual |
Implemented in loco::PermutingEncoder< Domain::Feature >.