In [5]:
from scipy.sparse import coo_matrix, hstack

In [7]:
A = coo_matrix([[1, 2], [3, 4]])

In [8]:
A


Out[8]:
<2x2 sparse matrix of type '<class 'numpy.int64'>'
	with 4 stored elements in COOrdinate format>

In [9]:
A.toarray()


Out[9]:
array([[1, 2],
       [3, 4]])

In [13]:
B = coo_matrix([[5, 6, 7], [8, 9, 10]])

In [14]:
C = hstack([A, B])

In [15]:
C


Out[15]:
<2x5 sparse matrix of type '<class 'numpy.int64'>'
	with 10 stored elements in COOrdinate format>

In [16]:
C.toarray()


Out[16]:
array([[ 1,  2,  5,  6,  7],
       [ 3,  4,  8,  9, 10]], dtype=int64)

In [ ]: