jorge.conrado | 8 Dec 14:53 2015
Picon

save figure

Hi,

This is a small part of my script:

mlab.quiver3d(u, v, w)

mlab.outline()

mlab.show()

mlab.savefig('t.png')

I have my image on screen but my t.png figure have only a grey tone. How 
can I save my figure.

I run my script using: python ventogr.py How can resize my mayavi 
window.

Conrado

------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741911&iu=/4140
Gael Varoquaux | 26 Nov 17:37 2015
Gravatar

Mayavi in latest ubuntu

Mayavi doesn't work in the latest Ubuntu. It's probably a misconfigured
VTK (nothing to do with Mayavi). I have submitted a bug report to Ubuntu.
If people click on the 'flame' icon to show that they are also affected
by this bug, it may make it move up the priority list:
https://bugs.launchpad.net/ubuntu/+source/vtk/+bug/1520306

Gaƫl

------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741551&iu=/4140
jorge.conrado | 10 Nov 16:52 2015
Picon

contour plot


Hi,

I have the contorno.py plot that I get from the: 
http://docs.enthought.com/mayavi/mayavi/auto/example_contour.html

I did:

python contorno.py

and I had:

Warning: Unable to import the wx backend for pyface due to traceback: 
Traceback (most recent call last):
           File 
"/usr/lib/python2.7/site-packages/pyface-4.5.2-py2.7.egg/pyface/toolkit.py", 
line 49, in _init_toolkit
             be = import_toolkit(tk)
           File 
"/usr/lib/python2.7/site-packages/pyface-4.5.2-py2.7.egg/pyface/toolkit.py", 
line 31, in import_toolkit
             __import__(be + 'init')
           File 
"/usr/lib/python2.7/site-packages/pyface-4.5.2-py2.7.egg/pyface/ui/wx/init.py", 
line 14, in <module>
             import wx
         ImportError: No module named wx

What can I do to solve this.

(Continue reading)

jorge.conrado | 6 Nov 17:26 2015
Picon

enthought


Hi,

I'm a neuw users of Mayvai. I took an example contour.py from:

http://scipy-cookbook.readthedocs.org/items/MayaVi_examples.html

then I did :

python contour.py

and I had the message:

Traceback (most recent call last):
   File "contour.py", line 14, in <module>
     import enthought.mayavi
ImportError: No module named enthought.mayavi

Please what can I do to solve this error.

Conrado

------------------------------------------------------------------------------
jorge.conrado | 6 Nov 14:18 2015
Picon

3D data plot


Hi,

I'm starting to use Mayavi and I would like know how to plot the axis 
values for 3D vizualisation.

Tanks in advance,

Conrado

------------------------------------------------------------------------------
Christopher Snyder | 6 Sep 20:45 2015
Picon

volume rendering -- without bluring. (make it so you can see the actual voxel boundaries)

Hi,

Let's say I'm volume rendering a fairly small array 10x10x10. How can I make it so that it is clear that the produced image is the granular result of 10pixels in each dimension? I looked into setting anti-aliasing=0, but I don't think that was it.

Thanks,
Chris
------------------------------------------------------------------------------
_______________________________________________
MayaVi-users mailing list
MayaVi-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users
Christopher Snyder | 23 Aug 13:18 2015
Picon

how to set ctf and otf for volume rendering-- not in scripting mode

Hi,

This problem is well covered in scripting mode here

In the case of a gui, Gael suggested somewhere using the record function. I find it does not reflect changes in the ctf widget.

Here is my code. I find that I can access the ctf fine, and that the ctf I access is sensitive to changes in the gui widget. I just can't find a way to set the ctf.

class Vis(HasTraits):
    scene     = Instance(MlabSceneModel,())    
    save=Button()
    load=Button()
    editor=SceneEditor(scene_class=MayaviScene)
    def __init__(self,G):
        self.G=G
        HasTraits.__init__(self)
        self.array_src=ArraySource()
        self.array_src.scalar_data=G
        self.scene.mayavi_scene.add_child(self.array_src)
        self.vol_module=Volume()
        self.volume=self.array_src.add_module(self.vol_module)

    def _save_fired(self):
        self.my_crf=self.vol_module.volume_property.rgb_transfer_function ##Works!!
    def _load_fired(self):
        self.vol_module.volume_property.set_color(self.init_crf) ##Fails and I need help
 
   traits_view = View( ..)

