Hi Karan,

Yes, that sounds like there is a problem with your input file. Looks
like there are probably no vectors in the file.

Something thing to check is that the input file is in the local file
system, and it will place the output files in hdfs.

What is the content of the files you are converting?

-M@

On Tue, Oct 5, 2010 at 5:58 AM, Karan Jindal
<[email protected]> wrote:
> Hi all,
>
> I tried to run kmeans algorithm using mahout but getting an error of which
> I don't have any idea. Before running the algorithms, I converted the text
> document dataset into vector writable format, for doing this I followed
> the sequence of steps given here
> https://cwiki.apache.org/MAHOUT/creating-vectors-from-text.html .
>
> the error looks like this::
>
> 10/10/09 17:33:42 ERROR driver.MahoutDriver: MahoutDriver failed with
> args: [-i, clusteringVec/vectors/, -o, clustering/output, -c, clusters,
> -m, org.apache.mahout.common.distance.CosineDistanceMeasure, -x, 5, -w,
> -d, 1, -k, 25, null]
> Index: 1, Size: 1
> Exception in thread "main" java.lang.IndexOutOfBoundsException: Index: 1,
> Size: 1
>        at java.util.ArrayList.rangeCheck(ArrayList.java:571)
>        at java.util.ArrayList.get(ArrayList.java:349)
>        at
> org.apache.mahout.clustering.kmeans.RandomSeedGenerator.buildRandom(RandomSeedGenerator.java:113)
>        at
> org.apache.mahout.clustering.kmeans.KMeansDriver.main(KMeansDriver.java:164)
>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>        at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>        at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>        at java.lang.reflect.Method.invoke(Method.java:616)
>        at
> org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(ProgramDriver.java:68)
>        at org.apache.hadoop.util.ProgramDriver.driver(ProgramDriver.java:139)
>        at org.apache.mahout.driver.MahoutDriver.main(MahoutDriver.java:172)
>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>        at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>        at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>        at java.lang.reflect.Method.invoke(Method.java:616)
>        at org.apache.hadoop.util.RunJar.main(RunJar.java:156)
>
> Does this error suggest any mistake in the input file?
> Can anyone tell the problem?
>
>
>
> -Karan
>
>
> --
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
>
>



-- 
Have you thanked a teacher today? ---> http://www.liftateacher.org

Reply via email to