[vtkusers] vtk.vtkVersion() not exposed to python?
Johann Cohen Tanugi
cohen at slac.stanford.edu
Fri May 5 10:42:49 EDT 2006
Python 2.4.2 (#3, Apr 21 2006, 11:56:28)
[GCC 3.2.3 20030502 (Red Hat Linux 3.2.3-47)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from vtk import common
>>> common.vtkVersion.GetVTKVersion()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'module' object has no attribute 'vtkVersion'
>>> common
<module 'vtk.common' from
'/data0/local/lib/python2.4/site-packages/vtk/common.pyc'>
>>> dir(common)
['Common', 'Data', 'DataSet', 'DataSetAttr', '__builtins__', '__doc__',
'__file__', '__name__', '_getline', 'is_celldata', 'is_dataset',
'is_datasetattr', 'is_float01', 'is_int', 'is_int255', 'is_number',
'is_pointdata', 'is_sequence', 'is_sequence2', 'is_sequence3',
'is_string', 'struct', 'sys', 'types']
>>> from common import Common
Traceback (most recent call last):
File "<stdin>", line 1, in ?
ImportError: No module named common
>>> from vtk import Common
>>> Common.vtkVersion.GetVTKVersion()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: class Common has no attribute 'vtkVersion'
>>> dir(Common)
['__doc__', '__module__', '__str__', '_get_nof_objs', '_get_trace',
'default_float', 'default_int', 'error', 'float01_to_int255',
'get_3_3_tuple', 'get_3_3_tuple_list', 'get_3_tuple',
'get_3_tuple_list', 'get_datatype', 'get_n_seq_seq', 'get_seq',
'get_seq_seq', 'int255_to_float01', 'message', 'seq_to_string',
'skipping', 'struct_fmt_map', 'warning']
>>>
cheers,
Johann
Prabhu Ramachandran wrote:
>>>>>>"JCT" == Johann Cohen Tanugi <cohen at slac.stanford.edu> writes:
>>>>>>
>>>>>>
>
> JCT> Well at least I see a few ways I can patch MayaVi locally in
> JCT> order to be able to run it..... I do not understand how I
> JCT> can be missing this lib and still be able to test the python
> JCT> functionalities to vtk fine....
>
>Try this and see if it helps refine your search for the error:
>
> >>> from vtk import common
> >>> common.vtkVersion.GetVTKVersion()
> '5.0.0'
>
>cheers,
>prabhu
>
>
More information about the vtkusers
mailing list