SciPy

scipy.sparse.bsr_matrix.shape

bsr_matrix.shape