you r missing Google Guava library which has these classes.  R u running a mvn 
build on Mahout snapshot?





On Thursday, November 28, 2013 1:56 AM, Tharindu Rusira 
<tharindurus...@gmail.com> wrote:
 
Hi all,
I'm working on Mahout 0.9-SNAPSHOT version checked out from the svn trunk.
The following code generates java.lang.NoClassDefFoundError:
com/google/common/base/Preconditions where b is supposed to be true
(because both cardinality and the values are same in the two vectors dv and
sv)

// --------------- start code -----------------

double[] vals= new double[]{2.3, 2.56,4.66};

DenseVector dv=new DenseVector(vals);

Vector sv= new SequentialAccessSparseVector(3);

for(int i=0;i<vals.length;i++){

  sv.set(i,vals[i]);

}


boolean b=dv.equals(sv);

System.out.println(b);

// --------------- end code -----------------


Where are the classes that execute these Preconditions? Are they shipped
with Mahout or am I missing something (apparently com.google.common.base)
in my standard Java library?


Thanks,

Reply via email to