Dear All,
I have the following codes, and have problems as follows:
・The plot is not displayed until the cmap is changed, Can I fix it? ・The name of the windows is "Edit properties", can I change it to Mayavi scence?
def show(self): print "Plotting...", mlab.view(distance = 'auto') mlab.outline( line_width=1.0, opacity=0.3 ) mlab.axes() mlab.show() def __init__(self, arg1, arg2, arg3, arg4): HasTraits.__init__(self) self.file_peaks = arg1 self.file_pat_dist = arg2 self.file_hess_dist = arg3 self.file_id_dist = arg4 @on_trait_change('lower_threshold_for_cmap,upper_threshold_for_cmap') def update_plot(self): mlab.clf() peaks = self.add_peak(self.file_peaks) self.add_grid(self.file_pat_dist, cmap=[self.lower_threshold_for_cmap, self.upper_threshold_for_cmap]) # [0.02, 0.4] self.show() scene = Instance(MlabSceneModel, ()) # The layout of the dialog created view = View(Item('scene', editor=SceneEditor(scene_class=MayaviScene), height=350, width=350, show_label=False), Group('_', 'lower_threshold_for_cmap', 'upper_threshold_for_cmap'), resizable=True) Kind Regards Mike
Log in to post a comment.
Dear All,
I have the following codes, and have problems as follows:
・The plot is not displayed until the cmap is changed, Can I fix it?
・The name of the windows is "Edit properties", can I change it to Mayavi scence?