Package org.apache.sysds.runtime.matrix.data

## Interface LibMatrixDenseToSparse

    public interface LibMatrixDenseToSparse

### Field Summary

Fields
`static org.apache.commons.logging.Log` `LOG`

### Method Summary

Static Methods
`static void` `denseToSparse​(MatrixBlock r, boolean allowCSR)` Convert the given matrix block to a sparse allocation.
`static void` `denseToSparse​(MatrixBlock r, boolean allowCSR, int k)`

### Field Detail

#### LOG

    static final org.apache.commons.logging.Log LOG

### Method Detail

#### denseToSparse

    static void denseToSparse​(MatrixBlock r,
                              boolean allowCSR)

Convert the given matrix block to a sparse allocation.

Parameters:
  `r` - The matrix block to modify, and return the sparse block in.
  `allowCSR` - If CSR is allowed.

#### denseToSparse

    static void denseToSparse​(MatrixBlock r,
                              boolean allowCSR,
                              int k)