Re: [Paraview] PYTHONPATH environmental variable
Hi Felix, I just happened upon the same problem yesterday. The solution was to add the directory with the vkt shared objects into the PYTHONPATH. Those are in .../site-packages/vtk. The .../site-packages/paraview/vtk is just a mirror that includes the libraries from the top-level vtk directory. Hope this helps. Regards, Timo ___ 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
Re: [Paraview] PYTHONPATH environmental variable
I find it easier to figure this out by using pvpython and then doing the following: import sys print sys.path The path should have all the directories that need to be set in your PYTHONPATH. Utkarsh On Fri, Jun 19, 2015 at 2:15 AM Timo Oster timo.os...@ovgu.de wrote: Hi Felix, I just happened upon the same problem yesterday. The solution was to add the directory with the vkt shared objects into the PYTHONPATH. Those are in .../site-packages/vtk. The .../site-packages/paraview/vtk is just a mirror that includes the libraries from the top-level vtk directory. Hope this helps. Regards, Timo ___ 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 ___ 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
Re: [Paraview] PYTHONPATH environmental variable
Tried it, but for some reason, it breaks python $ python Could not find platform independent libraries prefix Could not find platform dependent libraries exec_prefix Consider setting $PYTHONHOME to prefix[:exec_prefix] ImportError: No module named site *Félix Salazar**felix.sala...@polymtl.ca felix.sala...@polymtl.ca* Étudiant au doctorat - PhD Student *École Polytechnique de Montréal* * LADYF* Lab. de dynamique des fluides (514) 340 4711 ext 2489 Local: C-318.21.3 On Wed, Jun 17, 2015 at 10:19 AM, Burlen Loring burlen.lor...@gmail.com wrote: You also have to prepend the paths with the .so's to LD_LIBRARY_PATH before starting python. Burlen On 06/16/2015 07:19 PM, Felix Salazar wrote: Hello community, I normally run my Paraview scripts in pvpython, so far without issues. But I got some problems using specific Python functions (multiprocess), and decided to switch to import paraview libraries directly within Python I set my PYTHONPATH variable to the installation library where the files are located. Got a few errors, and added more directories, progressively clearing and decreasing the number of errors, until a point where I'm getting this message *Error: Could not import vtkCommonComputationalGeometryPython* Traceback (most recent call last): File /home/pissarro/fesal/Tools/zReattachment-NP.py, line 4, in module except: from paraview.simple import * File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/simple.py, line 41, in module import servermanager File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/servermanager.py, line 48, in module import paraview, re, os, os.path, new, sys, atexit, vtk File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk/__init__.py, line 7, in module from vtkCommonCorePython import * *ImportError: libvtkCommonCorePython27D-pv4.0.so.1: cannot open shared object file: No such file or directory* At this point my PYTHONPATH variable is: PYTHONPATH=*/apps/local-linux/paraview4.01/lib/paraview-4.0* :/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk:/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages:/apps/local-linux/paraview4.01/bin And the file libvtkCommonCorePython27D-pv4.0.so.1 is in */apps/local-linux/paraview4.01/lib/paraview-4.0/* Hence, that location is part of the path variable, but for some reason is not recognized. Is there any specific or recommended order to load these directories in the PYTHONPATH variable? Also, if I type help('modules') in a python console, I get this error message before the list of modules Please wait a moment while I gather a list of all available modules... Error: Could not import vtkCommonComputationalGeometryPython Thanks, * Félix Salazar **felix.sala...@polymtl.ca felix.sala...@polymtl.ca* Étudiant au doctorat - PhD Student *École Polytechnique de Montréal* ___ 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 ___ 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
Re: [Paraview] PYTHONPATH environmental variable
are you by chance mixing two python installs? like one from a paraview binary you didn't build yourself, and your system python? On 06/17/2015 10:47 AM, Felix Salazar wrote: Tried it, but for some reason, it breaks python $ python Could not find platform independent libraries prefix Could not find platform dependent libraries exec_prefix Consider setting $PYTHONHOME to prefix[:exec_prefix] ImportError: No module named site * Félix Salazar */felix.sala...@polymtl.ca mailto:felix.sala...@polymtl.ca/* *Étudiant au doctorat - PhD Student /École Polytechnique de Montréal/ /LADYF/ //Lab. de dynamique des fluides (514) 340 4711 ext 2489 Local: C-318.21.3* * On Wed, Jun 17, 2015 at 10:19 AM, Burlen Loring burlen.lor...@gmail.com mailto:burlen.lor...@gmail.com wrote: You also have to prepend the paths with the .so's to LD_LIBRARY_PATH before starting python. Burlen On 06/16/2015 07:19 PM, Felix Salazar wrote: Hello community, I normally run my Paraview scripts in pvpython, so far without issues. But I got some problems using specific Python functions (multiprocess), and decided to switch to import paraview libraries directly within Python I set my PYTHONPATH variable to the installation library where the files are located. Got a few errors, and added more directories, progressively clearing and decreasing the number of errors, until a point where I'm getting this message *Error: Could not import vtkCommonComputationalGeometryPython* Traceback (most recent call last): File /home/pissarro/fesal/Tools/zReattachment-NP.py, line 4, in module except: from paraview.simple import * File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/simple.py, line 41, in module import servermanager File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/servermanager.py, line 48, in module import paraview, re, os, os.path, new, sys, atexit, vtk File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk/__init__.py, line 7, in module from vtkCommonCorePython import * *ImportError: libvtkCommonCorePython27D-pv4.0.so.1: cannot open shared object file: No such file or directory* At this point my PYTHONPATH variable is: PYTHONPATH=*/apps/local-linux/paraview4.01/lib/paraview-4.0*:/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk:/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages:/apps/local-linux/paraview4.01/bin And the file libvtkCommonCorePython27D-pv4.0.so.1 is in */apps/local-linux/paraview4.01/lib/paraview-4.0/* Hence, that location is part of the path variable, but for some reason is not recognized. Is there any specific or recommended order to load these directories in the PYTHONPATH variable? Also, if I type help('modules') in a python console, I get this error message before the list of modules Please wait a moment while I gather a list of all available modules... Error: Could not import vtkCommonComputationalGeometryPython Thanks, * Félix Salazar */felix.sala...@polymtl.ca mailto:felix.sala...@polymtl.ca/* *Étudiant au doctorat - PhD Student /École Polytechnique de Montréal/ ___ Powered bywww.kitware.com http://www.kitware.com Visit other Kitware open-source projects athttp://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 ___ 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 ___ 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
Re: [Paraview] PYTHONPATH environmental variable
You also have to prepend the paths with the .so's to LD_LIBRARY_PATH before starting python. Burlen On 06/16/2015 07:19 PM, Felix Salazar wrote: Hello community, I normally run my Paraview scripts in pvpython, so far without issues. But I got some problems using specific Python functions (multiprocess), and decided to switch to import paraview libraries directly within Python I set my PYTHONPATH variable to the installation library where the files are located. Got a few errors, and added more directories, progressively clearing and decreasing the number of errors, until a point where I'm getting this message *Error: Could not import vtkCommonComputationalGeometryPython* Traceback (most recent call last): File /home/pissarro/fesal/Tools/zReattachment-NP.py, line 4, in module except: from paraview.simple import * File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/simple.py, line 41, in module import servermanager File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/servermanager.py, line 48, in module import paraview, re, os, os.path, new, sys, atexit, vtk File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk/__init__.py, line 7, in module from vtkCommonCorePython import * *ImportError: libvtkCommonCorePython27D-pv4.0.so.1: cannot open shared object file: No such file or directory* At this point my PYTHONPATH variable is: PYTHONPATH=*/apps/local-linux/paraview4.01/lib/paraview-4.0*:/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk:/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages:/apps/local-linux/paraview4.01/bin And the file libvtkCommonCorePython27D-pv4.0.so.1 is in */apps/local-linux/paraview4.01/lib/paraview-4.0/* Hence, that location is part of the path variable, but for some reason is not recognized. Is there any specific or recommended order to load these directories in the PYTHONPATH variable? Also, if I type help('modules') in a python console, I get this error message before the list of modules Please wait a moment while I gather a list of all available modules... Error: Could not import vtkCommonComputationalGeometryPython Thanks, * Félix Salazar */felix.sala...@polymtl.ca mailto:felix.sala...@polymtl.ca/* *Étudiant au doctorat - PhD Student /École Polytechnique de Montréal/ ___ 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 ___ 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
[Paraview] PYTHONPATH environmental variable
Hello community, I normally run my Paraview scripts in pvpython, so far without issues. But I got some problems using specific Python functions (multiprocess), and decided to switch to import paraview libraries directly within Python I set my PYTHONPATH variable to the installation library where the files are located. Got a few errors, and added more directories, progressively clearing and decreasing the number of errors, until a point where I'm getting this message *Error: Could not import vtkCommonComputationalGeometryPython* Traceback (most recent call last): File /home/pissarro/fesal/Tools/zReattachment-NP.py, line 4, in module except: from paraview.simple import * File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/simple.py, line 41, in module import servermanager File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/servermanager.py, line 48, in module import paraview, re, os, os.path, new, sys, atexit, vtk File /apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk/__init__.py, line 7, in module from vtkCommonCorePython import * *ImportError: libvtkCommonCorePython27D-pv4.0.so.1: cannot open shared object file: No such file or directory* At this point my PYTHONPATH variable is: PYTHONPATH=*/apps/local-linux/paraview4.01/lib/paraview-4.0* :/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages/paraview/vtk:/apps/local-linux/paraview4.01/lib/paraview-4.0/site-packages:/apps/local-linux/paraview4.01/bin And the file libvtkCommonCorePython27D-pv4.0.so.1 is in */apps/local-linux/paraview4.01/lib/paraview-4.0/* Hence, that location is part of the path variable, but for some reason is not recognized. Is there any specific or recommended order to load these directories in the PYTHONPATH variable? Also, if I type help('modules') in a python console, I get this error message before the list of modules Please wait a moment while I gather a list of all available modules... Error: Could not import vtkCommonComputationalGeometryPython Thanks, *Félix Salazar**felix.sala...@polymtl.ca felix.sala...@polymtl.ca* Étudiant au doctorat - PhD Student *École Polytechnique de Montréal* ___ 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