我是Mahout的新手,我有一个星期试图运行这些书的例子。本书建议使用IDE,但Eclipse和Netbeans在maven和slf4j安装方面遇到了一些麻烦,这就是为什么我试图使用ubuntu 13.04终端。任何人都可以帮助我吗?我从git存储库的0.7分支下载了源代码,并尝试使其工作,执行以下步骤:
$sudo apt-get install maven
(安装3.0.4版本)$ mvn package
(我想我必须修改pom文件,但我不确定)$ mvn exec:java -Dexec.mainClass="mia.recommender.ch02.IREvaluatorIntro" -Dexec.args="src"
命令运行其中一个示例,但是当我运行它时它会向我显示:[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.424s
[INFO] Finished at: Wed Jul 10 10:43:36 PDT 2013
[INFO] Final Memory: 8M/19M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:java (default-cli) on project mia: An exception occured while executing the Java class. null: InvocationTargetException: intro.csv -> [Help 1]
[ERROR]
[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]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
提前致谢!
答案 0 :(得分:0)
我认为你必须首先构建mahout jar文件!他们在每个mahout主文件夹的目标文件夹中创建,如数学,示例和... 然后在解压zip文件后运行此命令来构建jar文件
sudo mvn -DskipTests install -e
之后你可以运行你的例子:)