flux_modules/flux_module.py
def coo_rep_on_zero(A, rows_glob=None, cols_glob=None, vals_glob=None, sym=False):
  """ COO representation of matrix A on rank 0.

    :return:
      rank 0:        rows, cols, vals
      rank 1,2,... : None, None, None
    :rtype: (ndarray, ndarray, ndarray)
  """
  
  timer = Timer("COO representation")

  # noinspection PyBroadException
  try:  # DOLFIN 1.4+
    Acomp = PETScMatrix()
    A.copy().compressed(Acomp)
  except:
    Acomp = A   # Don't compress
      
  COO = backend_ext_module.COO(Acomp)

  return __coo_rep_on_zero_internal(COO, rows_glob, cols_glob, vals_glob, sym)
 COO representation of matrix A on rank 0.

    :return:
      rank 0:        rows, cols, vals
      rank 1,2,... : None, None, None
    :rtype: (ndarray, ndarray, ndarray)
  
COO representation of matrix A on rank 0.
COO representation of matrix A on rank 0 .
def coo_rep_on_zero(A, rows_glob=None, cols_glob=None, vals_glob=None, sym=False):
  timer = Timer("COO representation")
  try:  
    Acomp = PETScMatrix()
    A.copy().compressed(Acomp)
  except:
    Acomp = A   
  COO = backend_ext_module.COO(Acomp)
  return __coo_rep_on_zero_internal(COO, rows_glob, cols_glob, vals_glob, sym)
def coo_rep_on_zero ( A , rows_glob = None , cols_glob = None , vals_glob = None , sym = False ) : timer = Timer ( "COO representation" ) try : Acomp = PETScMatrix ( ) A . copy ( ) . compressed ( Acomp ) except : Acomp = A COO = backend_ext_module . COO ( Acomp ) return __coo_rep_on_zero_internal ( COO , rows_glob , cols_glob , vals_glob , sym )
COO representation of matrix A on rank 0.
COO representation of matrix A on rank 0 .
""" COO representation of matrix A on rank 0.

    :return:
      rank 0:        rows, cols, vals
      rank 1,2,... : None, None, None
    :rtype: (ndarray, ndarray, ndarray)
  """ # noinspection PyBroadException # DOLFIN 1.4+ # Don't compress
rank 0:        rows, cols, vals
rank 1,2,...
rank 0 : rows cols vals rank 1 2 ...
(ndarray, ndarray, ndarray)
A
rows_glob
cols_glob
vals_glob
sym