incubator-hama-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Samuel Guo (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HAMA-130) Computing Block's range will miss some cell during blocking.
Date Tue, 09 Dec 2008 12:36:44 GMT

    [ https://issues.apache.org/jira/browse/HAMA-130?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12654784#action_12654784
] 

Samuel Guo commented on HAMA-130:
---------------------------------

Also fix the bug from *SubMatrix*.

The bug from *SubMatrix* will fail the multiplication job during multiplying two matrices
that are not square-matrices. Such as a(30 * 40) * b(40 * 30).

> Computing Block's range will miss some cell during blocking.
> ------------------------------------------------------------
>
>                 Key: HAMA-130
>                 URL: https://issues.apache.org/jira/browse/HAMA-130
>             Project: Hama
>          Issue Type: Bug
>          Components: implementation
>    Affects Versions: 0.1.0
>            Reporter: Samuel Guo
>            Assignee: Samuel Guo
>            Priority: Critical
>             Fix For: 0.1.0
>
>         Attachments: HAMA-130.patch
>
>
> As the code below, in *BlockingMapper*, we compute the block's col range in a loop. 
> if the block's size can integer-divide the matrix' column size, it is right.
> but if the block's size can not integer-divide the matrix' column size, some cells will
be missed.
> for (int i = 0; i < mBlockNum; i++) {
>         startColumn = i * mBlockColSize;
>         endColumn = startColumn + mBlockColSize - 1;
>         output.collect(new BlockID(blkRow, i), new VectorWritable(key.get(),
>             dv.subVector(startColumn, endColumn)));
> }
> for examples:
> if the block num is 3,  the matrix is 100 * 100. mBlockSize = 100 / 3 = 33.
> then <0 ~ 32>, <33 ~ 65>, <66 ~ 98> will be counted. At the same time
we will lose column 99.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message