如何更改 python Mayavi 的 window 标题?
How can I change the window title of python Mayavi?
如何将 window 标题 "Mayavi Scene 1" 更改为我自己的?
from __future__ import absolute_import, division, print_function
from mayavi import mlab
import numpy as np
fig = mlab.figure(figure=None, bgcolor=(0,0,0), fgcolor=None, engine=None, size=(400, 400))
data = np.random.rand(3, 3)
x, y, z = np.transpose(data)
mlab.points3d(x, y, z, -y, colormap="RdYlBu", scale_factor=1, scale_mode='none')
mlab.show()
像那样:
from mayavi import mlab
mlab.figure('My title')
s = mlab.mesh(x, y, z)
mlab.show()
如何将 window 标题 "Mayavi Scene 1" 更改为我自己的?
from __future__ import absolute_import, division, print_function
from mayavi import mlab
import numpy as np
fig = mlab.figure(figure=None, bgcolor=(0,0,0), fgcolor=None, engine=None, size=(400, 400))
data = np.random.rand(3, 3)
x, y, z = np.transpose(data)
mlab.points3d(x, y, z, -y, colormap="RdYlBu", scale_factor=1, scale_mode='none')
mlab.show()
像那样:
from mayavi import mlab
mlab.figure('My title')
s = mlab.mesh(x, y, z)
mlab.show()