[Paraview-developers] Rendering in Paraview using python

sumeet kumar sumeet.kumar507 at gmail.com
Fri Apr 14 11:08:43 EDT 2017


Hi Andy,

LoadPlugin() helps in pvpython. But why does
*from  paraview.simple import * *does not work???

Why I need to externally load my plugin even I build with paraview source.
Also, I don't think, Its a good design to set PV_PLUGIN_PATH  or
PV_PLUGIN_CONFIG_FILE even when the plugin is build with source. The file
"plugin.cmake" should take care all of this.

Thanks
Sumeet

On Fri, Apr 14, 2017 at 7:01 AM, Andy Bauer <andy.bauer at kitware.com> wrote:

> Hi,
>
> My guess is that the reader plugin is automatically loaded in the GUI but
> not when you run pvpython directly. Look at the LoadPlugin() or
> LoadDistributedPlugin() command in pvpython.
>
> Are you setting PV_PLUGIN_PATH or PV_PLUGIN_CONFIG_FILE? Another guess may
> be that you're using PV_PLUGIN_PATH and/or PV_PLUGIN_CONFIG_FILE to load
> the plugin automatically through the GUI and that isn't being utilized when
> running with pvpython. See http://www.paraview.org/Wiki/Plugin_HowTo for
> information on that.
>
> Best,
> Andy
>
> On Thu, Apr 13, 2017 at 11:34 PM, sumeet kumar <sumeet.kumar507 at gmail.com>
> wrote:
>
>> Hey,
>>
>> I have a reader plugin integrated with paraview that works perfectly
>> fine. I could use the same plugin to trace an "equivalent python code" for
>> any visualization example.  The generated python code can be run again on
>> paraview gui.
>> BUT, when i try to follow the same python command in python externally
>> like pvpython. I get the following error.
>>
>> >>> from paraview.simple import *
>> updating active connection None
>> paraview version 5.2.0-RC1
>> updating active connection Connection (builtin:) [1]
>> updating active connection Connection (builtin:) [1]
>> >>> beam_Axial_Loadh5feioutput = pvESSI(FileName="/home/sumeet/Desktop
>> /Beam_Axial_Load.h5.feioutput")
>> Traceback (most recent call last):
>>   File "<stdin>", line 1, in <module>
>> NameError: name 'pvESSI' is not defined
>>
>> My plugin name is pvESSI. the same line works on paraview GUI mode in
>> python shell. I tried to look on the Internet and build the plugin inside
>> the paraview source itself, but the problem remains.
>>
>> Others have suggested here on link http://www.paraview.org/piperm
>> ail/paraview/2013-October/029428.html, but I dont understand where to
>> make changes to fix this problem.
>>
>>
>> Any help would be highly appreciated.
>>
>> Best Regards
>> Sumeet
>> --
>>
>> Sumeet Kumar Sinha
>> Graduate Student
>> Phone: (+1)  <%28%2B91%29%209910516219>5306018271 <(530)%20601-8271>
>> Website : http://www.sumeetksinha.com/
>>
>
>


-- 

Sumeet Kumar Sinha
Graduate Student
Phone: (+1)  <%28%2B91%29%209910516219>5306018271
Website : http://www.sumeetksinha.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview-developers/attachments/20170414/ef4612e4/attachment-0001.html>


More information about the Paraview-developers mailing list