def METHOD_NAME(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