You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hama.apache.org by "Samuel Guo (JIRA)" <ji...@apache.org> on 2008/12/09 13:34:44 UTC

[jira] Updated: (HAMA-130) Computing Block's range will miss some cell during blocking.

     [ https://issues.apache.org/jira/browse/HAMA-130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Samuel Guo updated HAMA-130:
----------------------------

    Attachment: HAMA-130.patch

Attach my patch.

> 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.