On 03/21/2013 04:13 PM, Angel Goñi Moreno wrote:
El jueves, 21 de marzo de 2013 15:59:04 UTC+1, Robert Cimrman escribió:
On 03/21/2013 03:45 PM, Angel Go?i Moreno wrote:
El jueves, 21 de marzo de 2013 14:52:57 UTC+1, Robert Cimrman escribi?:
After installing everything, I run $ ./simple.py
examples/diffusion/poisson.py as the tutorial says. The file
created. Then I run ./postproc.py cylinder.vtk but when I do so I get
*traits.trait_errors.TraitError: The 'current_scene' trait of an
instance must be a Scene or None, but a value of <enthought.mayavi.core.scene.Scene object at 0xc6ff6b0> <class 'enthought.mayavi.core.scene.Scene'> was specified.*
Could you post the whole error message (if there is), so that we can
the line numbers?
/home/angel/Escritorio/PDE/etsproxy/enthought/__init__.py:7: DeprecationWarning: enthought namespace imports are deprecated DeprecationWarning) Traceback (most recent call last): File "./postproc.py", line 444, in <module> main() File "./postproc.py", line 437, in main view = view_file(filenames, filter_names, options) File "./postproc.py", line 250, in view_file domain_specific=options.domain_specific) File "/home/angel/Escritorio/PDEs/sfepy-master/sfepy/postprocess/viewer.py", line 837, in call_mlab self.engine.current_scene = self.scene File "/home/angel/Escritorio/PDE/traits/traits/trait_types.py", line 2724, in validate self.validate_failed( object, name, value ) File "/home/angel/Escritorio/PDE/traits/traits/trait_types.py", line 2555, in validate_failed self.error( object, name, value ) File "/home/angel/Escritorio/PDE/traits/traits/trait_handlers.py",
170, in error value ) traits.trait_errors.TraitError: The 'current_scene' trait of an Engine instance must be a Scene or None, but a value of <enthought.mayavi.core.scene.Scene object at 0xa886cb0> <class 'enthought.mayavi.core.scene.Scene'> was specified.
Well, I do not really understand this error message - it says the trait has to be Scene, and complains that it is enthought.mayavi.core.scene.Scene, which has been exactly the same thing...
What is yout Mayavi version?
Buf! I would rather not downgrade mayavi now that something works at least :-) I will email Enthought directly and will post here their reply.
I can run mayavi first and then load the file cylinder.vtk but it
cylinder all blue and not as in the tutorial online.
So you used the surface module to see something, right? The click on
file name and change "Point scalars name" from "node_groups" to "t" and you should see the temperature distribution. Does it help?
Ok, something works at least!
It does. Btw, is it the same thing? I mean, but drawing the file in this way, do I get the same info/result as with the postproc.py order?
Yes, postproc.py is just a way of quickly seeing the results by setting some reasonable default filters/modules for each dataset in a results file. You can get the same thing by setting up the VTK pipeline manually in the Mayavi GUI. It's just more mouse work :)