|
|
Suneel Marthi 2011-07-26, 07:58
Trying to run the examples in Chapter 13 of the book, get the following error when trying to execute bash> $MAHOUT_HOME/bin/mahout cat donut.csv
Running on hadoop, using HADOOP_HOME=/usr/local/hadoop No HADOOP_CONF_DIR set, using /usr/local/hadoop/src/conf 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.InMemoryFactorizationEvaluator 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.ParallelFactorizationEvaluator 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.DatasetSplitter Exception in thread "main" java.lang.NoSuchMethodError: org.apache.hadoop.util.ProgramDriver.driver([Ljava/lang/String;)V at org.apache.mahout.driver.MahoutDriver.main(MahoutDriver.java:188) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.util.RunJar.main(RunJar.java:192) Any idea as to what am I missing?
Here are my environment details:-
Hadoop version: 0.21.0 Mahout version: 0.6
-
Re: Mahout newbiw question
Suneel Marthi 2011-07-26, 08:02
Never mind, figured it out I need to downgrade my Hadoop to 0.20.2 to fix this.
Thanks.
________________________________ From: Suneel Marthi <[EMAIL PROTECTED]> To: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> Sent: Tuesday, July 26, 2011 3:58 AM Subject: Mahout newbiw question Trying to run the examples in Chapter 13 of the book, get the following error when trying to execute bash> $MAHOUT_HOME/bin/mahout cat donut.csv
Running on hadoop, using HADOOP_HOME=/usr/local/hadoop No HADOOP_CONF_DIR set, using /usr/local/hadoop/src/conf 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.InMemoryFactorizationEvaluator 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.ParallelFactorizationEvaluator 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.DatasetSplitter Exception in thread "main" java.lang.NoSuchMethodError: org.apache.hadoop.util.ProgramDriver.driver([Ljava/lang/String;)V at org.apache.mahout.driver.MahoutDriver.main(MahoutDriver.java:188) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.util.RunJar.main(RunJar.java:192) Any idea as to what am I missing?
Here are my environment details:-
Hadoop version: 0.21.0 Mahout version: 0.6
-
Re: Mahout newbiw question
Sean Owen 2011-07-26, 08:38
Yes, 0.5 goes with 0.20.2. HEAD/0.6 goes with 0.20.203.0
On Tue, Jul 26, 2011 at 9:02 AM, Suneel Marthi <[EMAIL PROTECTED]>wrote:
> Never mind, figured it out I need to downgrade my Hadoop to 0.20.2 to fix > this. > > Thanks. > > > > ________________________________ > From: Suneel Marthi <[EMAIL PROTECTED]> > To: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> > Sent: Tuesday, July 26, 2011 3:58 AM > Subject: Mahout newbiw question > > > Trying to run the examples in Chapter 13 of the book, get the following > error when trying to execute > > > bash> $MAHOUT_HOME/bin/mahout cat donut.csv > > Running on hadoop, using HADOOP_HOME=/usr/local/hadoop > No HADOOP_CONF_DIR set, using /usr/local/hadoop/src/conf > 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: > org.apache.mahout.utils.eval.InMemoryFactorizationEvaluator > 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: > org.apache.mahout.utils.eval.ParallelFactorizationEvaluator > 11/07/26 03:45:09 WARN driver.MahoutDriver: Unable to add class: > org.apache.mahout.utils.eval.DatasetSplitter > Exception in thread "main" java.lang.NoSuchMethodError: > org.apache.hadoop.util.ProgramDriver.driver([Ljava/lang/String;)V > > at org.apache.mahout.driver.MahoutDriver.main(MahoutDriver.java:188) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:597) > at org.apache.hadoop.util.RunJar.main(RunJar.java:192) > > > Any idea as to what am I missing? > > Here are my environment details:- > > Hadoop version: 0.21.0 > Mahout version: 0.6 >
-
Re: Mahout newbiw question
Suneel Marthi 2011-07-26, 08:45
Downgraded to 0.20.203.0 and am able to run through the exercises.
I now hit the next issue while trying to run the example.
bash> ./bin/mahout trainlogistic --input donut.csv \ > --output ./model \ > --target color --categories 2 \ > --predictors x y --types numeric \ > --features 20 --passes 100 --rate 50 Running on hadoop, using HADOOP_HOME=/usr/local/hadoop No HADOOP_CONF_DIR set, using /usr/local/hadoop/src/conf 11/07/26 04:21:58 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.InMemoryFactorizationEvaluator 11/07/26 04:21:58 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.ParallelFactorizationEvaluator 11/07/26 04:21:58 WARN driver.MahoutDriver: Unable to add class: org.apache.mahout.utils.eval.DatasetSplitter Exception in thread "main" java.lang.IllegalStateException: Unable to construct type converter... shouldn't be possible at org.apache.mahout.classifier.sgd.CsvRecordFactory.firstLine(CsvRecordFactory.java:223) at org.apache.mahout.classifier.sgd.TrainLogistic.mainToOutput(TrainLogistic.java:78) at org.apache.mahout.classifier.sgd.TrainLogistic.main(TrainLogistic.java:64) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(ProgramDriver.java:68) at org.apache.hadoop.util.ProgramDriver.driver(ProgramDriver.java:139) at org.apache.mahout.driver.MahoutDriver.main(MahoutDriver.java:188) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.util.RunJar.main(RunJar.java:156) Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at org.apache.mahout.classifier.sgd.CsvRecordFactory.firstLine(CsvRecordFactory.java:215) ... 14 more Caused by: java.lang.IncompatibleClassChangeError: Expecting non-static method org.apache.mahout.vectorizer.encoders.CachingValueEncoder.bytesForString(Ljava/lang/String;)[B at org.apache.mahout.vectorizer.encoders.CachingValueEncoder.cacheProbeLocations(CachingValueEncoder.java:50) at org.apache.mahout.vectorizer.encoders.CachingValueEncoder.<init>(CachingValueEncoder.java:29) at org.apache.mahout.vectorizer.encoders.ConstantValueEncoder.<init>(ConstantValueEncoder.java:27) ... 19 more Figured out that bytesToString() is a static method in FeatureVectorEncoder.java and is referenced in CachingValueEncoder.cacheProbeLocations(). Modified the caller, CachingValueEncoder.cacheProbeLocations()to call FeatureValueencoder.bytesToString() and am good now.
But I do see that bytesToString() is referenced in every class that extends FeatureVectorEncoder.java, wonder if its working.
Kind Regards.
________________________________ From: Sean Owen <[EMAIL PROTECTED]> To: [EMAIL PROTECTED]; Suneel Marthi <[EMAIL PROTECTED]> Sent: Tuesday, July 26, 2011 4:38 AM Subject: Re: Mahout newbiw question Yes, 0.5 goes with 0.20.2. HEAD/0.6 goes with 0.20.203.0 On Tue, Jul 26, 2011 at 9:02 AM, Suneel Marthi <[EMAIL PROTECTED]> wrote:
Never mind, figured it out I need to downgrade my Hadoop to 0.20.2 to fix this. > >Thanks. > > > > >________________________________
-
Re: Mahout newbiw question
Sean Owen 2011-07-26, 09:14
(Downgraded Hadoop to *0.20.2* you mean?) (I'd suggest you actually upgrade Mahout to 0.6/HEAD instead.)
This means you have incompatible versions of the compiled code lying around. Make sure you aren't including different versions twice, and/or recompile your local copy. The method in question is correct in 0.5 and HEAD.
On Tue, Jul 26, 2011 at 9:45 AM, Suneel Marthi <[EMAIL PROTECTED]>wrote:
> Downgraded to 0.20.203.0 and am able to run through the exercises. > > I now hit the next issue while trying to run the example. > > bash> ./bin/mahout trainlogistic --input donut.csv \ > > --output ./model \ > > --target color --categories 2 \ > > --predictors x y --types numeric \ > > --features 20 --passes 100 --rate 50 > > Running on hadoop, using HADOOP_HOME=/usr/local/hadoop > No HADOOP_CONF_DIR set, using /usr/local/hadoop/src/conf > 11/07/26 04:21:58 WARN driver.MahoutDriver: Unable to add class: > org.apache.mahout.utils.eval.InMemoryFactorizationEvaluator > 11/07/26 04:21:58 WARN driver.MahoutDriver: Unable to add class: > org.apache.mahout.utils.eval.ParallelFactorizationEvaluator > 11/07/26 04:21:58 WARN driver.MahoutDriver: Unable to add class: > org.apache.mahout.utils.eval.DatasetSplitter > Exception in thread "main" java.lang.IllegalStateException: Unable to > construct type converter... shouldn't be possible > at > org.apache.mahout.classifier.sgd.CsvRecordFactory.firstLine(CsvRecordFactory.java:223) > at > org.apache.mahout.classifier.sgd.TrainLogistic.mainToOutput(TrainLogistic.java:78) > at > org.apache.mahout.classifier.sgd.TrainLogistic.main(TrainLogistic.java:64) > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:597) > at > org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(ProgramDriver.java:68) > at org.apache.hadoop.util.ProgramDriver.driver(ProgramDriver.java:139) > > at org.apache.mahout.driver.MahoutDriver.main(MahoutDriver.java:188) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:597) > at org.apache.hadoop.util.RunJar.main(RunJar.java:156) > Caused by: java.lang.reflect.InvocationTargetException > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native > Method) > at > sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) > at > sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) > at java.lang.reflect.Constructor.newInstance(Constructor.java:513) > at > org.apache.mahout.classifier.sgd.CsvRecordFactory.firstLine(CsvRecordFactory.java:215) > ... 14 more > Caused by: java.lang.IncompatibleClassChangeError: Expecting non-static > method > org.apache.mahout.vectorizer.encoders.CachingValueEncoder.bytesForString(Ljava/lang/String;)[B > at > org.apache.mahout.vectorizer.encoders.CachingValueEncoder.cacheProbeLocations(CachingValueEncoder.java:50) > at > org.apache.mahout.vectorizer.encoders.CachingValueEncoder.<init>(CachingValueEncoder.java:29) > at > org.apache.mahout.vectorizer.encoders.ConstantValueEncoder.<init>(ConstantValueEncoder.java:27) > ... 19 more > > Figured out that bytesToString() is a static method in > FeatureVectorEncoder.java and is referenced in > CachingValueEncoder.cacheProbeLocations(). > Modified the caller, CachingValueEncoder.cacheProbeLocations() to call > FeatureValueencoder.bytesToString() and am good now. > > But I do see that bytesToString() is referenced in every class that extends > FeatureVectorEncoder.java, wonder if its working.
-
Re: Mahout newbiw question
Sean Owen 2011-07-26, 09:20
If you are on HEAD, you don't need to downgrade to Hadoop 0.20.2 (though it will work). I suspect that original problem was a symptom of the same issue. Yes, try a clean build.
On Tue, Jul 26, 2011 at 10:18 AM, Suneel Marthi <[EMAIL PROTECTED]>wrote:
> I am running 0.6 mahout, but I guess I should have done a clean build, will > give that a shot. My bad and thanks for your help. > >
|
|