Hello,

How do I read a row from a file and assign it to a VectorWritable?
Can I directly use the readVector() or readFields() of the VectorWritable
class?  Do I have to construct the VectorWritable using a Vector?
Does anyone have some sample code?


Thanks,
Chiu

On Thu, Nov 22, 2012 at 8:15 AM, Sebastian Schelter <[email protected]> wrote:

> Hi,
>
> the sequencefile must consist of <IntWritable,VectorWritable> pairs,
> where the key represents the row number and the value holds the row vector.
>
> Best,
> Sebastian
>
>
> On 22.11.2012 15:13, Chui-Hui Chiu wrote:
> > Hello, all,
> >
> > I read the introduction page of the SVD in Mahout.  The SVD application
> > requires that the input matrix in the Sequence File Format.  Now, I have
> a
> > matrix with real number elements in the ASCII format.  Rows are separated
> > by the new line characters and columns are separated by the space
> > character.  The matrix looks like
> >
> > 1.1 1.2 1.3
> > 2.1 2.2 2.3
> > 3.1 3.2 3.3
> >
> > How is the matrix stored in Sequence Files?  How do I convert the matrix
> > into the appropriate format for the SVD application?
> >
> >
> > Thanks,
> > Chiu
> >
>
>

Reply via email to