mahout-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jake Mannix <jake.man...@gmail.com>
Subject Re: Taste-GenericItemBasedRecommender
Date Sun, 13 Dec 2009 11:11:20 GMT
On Sat, Dec 12, 2009 at 5:34 PM, Ted Dunning <ted.dunning@gmail.com> wrote:

> This is a key problem.
>
> Looks like we really need to think about versions of assign that only scan
> non-zero elements.  Something like assignFromNonZero.
>

This is easier than the rest of the stuff we are talking about here.
Whenever
you have a UnaryFunction f such that f.apply(0) == 0, or you have a
BinaryFunction b such that b.appy(x, 0) == x or b.apply(0, x) == x, then
assign
should take advantage of this and iterateNonZero() on the vector which can
be skipped over.  In Colt, they actually special-case out functions like
Plus
or Minus to take care of this.

In our case, a particular, PlusWithScale is a very very common function
for Vectors to do, and could be special cased itself, in AbstractVector.

  -jake

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message