def as_diag(self, copy=None):
        cov = _check_copy_dep(self, copy, default=True)
        if cov['diag']:
            return cov
        cov['diag'] = True
        cov['data'] = np.diag(cov['data'])
        cov['eig'] = None
        cov['eigvec'] = None
        return cov
Set covariance to be processed as being diagonal.
dataset/ETHPy150Open mne-tools/mne-python/mne/cov.py/Covariance.as_diag