def _compute_cov_epochs(epochs, n_jobs):
 (parallel, p_fun, _) = parallel_func(np.dot, n_jobs)
 data = parallel((p_fun(e, e.T) for e in epochs))
 n_epochs = len(data)
 if (n_epochs == 0):
  raise RuntimeError('No good epochs found')
 (n_chan, n_samples) = (epochs.info['nchan'], len(epochs.times))
 _check_n_samples((n_samples * n_epochs), n_chan)
 data = sum(data)
 return data

def _compute_cov_epochs ( epochs , n_jobs ) : ( parallel , p_fun , _ ) = parallel_func ( np . dot , n_jobs ) data = parallel ( ( p_fun ( e , e . T ) for e in epochs ) ) n_epochs = len ( data ) if ( n_epochs == 0 ) : raise RuntimeError ( 'No good epochs found' ) ( n_chan , n_samples ) = ( epochs . info [ 'nchan' ] , len ( epochs . times ) ) _check_n_samples ( ( n_samples * n_epochs ) , n_chan ) data = sum ( data ) return data
helper function for computing epochs covariance .