public class ColGroupRLE extends ColGroupBitmap
ColGroup.CompressionType
_data, _ptr, _skiplist, _values, _zeros, CREATE_SKIPLIST, LOW_LEVEL_OPT, READ_CACHE_BLKSZ, WRITE_CACHE_BLKSZ
_colIndexes, _numRows
Constructor and Description |
---|
ColGroupRLE() |
ColGroupRLE(int[] colIndices,
int numRows,
boolean zeros,
double[] values,
char[] bitmaps,
int[] bitmapOffs) |
ColGroupRLE(int[] colIndices,
int numRows,
UncompressedBitmap ubm)
Main constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean[] |
computeZeroIndicatorVector() |
protected void |
countNonZerosPerRow(int[] rnnz,
int rl,
int ru)
Count the number of non-zeros per row
|
void |
decompressToBlock(MatrixBlock target,
int colpos)
Decompress to block.
|
void |
decompressToBlock(MatrixBlock target,
int[] colixTargets)
Decompress the contents of this column group into uncompressed packed
columns
|
void |
decompressToBlock(MatrixBlock target,
int rl,
int ru)
Decompress the contents of this column group into the specified full
matrix block.
|
Iterator<Integer> |
getDecodeIterator(int k) |
void |
leftMultByRowVector(MatrixBlock vector,
MatrixBlock result)
Multiply the slice of the matrix that this column group represents by a
row vector on the left (the original column vector is assumed to be
transposed already i.e.
|
void |
rightMultByVector(MatrixBlock vector,
MatrixBlock result,
int rl,
int ru)
Multiply the slice of the matrix that this column group represents by a
vector on the right.
|
ColGroup |
scalarOperation(org.apache.sysml.runtime.matrix.operators.ScalarOperator op)
Perform the specified scalar operation directly on the compressed column
group, without decompressing individual cells if possible.
|
void |
unaryAggregateOperations(org.apache.sysml.runtime.matrix.operators.AggregateUnaryOperator op,
MatrixBlock result) |
void |
unaryAggregateOperations(org.apache.sysml.runtime.matrix.operators.AggregateUnaryOperator op,
MatrixBlock result,
int rl,
int ru) |
applyScalarOp, applyScalarOp, computeColMxx, computeMxx, computeOffsets, createCompressedBitmaps, estimateInMemorySize, get, getBitmapOffsets, getBitmaps, getExactSizeOnDisk, getNumValues, getValues, hasZeros, len, mxxValues, preaggValues, readFields, sumValues, sumValues, write
getColIndex, getColIndices, getCompType, getNumCols, getNumRows, shiftColIndices
public ColGroupRLE()
public ColGroupRLE(int[] colIndices, int numRows, UncompressedBitmap ubm)
colIndices
- indices (within the block) of the columns included in this
columnnumRows
- total number of rows in the parent blockubm
- Uncompressed bitmap representation of the blockpublic ColGroupRLE(int[] colIndices, int numRows, boolean zeros, double[] values, char[] bitmaps, int[] bitmapOffs)
public Iterator<Integer> getDecodeIterator(int k)
getDecodeIterator
in class ColGroupBitmap
k
- index of a specific compressed bitmap (stored in subclass,
index same as ColGroupBitmap.getValues()
)public void decompressToBlock(MatrixBlock target, int rl, int ru)
ColGroup
decompressToBlock
in class ColGroupBitmap
target
- a matrix block where the columns covered by this column group
have not yet been filled in.rl
- row lowerru
- row upperpublic void decompressToBlock(MatrixBlock target, int[] colixTargets)
ColGroup
decompressToBlock
in class ColGroupBitmap
target
- a dense matrix block. The block must have enough space to hold
the contents of this column group.colixTargets
- array that maps column indices in the original matrix block to
columns of target.public void decompressToBlock(MatrixBlock target, int colpos)
ColGroup
decompressToBlock
in class ColGroupBitmap
target
- dense output vectorcolpos
- column to decompress, error if larger or equal numColspublic void rightMultByVector(MatrixBlock vector, MatrixBlock result, int rl, int ru) throws DMLRuntimeException
ColGroup
rightMultByVector
in class ColGroup
vector
- vector to multiply by (tall vector)result
- accumulator for holding the resultrl
- row lowerru
- row upperDMLRuntimeException
- if the internal SystemML code that performs the
multiplication experiences an errorpublic void leftMultByRowVector(MatrixBlock vector, MatrixBlock result) throws DMLRuntimeException
ColGroup
leftMultByRowVector
in class ColGroup
vector
- row vectorresult
- matrix block resultDMLRuntimeException
- if DMLRuntimeException occurspublic ColGroup scalarOperation(org.apache.sysml.runtime.matrix.operators.ScalarOperator op) throws DMLRuntimeException
ColGroup
scalarOperation
in class ColGroup
op
- operation to performDMLRuntimeException
- if DMLRuntimeException occurspublic void unaryAggregateOperations(org.apache.sysml.runtime.matrix.operators.AggregateUnaryOperator op, MatrixBlock result) throws DMLRuntimeException
unaryAggregateOperations
in class ColGroup
DMLRuntimeException
public void unaryAggregateOperations(org.apache.sysml.runtime.matrix.operators.AggregateUnaryOperator op, MatrixBlock result, int rl, int ru) throws DMLRuntimeException
unaryAggregateOperations
in class ColGroupBitmap
DMLRuntimeException
public boolean[] computeZeroIndicatorVector() throws DMLRuntimeException
DMLRuntimeException
protected void countNonZerosPerRow(int[] rnnz, int rl, int ru)
ColGroup
countNonZerosPerRow
in class ColGroup
rnnz
- non-zeros per rowrl
- row lower bound, inclusiveru
- row upper bound, exclusiveCopyright © 2017 The Apache Software Foundation. All rights reserved.