waylonflinn/weblas

Substraction matrix ?

extremety1989 opened this issue · 2 comments

Why is there no Substraction method ?

If you're already doing a matrix multiply (adding a bias term, for instance) the easiest way to do this is directly with the sgemm method.

  1. set beta to -1
  2. pass in your bias terms as C (the last argument)

If you aren't doing a multiply beforehand, the best way is with the saxpy method.

  1. set a to -1
  2. pass the matrix you want to subtract from as X
  3. pass the matrix you want to subtract with as Y

Please let me know if this helps you.