parameters: (filename, dm_name='Mixed')
return_statement: return num_dm
docstring: Get number of samples of 1RDM from file.
  
      Parameters
      ----------
      filename : string
          QMCPACK output containing density matrix (*.h5 file).
  
      Returns
      -------
      len_rdm : int
          Number of samples of 1RDM.
docstring_summary: Get number of samples of 1RDM from file.
docstring_tokens: Get number of samples of 1RDM from file .
function: def get_rdm_len(filename, dm_name='Mixed'):
      """Get number of samples of 1RDM from file.
  
      Parameters
      ----------
      filename : string
          QMCPACK output containing density matrix (*.h5 file).
  
      Returns
      -------
      len_rdm : int
          Number of samples of 1RDM.
      """
      with h5py.File(filename, 'r') as fh5:
          dms = fh5[dm_name].keys()
          # Block size of RDM is not necessarily known so just be dumb and count.
          num_dm = len([n for n in dms if 'denominator' in n])
      return num_dm
function_tokens: def get_rdm_len ( filename , dm_name = 'Mixed' ) : with h5py . File ( filename , 'r' ) as fh5 : dms = fh5 [ dm_name ] . keys ( ) # Block size of RDM is not necessarily known so just be dumb and count. num_dm = len ( [ n for n in dms if 'denominator' in n ] ) return num_dm