Stc.plot - colorbar problem

Hi! :slight_smile:
I am trying to do some stc plots but I have problem with colorbar.
Code:
brain = stc.plot(clim=dict(kind=‘percent’, lims=[30, 45, 60]),colorbar=True,transparent=True,subjects_dir=subjects_dir, views=‘dorsal’, hemi=‘both’,background=‘white’,smoothing_steps=25, time_label=‘wPLI’)
It shows colors in the strange way. Can you help me how can I fix it?

Best,
Marta

mne.sys_info()
Platform: Windows-10-10.0.19042-SP0
Python: 3.9.6

mne: 0.23.0
numpy: 1.21.0 {blas=NO_ATLAS_INFO, lapack=lapack}
scipy: 1.7.0
matplotlib: 3.4.2 {backend=module://matplotlib_inline.backend_inline}

sklearn: 0.24.2
numba: 0.53.1
nibabel: 3.2.1
nilearn: 0.8.0
dipy: 1.4.1
cupy: Not found
pandas: 1.3.0
mayavi: 4.7.2
pyvista: 0.31.3 {pyvistaqt=0.5.0, OpenGL 4.5.0 - Build 27.20.100.8935 via Intel(R) Iris(R) Plus Graphics}
vtk: 9.0.1
PyQt5: 5.12.3

cc @GuillaumeFavelier, who might know what’s going on :blush:

1 Like

can you share a full snippet to replicate?

is it a problem you see with an stc plot on your system?

Alex

Yes I can see this problem with all stc plots

threshold_prop = 0.20  

degree = mne.connectivity.degree(con_s, threshold_prop=threshold_prop)

stc = mne.labels_to_stc(labels_parc, degree)

brain = stc.plot(

    clim=dict(kind='value', pos_lims=[0.5, 0.6, 0.7]),colormap='bwr',colorbar=True,transparent=True,

    subjects_dir=subjects_dir, views='dorsal', hemi='both',background='white',

    smoothing_steps=25)

Marta

then it’s an install problem or a problem on your system.

Alex

ok, thanks for help Alex! :slight_smile:

Marta

@mkkubins Did you install everything according to the official installation instructions?

Can you check if your system’s graphics card drivers are up to date?

I checked this and it is updated. I will reinstall my system and if it still be a issue I will post it here again :slight_smile: