Class AColGroupOffset
- java.lang.Object
-
- org.apache.sysds.runtime.compress.colgroup.AColGroup
-
- org.apache.sysds.runtime.compress.colgroup.AColGroupCompressed
-
- org.apache.sysds.runtime.compress.colgroup.AColGroupValue
-
- org.apache.sysds.runtime.compress.colgroup.AColGroupOffset
-
- All Implemented Interfaces:
Serializable
,Cloneable
- Direct Known Subclasses:
ColGroupOLE
,ColGroupRLE
public abstract class AColGroupOffset extends AColGroupValue
Base class for column groups encoded with various types of bitmap encoding. NOTES: * OLE: separate storage segment length and bitmaps led to a 30% improvement but not applied because more difficult to support both data layouts at the same time (distributed/local as well as w/ and w/o low-level opt)- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.sysds.runtime.compress.colgroup.AColGroup
AColGroup.CompressionType
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
countNonZerosPerRow(int[] rnnz, int rl, int ru)
long
estimateInMemorySize()
Get the upper bound estimate of in memory allocation for the column group.int[]
getBitmapOffsets()
char[]
getBitmaps()
double
getCost(ComputationCostEstimator e, int nRows)
Get the computation cost associated with this column group.long
getExactSizeOnDisk()
Returns the exact serialized size of column group.boolean
hasZeros()
void
readFields(DataInput in)
Deserialize column group from data input.String
toString()
void
write(DataOutput out)
Serializes column group to data output.-
Methods inherited from class org.apache.sysds.runtime.compress.colgroup.AColGroupValue
centralMoment, computeColSums, containsValue, copy, decompressToDenseBlock, decompressToSparseBlock, forceMatrixBlockDictionary, getCachedCounts, getCounts, getCounts, getDictionary, getNumberNonZeros, getNumValues, replace, rexpandCols, rightMultByMatrix
-
Methods inherited from class org.apache.sysds.runtime.compress.colgroup.AColGroupCompressed
getMax, getMin, preAggRows, tsmm, unaryAggregateOperations, unaryAggregateOperations
-
Methods inherited from class org.apache.sysds.runtime.compress.colgroup.AColGroup
binaryRowOpLeft, binaryRowOpRight, colSum, decompressToDenseBlock, decompressToSparseBlock, get, getColIndices, getCompType, getIdx, getNumCols, leftMultByAColGroup, leftMultByMatrixNoPreAgg, scalarOperation, shiftColIndices, sliceColumn, sliceColumns, tsmmAColGroup, unaryOperation
-
-
-
-
Method Detail
-
estimateInMemorySize
public long estimateInMemorySize()
Description copied from class:AColGroup
Get the upper bound estimate of in memory allocation for the column group.- Overrides:
estimateInMemorySize
in classAColGroupValue
- Returns:
- an upper bound on the number of bytes used to store this ColGroup in memory.
-
getBitmaps
public char[] getBitmaps()
-
getBitmapOffsets
public int[] getBitmapOffsets()
-
hasZeros
public boolean hasZeros()
-
readFields
public void readFields(DataInput in) throws IOException
Description copied from class:AColGroup
Deserialize column group from data input.- Overrides:
readFields
in classAColGroupValue
- Parameters:
in
- data input- Throws:
IOException
- if IOException occurs
-
write
public void write(DataOutput out) throws IOException
Description copied from class:AColGroup
Serializes column group to data output.- Overrides:
write
in classAColGroupValue
- Parameters:
out
- data output- Throws:
IOException
- if IOException occurs
-
getExactSizeOnDisk
public long getExactSizeOnDisk()
Description copied from class:AColGroup
Returns the exact serialized size of column group. This can be used for example for buffer preallocation.- Overrides:
getExactSizeOnDisk
in classAColGroupValue
- Returns:
- exact serialized size for column group
-
countNonZerosPerRow
public abstract void countNonZerosPerRow(int[] rnnz, int rl, int ru)
-
getCost
public double getCost(ComputationCostEstimator e, int nRows)
Description copied from class:AColGroup
Get the computation cost associated with this column group.
-
toString
public String toString()
- Overrides:
toString
in classAColGroupValue
-
-