# ica_data[epochs_idx,channels_idx] /= ica_data[epochs_idx].sum() ica_data_reshape = ica_data.reshape( (ica_data.shape[0], ica_data.shape[1] * ica_data.shape[2])) #------------------------------------------------------------------------------ #Checking ICA through plot method = 'fastica' random_state = 42 ica = ICA(n_components=13, method=method, random_state=random_state) ica.fit(epochs) ica.plot_components() ica.plot_properties(epochs, picks=0) ica.plot_overlay(evoked, title='Plot Overlay', show=True) #------------------------------------------------------------------------------ #------------------------------------------------------------------------------ #------------------------------------------------------------------------------ from PIL import Image import os.path, sys #zero-produceERP-Image steps = np.arange(9.5, 20.5, 0.001) for step in steps: evoked_zero.plot_topomap(times=step, show=False, colorbar=False, time_unit='s')