views:

61

answers:

1

Complied Mahout successfully under Windows using Maven.

I'm trying to run one of the examples from the command line and I don't get what I am doing wrong. Seems like a CLASSPATH problem.

Let's say I want to run the GroupLensRecommenderEvaluatorRunner example. I go to the folder with the GroupLensRecommenderEvaluatorRunner.class file in it and execute:

java -cp C:/mahout/core/target/classes;. 

org.apache.mahout.cf.taste.example.grouplens.GroupLensRecommenderEvaluatorRunner

It gives me the NoClassDefFoundError exception for the GroupLensRecommenderEvaluatorRunner class.

Is the path for -cp wrong?

btw, for those who aren't familiar with mahout,

org.apache.mahout.cf.taste.example.grouplens

is the package of the GroupLensRecommenderEvaluatorRunner class. javadoc

thanks guys.

p.s - I first looked on previous stackoverflow questions on CLASSPATH and followed the given solutions, before asking this question.

A: 

This is better asked at [email protected].

Your classpath is missing compiled code in Mahout's examples module, which is where this class lives.

Better yet, have a look at this walkthrough: https://cwiki.apache.org/confluence/display/MAHOUT/Recommender+Documentation

Sean Owen
Thanks for your answer.I don't see any classpath explanation in this link.I do specify the folder "examples\target\classes\org\apache\mahout\cf\taste\example\grouplens". Any other class files in the examples module?But it still gives the same thing -- complaining on GroupLensRecommenderEvaluatorRunneronly, not on something else that it cannot find its class file. I will keep playing with it and if nothing works i will post the question to the user list. thanks again...
You shouldn't need to mess with the classpath if you're building as per the instructions there.But if you're doing something else that needs you to specify the classpath, that's OK, but that is not the correct classpath. Java classpath elements need to be the directory root: `examples/target/classes`.
Sean Owen