def inplace_swap_row(X, m, n):
 if isinstance(X, sp.csc_matrix):
  return inplace_swap_row_csc(X, m, n)
 elif isinstance(X, sp.csr_matrix):
  return inplace_swap_row_csr(X, m, n)
 else:
  _raise_typeerror(X)

def inplace_swap_row ( X , m , n ) : if isinstance ( X , sp . csc_matrix ) : return inplace_swap_row_csc ( X , m , n ) elif isinstance ( X , sp . csr_matrix ) : return inplace_swap_row_csr ( X , m , n ) else : _raise_typeerror ( X )
swaps two rows of a csc/csr matrix in-place .