[Paraview] problems using pvbatch in frozen build

Utkarsh Ayachit utkarsh.ayachit at kitware.com
Fri Jul 8 11:38:47 EDT 2016


I got over such problems by delaying importing of those modules until
needed. They are not needed for most common use-cases.

See:
https://gitlab.kitware.com/paraview/paraview/commit/3af48fffd924bf5ffd11f576a261ef4eb3ff5897

On Tue, Jul 5, 2016 at 2:35 PM, Burlen Loring <bloring at lbl.gov> wrote:

> Hi All,
>
> I'm encountering some issues when trying to use pvbatch from a frozen
> build(PARAVIEW_FREEZE_PYTHON=ON). Seems that certain key python modules are
> missing.ie math. However, I can use Python shell feature in the GUI from
> the same build. Do we have any idea about what may be wrong with pvbatch?
>
>
> here is output from a simple test:
>
> nid00048:~$pvbatch pvbatch-test.py
> started
> Traceback (most recent call last):
>   File "pvbatch-test.py", line 3, in <module>
>     from paraview.simple import *
>   File
> "/usr/common/graphics/ParaView/builds/PV-4.4.0/lib/site-packages/paraview/simple.py",
> line 40, in <module>
>     import lookuptable
>   File
> "/usr/common/graphics/ParaView/builds/PV-4.4.0/lib/site-packages/paraview/lookuptable.py",
> line 21, in <module>
>     from math import sqrt
> ImportError: No module named math
>
> I tried this as well:
>
> nid00048:~$pvpython
> Python 2.7.9 (default, Jan  8 2015, 22:29:31)
> [GCC 4.9.1 20140716 (Cray Inc.)] on linux2
> Traceback (most recent call last):
>   File "/etc/pythonstart", line 7, in <module>
>     import readline
> ImportError: Excluded frozen object named readline
> >>> import math
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> ImportError: No module named math
> >>>
>
> Thanks
> Burlen
>
> _______________________________________________
> 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
>
> Search the list archives at: http://markmail.org/search/?q=ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/paraview
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20160708/4ad7c631/attachment.html>


More information about the ParaView mailing list