row = scipy.array([1, 3, 5, 7, 9])
col = scipy.array([2, 4, 6, 8, 10])
values = scipy.ones(col.size)
m = coo_matrix((values, (row, col)), shape=(nrows, ncols), dtype=float)
Calculate Similarity of Sparse Matrix