[Paraview] Error trying to run python script

Utkarsh Ayachit utkarsh.ayachit at kitware.com
Sat Jun 28 10:15:03 EDT 2014


Chuks,

The trace missing the filename is indeed a bug. We are working on
refactoring the tracing code right now, so tracing should get better
in the next release.

The error you get when you explicitly set the FileName is due to the
fact that the property is called FileNames and not FileName
(http://www.paraview.org/ParaView3/Doc/Nightly/www/py-doc/paraview.simple.XDMFReader.html?highlight=xdmfreader#paraview.simple.XDMFReader).

To overcome such issues, you can also use the OpenDataFile()
(http://www.paraview.org/ParaView3/Doc/Nightly/www/py-doc/paraview.simple.html#paraview.simple.OpenDataFile)
function instead:

reader = OpenDataFile("....foo.xmf")

Utkarsh

On Mon, Jun 23, 2014 at 2:40 PM, Chukwudi Chukwudozie
<cchukw1 at tigers.lsu.edu> wrote:
> Hi,
>
> I recently built and installed paraview 4.1 on my mac with the intention of
> doing python scripting but when I save a trace and try to run it using
> pvpython, I get the following error messages. But looking at the trace, I
> see that it does not reference the file it is loading as you can see here
>
> TEST_00000_xmf = XDMFReader()
>
> The XDMFReader argument is empty
>
>
>
> Below is error message on terminal
>
>
> Traceback (most recent call last):
>   File "fracture.py", line 5, in <module>
>     TEST_00000_xmf = XDMFReader(
> FileName='/Users/chukwudichukwudozie/Desktop/vf-chevron/ValidationTests/TEST.00000.xmf'
> )
>   File "/Applications/ParaView.app/Contents/Python/paraview/simple.py", line
> 1183, in CreateObject
>     SetProperties(px, **params)
>   File "/Applications/ParaView.app/Contents/Python/paraview/simple.py", line
> 374, in SetProperties
>     raise AttributeError("object has no property %s" % param)
> AttributeError: object has no property FileName
> wireless-10-146-16-226:Python chukwudichukwudozie$ pvpython fracture.py
> ERROR: In
> /Users/chukwudichukwudozie/softwares/ParaView/VTK/IO/Xdmf2/vtkXdmfReader.cxx,
> line 189
> vtkXdmfReader (0x7fe7d58b7800): File name not set
>
> ERROR: In
> /Users/chukwudichukwudozie/softwares/ParaView/VTK/Common/ExecutionModel/vtkExecutive.cxx,
> line 754
> vtkPVCompositeDataPipeline (0x7fe7d58bd3a0): Algorithm
> vtkFileSeriesReader(0x7fe7d58bb620) returned failure for request:
> vtkInformation (0x7fe7d58bebd0)
>   Debug: Off
>   Modified Time: 148835
>   Reference Count: 1
>   Registered Events: (none)
>   Request: REQUEST_DATA_OBJECT
>   ALGORITHM_AFTER_FORWARD: 1
>   FORWARD_DIRECTION: 0
>
>
>
> ERROR: In
> /Users/chukwudichukwudozie/softwares/ParaView/VTK/IO/Xdmf2/vtkXdmfReader.cxx,
> line 189
> vtkXdmfReader (0x7fe7d58b7800): File name not set
>
> ERROR: In
> /Users/chukwudichukwudozie/softwares/ParaView/VTK/Common/ExecutionModel/vtkExecutive.cxx,
> line 754
> vtkPVCompositeDataPipeline (0x7fe7d58b9e20): Algorithm
> vtkXdmfReader(0x7fe7d58b7800) returned failure for request: vtkInformation
> (0x7fe7d58c1730)
>   Debug: Off
>   Modified Time: 148843
>   Reference Count: 1
>   Registered Events: (none)
>   Request: REQUEST_DATA_OBJECT
>   ALGORITHM_AFTER_FORWARD: 1
>   FORWARD_DIRECTION: 0
>
>
>
> ERROR: In
> /Users/chukwudichukwudozie/softwares/ParaView/VTK/IO/Xdmf2/vtkXdmfReader.cxx,
> line 189
> vtkXdmfReader (0x7fe7d58b7800): File name not set
>
> ERROR: In
> /Users/chukwudichukwudozie/softwares/ParaView/VTK/Common/ExecutionModel/vtkExecutive.cxx,
> line 754
> vtkPVCompositeDataPipeline (0x7fe7d58b9e20): Algorithm
> vtkXdmfReader(0x7fe7d58b7800) returned failure for request: vtkInformation
> (0x7fe7d58c1730)
>   Debug: Off
>   Modified Time: 148843
>   Reference Count: 1
>   Registered Events: (none)
>   Request: REQUEST_DATA_OBJECT
>   ALGORITHM_AFTER_FORWARD: 1
>   FORWARD_DIRECTION: 0
>
> Chuks
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/paraview
>


More information about the ParaView mailing list