Not sure unless I intetionally reproduce this situation, however, Mahout
recommendation seems to be senstive to the carriage code placed at the end
of your final input data record.
For instance,
If your final data record ends like
....
5 105
5 106<CR><LF>
<End of File>
and have no succeeding recods, I believe Mahout should blindly read the NUL
record and eventually fall into
.ArrayIndexOutOfBoundsException.

Regards,,,
Y.Mandai




2013/5/11 滝口倫理 <rinri1...@gmail.com>

> I tried to give exactly path. But I see the same error..
>
>
> [hadoop@localhost ~]$ hadoop jar
> /usr/lib/mahout/mahout-core-0.7-cdh4.2.1-job.jar
> org.apache.mahout.cf.taste.hadoop.item.RecommenderJo
> b -i /user/hadoop/recommend2_in -o /user/hadoop/rec_out -s
> SIMILARITY_LOGLIKELIHOOD -b true
>
> [Error]
> ====================================================
>
> 13/05/11 09:14:09 INFO mapreduce.Job: Task Id :
> attempt_1368231064557_0001_m_000000_0, Status : FAILED
> Error: java.lang.ArrayIndexOutOfBoundsException: 1
>         at
>
> org.apache.mahout.cf.taste.hadoop.item.ItemIDIndexMapper.map(ItemIDIndexMapper.java:47)
>         at
>
> org.apache.mahout.cf.taste.hadoop.item.ItemIDIndexMapper.map(ItemIDIndexMapper.java:31)
>
> 13/05/11 09:14:33 INFO mapreduce.Job: Counters: 6
>         Job Counters
>                 Failed map tasks=4
>                 Launched map tasks=4
>                 Other local map tasks=3
>                 Rack-local map tasks=1
>                 Total time spent by all maps in occupied slots (ms)=26278
>                 Total time spent by all reduces in occupied slots (ms)=0
> Exception in thread "main" java.io.FileNotFoundException: File does not
> exist: /user/hadoop/temp/preparePreferenceMatrix/numUsers.bin
>         at
>
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocationsUpdateTimes(FSNamesystem.java:1312)
>         at
>
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocationsInt(FSNamesystem.java:1258)
>         at
>
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocations(FSNamesystem.java:1231)
> ====================================================
>
>
>
>
>
> 2013/5/10 Sebastian Schelter <s...@apache.org>
>
> > I think there is some problem with the pathes to the files which you
> > supply. You should try to give absolute pathes to the files.
> >
> > Best,
> > Sebastian
> >
> >
> > On 10.05.2013 13:36, 滝口倫理 wrote:
> > > I would like to get recommended items by using RecommenderJob.
> > > The input data I made is as below. There aren't preference value on
> > purpose.
> > >
> > > When I run RecommenderJob, I got some errors.
> > >
> > > Does it mean I have to prepare the preference value for input file?
> > > I want to do RecommenderJob without preference value.
> > >
> > > Regards
> > > Takiguchi
> > >
> > >
> > > [mahout command]
> > > ===========================================================
> > >
> > > [hadoop@localhost test]$ cat rere2
> > > 1 101
> > > 1 102
> > > 1 103
> > > 2 101
> > > 2 102
> > > 2 103
> > > 2 104
> > > 3 101
> > > 3 104
> > > 3 105
> > > 3 107
> > > 4 101
> > > 4 103
> > > 4 104
> > > 4 106
> > > 5 101
> > > 5 102
> > > 5 103
> > > 5 104
> > > 5 105
> > > 5 106
> > >
> > > [hadoop@localhost test]$ hadoop fs -mkdir recommend2_in
> > >
> > > [hadoop@localhost test]$ hadoop fs -put rere2 recommend2_in
> > >
> > > [hadoop@localhost test]$ hadoop jar
> > > /usr/lib/mahout/mahout-core-0.7-cdh4.2.1-job.jar \
> > > org.apache.mahout.cf.taste.hadoop.item.RecommenderJob \
> > > -i recommend2_in -o rec_out -s SIMILARITY_LOGLIKELIHOOD \
> > > -b true
> > > ===========================================================
> > >
> > >
> > > [Error]
> > >
> >
> =============================================================================
> > >
> > >
> > > 13/05/10 20:15:54 INFO mapreduce.Job: Task Id :
> > > attempt_1368183830239_0002_m_000000_0, Status : FAILED
> > > Error: java.lang.ArrayIndexOutOfBoundsException: 1
> > >         at
> > >
> >
> org.apache.mahout.cf.taste.hadoop.item.ItemIDIndexMapper.map(ItemIDIndexMapper.java:47)
> > >         at
> > >
> >
> org.apache.mahout.cf.taste.hadoop.item.ItemIDIndexMapper.map(ItemIDIndexMapper.java:31)
> > >
> > > 13/05/10 20:16:02 INFO mapreduce.Job: Task Id :
> > > attempt_1368183830239_0002_m_000000_1, Status : FAILED
> > > Error: java.lang.ArrayIndexOutOfBoundsException: 1
> > >
> > > 13/05/10 20:16:10 INFO mapreduce.Job: Task Id :
> > > attempt_1368183830239_0002_m_000000_2, Status : FAILED
> > > Error: java.lang.ArrayIndexOutOfBoundsException: 1
> > >
> > > 13/05/10 20:16:18 INFO mapreduce.Job: Counters: 6
> > >         Job Counters
> > >                 Failed map tasks=4
> > >                 Launched map tasks=4
> > >                 Other local map tasks=3
> > >                 Rack-local map tasks=1
> > >                 Total time spent by all maps in occupied slots
> (ms)=26266
> > >                 Total time spent by all reduces in occupied slots
> (ms)=0
> > > Exception in thread "main" java.io.FileNotFoundException: File does not
> > > exist: /user/hadoop/temp/preparePreferenceMatrix/numUsers.bin
> > >         at
> > >
> >
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocationsUpdateTimes(FSNamesystem.java:1312)
> > >         at
> > >
> >
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocationsInt(FSNamesystem.java:1258)
> > >         at
> > >
> >
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocations(FSNamesystem.java:1231)
> > >
> > >
> > >
> > >
> >
> =============================================================================
> > >
> >
> >
>

Reply via email to