Template Class ReorderHeatmap
Defined in File reorder_heatmap.h
Inheritance Relationships
Base Type
public sparsebase::utils::FunctionMatcherMixin< format::FormatOrderOne< FloatType > * >
(Template Class FunctionMatcherMixin)
Class Documentation
-
template<typename IDType, typename NNZType, typename ValueType, typename FloatType>
class sparsebase::reorder::ReorderHeatmap : public sparsebase::utils::FunctionMatcherMixin<format::FormatOrderOne<FloatType>*> Calculates density of non-zeros of a 2D format on a num_parts * num_parts grid
Splits the input 2D matrix into a grid of size num_parts * num_parts containing an equal number of rows and columns, and calculates the density of non-zeros in each cell in the grid relative to the total number of non-zeros in the matrix, given that the matrix was reordered according to a permutation matrix. Returns the densities as a dense array (FormatOrderOne) of size num_parts * num_parts where the density at cell [i][j] in the 2D grid is located at index [i*num_parts+j] in the grid. The density values sum up to 1.
- tparam FloatType
type used to represent the densities of non-zeros.
Protected Static Functions
-
static format::FormatOrderOne<FloatType> *ReorderHeatmapCSRArrayArray(std::vector<format::Format*> formats, utils::Parameters *poly_params)