scipy.sparse.dia_matrix.

scipy.sparse.dia_matrix.ndim#

свойство dia_matrix.ndim#