mahout-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Abernathy <>
Subject Re: A question about "" example in" Mahout in Action" book
Date Sun, 17 Jun 2012 10:37:13 GMT
I also have gotten the Mahout in Action book recently and am stuck on 
the first example.  I downloaded the 0.6 distribution and downloaded and 
built the MiA code.  When I attempt to run the class from the command 
line, I get this error:

java mia.recommender.ch02.RecommenderIntro
Exception in thread "main" java.lang.NoClassDefFoundError: 
Caused by: java.lang.ClassNotFoundException:
     at Method)
     at java.lang.ClassLoader.loadClass(
     at sun.misc.Launcher$AppClassLoader.loadClass(
     at java.lang.ClassLoader.loadClass(
Could not find the main class: mia.recommender.ch02.RecommenderIntro. 
Program will exit.

Am I missing a jar somewhere, or am I running with the wrong Mahout version?

When I change into the MiA directed and attempt to run it with Maven, I 
get this error:

mvn pom.xml
[INFO] Scanning for projects...
[INFO] Building Mahout in Action Examples 0.1
[INFO] Total time: 0.642s
[INFO] Finished at: Sun Jun 17 06:22:08 EDT 2012
[INFO] Final Memory: 2M/15M
[ERROR] Unknown lifecycle phase "pom.xml". You must specify a valid 
lifecycle phase or a goal in the format <plugin-prefix>:<goal> or 

Available lifecycle phases are: validate, initialize, generate-sources, 
process-sources, generate-resources, process-resources, compile, 
process-classes, generate-test-sources, process-test-sources, 
generate-test-resources, process-test-resources, test-compile, 
process-test-classes, test, prepare-package, package, 
pre-integration-test, integration-test, post-integration-test, verify, 
install, deploy, pre-clean, clean, post-clean, pre-site, site, 
post-site, site-deploy. -> [Help 1]
[ERROR] To see the full stack trace of the errors, re-run Maven with the 
-e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] For more information about the errors and possible solutions, 
please read the following articles:
[ERROR] [Help 1]

I am new to Maven to it may be that I don't know how to run Maven 
correctly.  Also, when I downloaded the trunk version from svn I was 
not  able to get it to build (it seemed to be missing a few jar files 
but I forget which ones), but that's a different issue.  Right now I am 
trying to figure out how to run the first examples in some version of 
Mahout.  If anybody knows how to run the examples I would greatly 
appreciate the assistance.



On 06/13/2012 12:20 PM, Sean Owen wrote:
> (Since you also asked in the publisher's forum, and it pertains to the
> book, I will answer there rather than on the general Mahout mailing list.)
> On Wed, Jun 13, 2012 at 2:25 PM, Yaprak Ayazoglu
> <>wrote:
>> Hi,
>> I'm following "Mahout in Action" book to learn Mahout. I'm trying to run
>> the example codes in this book. I downloaded the codes and run
>> "" (a code at chapter 2 - ch2).
>> After running this code I get the following error:
>> Exception in thread "main" intro.csv
>> at
>> at
>> at mia.recommender.ch02.RecommenderIntro.main(
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(
>> at java.lang.reflect.Method.invoke(
>> at com.intellij.rt.execution.application.AppMain.main(
>> Can you help me to solve this problem?
>> Thanks.
>> --
>> Yaprak

View raw message