diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/nerv_matrix.md | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/doc/nerv_matrix.md b/doc/nerv_matrix.md index 2edf691..2cef099 100644 --- a/doc/nerv_matrix.md +++ b/doc/nerv_matrix.md @@ -88,4 +88,14 @@ Treating each row of `a` as speech feature, and do a feature expansion. The `sel * __void Matrix.rearrange_frm(Matrix self, Matrix a, int step)__ Rearrange `a` according to its feature dimension. The `step` is the length of context. So, `self[i][j]` will be assigned `a[i][j / step + (j % step) * (a.ncol / step)]`. `a` and `self` should be of the same size and `step` should be divisible by `a.ncol`. * __void Matrix.scale_row(Matrix self, Matrix scale)__ -Scale each column of `self` according to a vector `scale`. `scale` should be of size `1 * self.ncol`.
\ No newline at end of file +Scale each column of `self` according to a vector `scale`. `scale` should be of size `1 * self.ncol`. +* __Matrix Matrix.\_\_add\_\_(Matrix ma, Matrix mb)__ +Returns a new __Matrix__ which stores the result of `ma+mb`. +* __Matrix Matrix.\_\_sub\_\_(Matrix ma, Matrix mb)__ +Returns a new __Matrix__ which stores the result of `ma-mb`. +* __Matrix Matrix.\_\_mul\_\_(Matrix ma, Matrix mb)__ +Returns a new __Matrix__ which stores the result of `ma*mb`. +* __CuMatrix CuMatrix.new_from_host(MMatrix m)__ +Return a new __CuMatrix__ which is a copy of `m`. +* __MMatrix CuMatrix.new_to_host(CuMatrix self)__ +Return a new __MMatrix__ which is a copy of `self`.
\ No newline at end of file |