The matrix Plugin
More...
|
const Def * | zero_int (World &w, Ref n, Ref S, Ref mem, nat_t m) |
| mat.zero: [n: Nat, S: «n; Nat», m: Nat] -> mat.Mat (n,S,(Idx m));
|
|
const Def * | op_read (Ref mem, Ref matrix, Ref idx) |
|
u64 | get_max_index (u64 init, Defs inputs) |
| Matrix normalizer for product on two-dimensional matrices.
|
|
std::pair< Lam *, Ref > | counting_for (Ref bound, DefVec acc, Ref exit, const char *name="for_body") |
|
void | register_normalizers (Normalizers &normalizers) |
|
◆ constMat
◆ init
◆ insert
◆ internal_map_reduce_cleanup
◆ lower_matrix_high_level_map_reduce
◆ lower_matrix_low_level
◆ lower_matrix_medium_level
◆ map_reduce
◆ Mat
◆ prod
◆ read
◆ shape
◆ sum
◆ transpose
◆ counting_for()
std::pair< Lam *, Ref > mim::plug::matrix::counting_for |
( |
Ref | bound, |
|
|
DefVec | acc, |
|
|
Ref | exit, |
|
|
const char * | name = "for_body" ) |
◆ get_max_index()
u64 mim::plug::matrix::get_max_index |
( |
u64 | init, |
|
|
Defs | inputs ) |
Matrix normalizer for product on two-dimensional matrices.
- product (constMat v1, constMat v2) -> constMat v1 * v2 * dim (TODO: implement)
- product (constMat v, m) -> ... (TODO: implement)
- product (m, constMat v) -> ... (TODO: implement)
- product (id, m) -> m (TODO: check)
- product (m, id) -> m
- map(constMat v, f) -> constMat f(v) (TODO: implement)
- map f (map g m) -> map (f . g) m (TODO: implement)
- map f (zipWith g m1 m2) -> zipWith (f . g) m1 m2 (TODO: implement)
Definition at line 76 of file normalizers.cpp.
References mim::Lit::isa().
◆ normalize_insert()
Ref mim::plug::matrix::normalize_insert |
( |
Ref | type, |
|
|
Ref | callee, |
|
|
Ref | arg ) |
◆ normalize_map_reduce()
Ref mim::plug::matrix::normalize_map_reduce |
( |
Ref | type, |
|
|
Ref | callee, |
|
|
Ref | arg ) |
◆ normalize_prod()
Ref mim::plug::matrix::normalize_prod |
( |
Ref | type, |
|
|
Ref | callee, |
|
|
Ref | arg ) |
◆ normalize_read()
Ref mim::plug::matrix::normalize_read |
( |
Ref | type, |
|
|
Ref | callee, |
|
|
Ref | arg ) |
◆ normalize_shape()
Ref mim::plug::matrix::normalize_shape |
( |
Ref | type, |
|
|
Ref | callee, |
|
|
Ref | arg ) |
Normalizer for transpose operations.
- transpose (constMat v) -> cosntMat v (TODO: implement)
- transpose (insert m v (i,j)) -> insert (transpose m) v (j,i) (TODO: implement, maybe other way around?)
- transpose (tranpose m) -> m (TODO: implement)
- shape (@mat n (k1,k2,...,kn) i) -> (k1,k2,...,kn)#i (TODO: implement)
Definition at line 57 of file normalizers.cpp.
References mim::match(), mim::Def::projs(), and mim::Def::world().
◆ normalize_transpose()
Ref mim::plug::matrix::normalize_transpose |
( |
Ref | type, |
|
|
Ref | callee, |
|
|
Ref | arg ) |
◆ op_read()
const Def * mim::plug::matrix::op_read |
( |
Ref | mem, |
|
|
Ref | matrix, |
|
|
Ref | idx ) |
|
inline |
◆ register_normalizers()
void mim::plug::matrix::register_normalizers |
( |
Normalizers & | normalizers | ) |
|
◆ zero_int()
mat.zero: [n: Nat, S: «n; Nat», m: Nat] -> mat.Mat (n,S,(Idx m));
Definition at line 14 of file matrix.h.
◆ Plugin_Id
plugin_t mim::plug::matrix::Plugin_Id = 0x3825532990000000 |
|
staticconstexpr |