Does an empty entry mean a zero value? If so, try changing the text file to use 0 instead of the empty space.
Is there a text line which has 16 numbers and the rest empty spaces? And another text line with 91 numbers? On Wed, Jan 11, 2012 at 2:31 AM, rahul raghavendhra <[email protected]> wrote: > Hi all, > > i have run that org.apache.mahout.clustering.syntheticcontrol.<>.Job > successfully.. > > when i run with similar dataset(double values separated by ' ' (space)).. > > i got the error org.apache.mahout.math.CardinalityException: Required > cardinality 16 but got 91 > > How this Cardinality is calculated and how it is passed to kmeans driver.. > how to calculate the cardinality for any dataset ? > > please help > > > > > ./rahul > > > On Tue, Jan 10, 2012 at 9:31 AM, Grant Ingersoll <[email protected]>wrote: > >> The CSVVectorIterator will get you vectors from a CSV file, then you just >> need to write them out to the SequenceFile. All you need is a driver that >> wraps the SequenceFileVectorWriter and calls the write method. >> >> >> On Jan 9, 2012, at 2:50 PM, Daniel Quach wrote: >> >> > I have a file of vectors I formulated in csv format, and I want to use >> mahout to perform k-means clustering on the vectors in this file. >> > >> > However, it seems mahout expects the input data to be formatted in a >> SequenceFile format, and I'm not sure if there's a way to easily do this >> (are there existing tools?) >> >> -------------------------------------------- >> Grant Ingersoll >> http://www.lucidimagination.com >> >> >> >> -- Lance Norskog [email protected]
