Hi,

I was using Apache Mahout version 0.7 and I was using this piece of code:

KMeansDriver.run(conf, new Path("testdata/points"), new 
Path("testdata/clusters"), output, new EuclideanDistanceMeasure(),0.001, 10, 
true, 0.0, false);

Next, I was iterating in this way to see the results:

SequenceFile.Reader reader = new SequenceFile.Reader(fs, new Path("output/" + 
Kluster.CLUSTERED_POINTS_DIR + "/part-m-00000"),conf);

IntWritable key = new IntWritable();
WeightedVectorWritable value = new WeightedVectorWritable();

while (reader.next(key, value)) {
  value.getVector();
  // ...
}

I changed version from 0.7 to 0.9 and I have got compilation problems in lines:

KMeansDriver.run(...

and

value.getVector(...

Could you tell me how I can fix it?

my pom.xml:
                <mahout.version>0.9</mahout.version>
                <mahout.groupid>org.apache.mahout</mahout.groupid>

                <dependency>
                        <groupId>${mahout.groupid}</groupId>
                        <artifactId>mahout-core</artifactId>
                        <version>${mahout.version}</version>
                </dependency>
                <dependency>
                        <groupId>${mahout.groupid}</groupId>
                        <artifactId>mahout-core</artifactId>
                        <type>test-jar</type>
                        <scope>test</scope>
                        <version>${mahout.version}</version>
                </dependency>
                <dependency>
                        <groupId>${mahout.groupid}</groupId>
                        <artifactId>mahout-math</artifactId>
                        <version>${mahout.version}</version>
                </dependency>
                <dependency>
                        <groupId>${mahout.groupid}</groupId>
                        <artifactId>mahout-math</artifactId>
                        <type>test-jar</type>
                        <scope>test</scope>
                        <version>${mahout.version}</version>
                </dependency>
                <dependency>
                        <groupId>${mahout.groupid}</groupId>
                        <artifactId>mahout-examples</artifactId>
                        <version>${mahout.version}</version>
                </dependency>

Thank you in advance
Alex


Reply via email to