vis=Vis(G)
vis.configure_traits()



Obvious workarounds like settings _ctf directly don't seem to work.

Thanks,
Chris
------------------------------------------------------------------------------
_______________________________________________
MayaVi-users mailing list
MayaVi-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users
Christopher Snyder | 13 Aug 10:42 2015
Picon

bug with volume colortransfer function mayavi

Dear all,

I think I have come across a genuine bug. It seems that something very strange and certainly unintuitive is happening with the colortransferfunction(CTF) interface.

I'll describe here what I've shown in the attached movie.

Action: mlab.pipeline.volume(whatever). It doesn't matter how the volume rendering is created.
Result: The volume source is displayed as red. Fine.

Action: The user just clicks on the volume transfer function without changing it much. You can even move it back to exactly where it was.
Result: The volume source totally changes colors from red to green: suggesting the CTF in the "Mayavi pipeline" window is not the same as the one originally used in "Mayavi Scene 1"

Action: The user,  having clicked on the opacity transfer function at least once, clicks away. Then the user clicks back.
Result: The CTF totally changes to this blue-red fade instead of this nice three-color style before. If the user messes with the OTF once more, update CTF will change the volume again! from this green color to this red-purple-ish.

Note: It's not just "clicking away" and clicking back that causes this weird change in CTF. I originally ran into this problem while changing data sources. I had say 5 difference volumes. Whenever I would say "array_src.scalar_values=my_volumes.next()" the CTF would change from a rgb to a blue-red fade if and only if I had tried to alter the ctf manually in the GUI.

I really hope we can get this resolved.

Thanks,
Chris Snyder

------------------------------------------------------------------------------
_______________________________________________
MayaVi-users mailing list
MayaVi-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users
Christopher Snyder | 1 Aug 15:15 2015
Picon

ArraySource vs ScalarField produces different results

Specifically I can't get them to look the same by adjusting all the parameters I can find on the GUI.

Side question: I couldn't figure out how to synchronize the colormaps for each scene to get a rigorous comparison.

On the one hand I call mlab.pipeline.volume(scalar_field_object) and I get a very nice volume that is mostly translucent except for the main region of intensity.

On the other I have this ArraySource.add_module(mlab.modules.Volume()) #sudo code, don't actually try either of these things, and I get very opaque image volumes even from areas of low intensity.

Any thoughts ?

Chris
------------------------------------------------------------------------------
_______________________________________________
MayaVi-users mailing list
MayaVi-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users
Christopher Snyder | 29 Jul 01:02 2015
Picon

volume rendering with anisotropic, but regularly spaced pixels, (delz=2*delz=2*dely)

Hi there,

My usual routine involves
ix,iy,iz=np.indices(Image)
s=mlab.pipeline.scalar_field(spacing[0]*ix,spacing[1]*iy,spacing[2]*iz,Image)
mlab.pipeline(volume(s))

However, I am strapped for memory. Actually forming the indices ix,iy,iz is putting a burden on my code. Is there some workaround, perhaps through the depths of vtk, that lets me specify this with just the scalar tuple (1,1,2) ??? 

Thanks in anticipation,
Chris Snyder
------------------------------------------------------------------------------
_______________________________________________
MayaVi-users mailing list
MayaVi-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users
Andrew Andrade | 23 Jul 01:02 2015
Picon

Representing an additional scalar on barchart

Hello everyone,

Sorry for my noobness, I am somewhat new to Mayavi. I have 3d visualization working using the bar chart.  The data is discrete across all four variables (not a surface)

I have a 4th dimention of the same size and I wanted to represent that via color, effectively showing the relationship between the 4 variables.

Any idea how to do this? I found this post [1] , but my values are a list of scalars not a function. 

Where results is a pandas dataframe, if I put in barchart(results.var1, results.var2 ,results.var3, results.var4) it gives me incorrect plots, so I am confused what the S argument is for the function. Any ideas?


Thanks,

Andrew

http://gael-varoquaux.info/programming/mayavi-representing-an-additional-scalar-on-surfaces.html
------------------------------------------------------------------------------
_______________________________________________
MayaVi-users mailing list
MayaVi-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users

Gmane