ONE - On-device Neural Engine
Loading...
Searching...
No Matches
nnfw::cker::functor::InflateFunctor< Device, T, N > Struct Template Reference

#include <Einsum.h>

Public Member Functions

void operator() (const Device &d, typename TTypes< T, N >::ConstTensor input, const std::vector< int32_t > &strides, typename TTypes< T, N >::Tensor output)
 

Detailed Description

template<typename Device, typename T, int N>
struct nnfw::cker::functor::InflateFunctor< Device, T, N >

Definition at line 65 of file Einsum.h.

Member Function Documentation

◆ operator()()

template<typename Device , typename T , int N>
void nnfw::cker::functor::InflateFunctor< Device, T, N >::operator() ( const Device &  d,
typename TTypes< T, N >::ConstTensor  input,
const std::vector< int32_t > &  strides,
typename TTypes< T, N >::Tensor  output 
)
inline

Definition at line 67 of file Einsum.h.

69 {
70
71 Eigen::DSizes<Eigen::DenseIndex, N> dsizes;
72 for (size_t d = 0; d < strides.size(); d++)
73 {
74 dsizes[d] = static_cast<Eigen::DenseIndex>(strides[d]);
75 }
76 for (size_t d = strides.size(); d < N; d++)
77 {
78 dsizes[d] = 1;
79 }
80
81 output.device(d) = input.inflate(dsizes);
82 }

The documentation for this struct was generated from the following file: