Class ABitmap
java.lang.Object
org.apache.sysds.runtime.compress.bitmap.ABitmap
- Direct Known Subclasses:
Bitmap,MultiColBitmap
-
Method Summary
Modifier and TypeMethodDescriptionfinal booleanFind out if the map contains zeros.abstract intGet the number of columns encoded in this bitmapabstract intgetNumNonZerosInOffset(int idx) Get the number of non zeros in a specific offset's tuple value.final longGet the sum of offsets contained.final intgetNumOffsets(int ix) Get the number of offsets for a specific unique offset.final intObtain number of distinct value groups in the column.final intGet the number of zero tuples contained in this bitmap.final IntArrayList[]Get all the offset lists.final IntArrayListgetOffsetsList(int idx) Get a specific offset list.toString()
-
Method Details
-
getOffsetList
Get all the offset lists.- Returns:
- the contained offset lists
-
getOffsetsList
Get a specific offset list.- Parameters:
idx- The index to look at inside the contained array- Returns:
- the Offset list at the index
-
getNumOffsets
public final long getNumOffsets()Get the sum of offsets contained.- Returns:
- The sum of offsets
-
getNumOffsets
public final int getNumOffsets(int ix) Get the number of offsets for a specific unique offset.- Parameters:
ix- The offset index.- Returns:
- The number of offsets for this unique value.
-
getNumZeros
public final int getNumZeros()Get the number of zero tuples contained in this bitmap.- Returns:
- The number of zero tuples
-
containsZero
public final boolean containsZero()Find out if the map contains zeros.- Returns:
- A boolean specifying if the bitmap contains zero offsets
-
getNumValues
public final int getNumValues()Obtain number of distinct value groups in the column. this number is also the number of bitmaps, since there is one bitmap per value- Returns:
- number of distinct value groups in the column;
-
getNumNonZerosInOffset
public abstract int getNumNonZerosInOffset(int idx) Get the number of non zeros in a specific offset's tuple value.- Parameters:
idx- The offset index to look at.- Returns:
- The nnz in the tuple.
-
getNumColumns
public abstract int getNumColumns()Get the number of columns encoded in this bitmap- Returns:
- The column count
-
toString
-