[
https://issues.apache.org/jira/browse/MAHOUT-812?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Sean Owen updated MAHOUT-812:
-----------------------------
Attachment: MAHOUT-812.patch
OK, this is looking reasonable.
Some of the formatting needs to be cleaned up -- some lines are not indented or
indented with tabs, etc. What's up with calling hashCode() on an array and not
using the result?
MatrixWritable looks good, along with the rest of the test code.
In ConfusionMatrix: why add 0.0001 to all elements? Is it so that the doubles
are converted back to ints properly on the other side? I'd do a round then.
Attached is my take on the patch.
> Allow ConfusionMatrix to be Writable (via MatrixWritable)
> ---------------------------------------------------------
>
> Key: MAHOUT-812
> URL: https://issues.apache.org/jira/browse/MAHOUT-812
> Project: Mahout
> Issue Type: Improvement
> Reporter: Lance Norskog
> Priority: Minor
> Fix For: 0.6
>
> Attachments: MAHOUT-812.patch, MAHOUT-812.patch, MAHOUT-812.patch
>
>
> ConfusionMatrix does not support Writable. This patch adds that feature.
> ConfusionMatrix is a subclass of MatrixWritable.
> Since ConfusionMatrix is somewhat less than useful without the row/column
> labels, and MatrixWritable does not support writing bindings (it only saves
> numbers), this patch fixes both.
> Includes unit test for ConfusionMatrix (previously missing) which includes
> exercise of MatrixWritable support for numbers and labels. (There is no
> independent unit test for MatrixWritable.)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira