Cortenn
helper.hpp
Go to the documentation of this file.
1 
9 #include "ade/ifunctor.hpp"
10 
11 #ifndef LLO_HELPER_HPP
12 #define LLO_HELPER_HPP
13 
14 namespace llo
15 {
16 
18 ade::TensptrT mtens_mul (ade::TensptrT lhs, ade::MappedTensor rhs);
19 
22 ade::TensptrT grad_prod (ade::iFunctor* fwd, size_t gradidx, ade::TensT tens);
23 
26 ade::TensptrT grad_min (ade::iFunctor* fwd, size_t gradidx, ade::TensT tens);
27 
30 ade::TensptrT grad_max (ade::iFunctor* fwd, size_t gradidx, ade::TensT tens);
31 
33 ade::TensptrT reduce (ade::Opcode opcode, ade::TensptrT tens, uint8_t dim);
34 
36 ade::TensptrT matmul (ade::TensptrT a, ade::TensptrT b);
37 
39 ade::TensptrT convolution (ade::TensptrT img, ade::TensptrT kernel);
40 
41 }
42 
43 #endif // LLO_HELPER_HPP
ade::TensptrT mtens_mul(ade::TensptrT lhs, ade::MappedTensor rhs)
Return product of lhs with mapped rhs.
Definition: helper.cpp:11
ade::TensptrT grad_prod(ade::iFunctor *fwd, size_t gradidx, ade::TensT tens)
Definition: helper.cpp:18
ade::TensptrT convolution(ade::TensptrT img, ade::TensptrT kernel)
Return convolution operation on img with kernel.
Definition: helper.cpp:102
ade::TensptrT matmul(ade::TensptrT a, ade::TensptrT b)
Return matmul of a and b.
Definition: helper.cpp:67
std::vector< ade::TensptrT > TensT
Tensptr vector type.
Definition: data.hpp:22
ade::TensptrT grad_max(ade::iFunctor *fwd, size_t gradidx, ade::TensT tens)
Definition: helper.cpp:46
Definition: data.hpp:20
ade::TensptrT grad_min(ade::iFunctor *fwd, size_t gradidx, ade::TensT tens)
Definition: helper.cpp:35
ade::TensptrT reduce(ade::Opcode opcode, ade::TensptrT tens, uint8_t dim)
Return reduction of tens after dimension dim using opcode operation.
Definition: helper.cpp:57