mtl5.sparse.coo_matrix#

mtl5.sparse.coo_matrix(row: ndarray, col: ndarray, data: ndarray, shape: tuple[int, int])#

Construct an MTL5 COO matrix from scipy-style (row, col, data) triplets.

Duplicate coordinates accumulate rather than overwrite, matching scipy.sparse.coo_matrix: the duplicates stay in the triplet list, nnz counts them separately, reading an element sums them, and tocsr() folds them into one entry.