Uploaded image for project: 'Mahout'
  1. Mahout
  2. MAHOUT-721

Override org.apache.mahout.math.VectorWritable#toString()

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.6
    • classic
    • None

    Description

      VectorWritable#toString method is currently default implementation.
      It should be implemented appropriately.

      For instance, after running RecommenderJob, I inspect the temporary files on HDFS.

      $ hadoop fs -libjars /path/to/mahout-core-0.5-job.jar -text temp/userVectors/part-r-00000

      But this command returns

      2       org.apache.mahout.math.VectorWritable@15f48262
      4       org.apache.mahout.math.VectorWritable@15f48262
      

      If the toString is not default implementation, we can see this result.

      2       {101:2.0,104:2.0,103:5.0,102:2.5}
      4       {101:5.0,106:4.0,104:4.5,103:3.0}
      

      Attachments

        1. VectorWritable.java.patch
          0.5 kB
          Daisuke Miyamoto
        2. Writable-toString.patch
          5 kB
          Daisuke Miyamoto

        Activity

          People

            srowen Sean R. Owen
            daisuke_m Daisuke Miyamoto
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: