Search in sources :

Example 1 with ColumnRangePartitioner

use of com.tencent.angel.ps.storage.partitioner.ColumnRangePartitioner in project angel by Tencent.

the class PartitionerTest method testModelLongPartitioner.

@Test
public void testModelLongPartitioner() throws Exception {
    MatrixContext mMatrix = new MatrixContext();
    mMatrix.setName("w1");
    mMatrix.setRowNum(10);
    mMatrix.setColNum(-1);
    mMatrix.setValidIndexNum(100000000);
    mMatrix.setRowType(RowType.T_DOUBLE_SPARSE_LONGKEY);
    Configuration conf = new Configuration();
    conf.setInt(AngelConf.ANGEL_PS_NUMBER, 1);
    ColumnRangePartitioner partitioner = new ColumnRangePartitioner();
    // partitioner.init(mMatrix, conf);
    partitioner.getPartitions();
}
Also used : MatrixContext(com.tencent.angel.ml.matrix.MatrixContext) ColumnRangePartitioner(com.tencent.angel.ps.storage.partitioner.ColumnRangePartitioner) Configuration(org.apache.hadoop.conf.Configuration) Test(org.junit.Test)

Aggregations

MatrixContext (com.tencent.angel.ml.matrix.MatrixContext)1 ColumnRangePartitioner (com.tencent.angel.ps.storage.partitioner.ColumnRangePartitioner)1 Configuration (org.apache.hadoop.conf.Configuration)1 Test (org.junit.Test)1