CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[General] pvphyton Error

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 19, 2018, 09:50
Post pvphyton Error
  #1
New Member
 
Batu
Join Date: Dec 2016
Location: Turkey
Posts: 5
Rep Power: 10
BM_CFD is on a distinguished road
Hello everyone,

I'm new to paraview scripting. I used the trace command and created a phyton script. I can use this script when I open paraview and use the Pyhton Shell there. However, when I want to use the command pvphyton MyScriptName.py I get the following error.

Code:
Traceback (most recent call last):
  File "Re800.py", line 25, in <module>
    ResultsOpenFOAM = PVFoamReader(FileName='/home/batuhan/Masa\xc3\xbcst\xc3\xbc/Thesis/LaminarCases/Gmsh/144mm_From9mm/Comparison/Re800_BlockMesh/Results.OpenFOAM')
NameError: name 'PVFoamReader' is not defined
Start of my script and where it gets this is error can be found here:

Code:
#### import the simple module from the paraview
from paraview.simple import *
#### disable automatic camera reset on 'Show'
paraview.simple._DisableFirstRenderCameraReset()

# set active view
SetActiveView(None)

CreateLayout('Layout #1')

# Create a new 'Render View'
renderView1 = CreateView('RenderView')
renderView1.ViewSize = [1502, 858]
renderView1.AxesGrid = 'GridAxes3DActor'
renderView1.StereoType = 0
renderView1.Background = [0.32, 0.34, 0.43]

# get layout
layout1 = GetLayout()

# place view in the layout
layout1.AssignView(0, renderView1)

# create a new 'PVFoamReader'
ResultsOpenFOAM = PVFoamReader(FileName='/home
So I believe that pvpyhton does not load PVFoamReader. How can I solve this issue?
BM_CFD is offline   Reply With Quote

Reply

Tags
paraview, pyhton


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[OpenFOAM.org] compile error in dynamicMesh and thermophysicalModels libraries NickG OpenFOAM Installation 3 December 30, 2019 01:21
[blockMesh] blockMesh with double grading. spwater OpenFOAM Meshing & Mesh Conversion 92 January 12, 2019 10:00
[swak4Foam] GroovyBC the dynamic cousin of funkySetFields that lives on the suburb of the mesh gschaider OpenFOAM Community Contributions 300 October 29, 2014 19:00
OpenFOAM without MPI kokizzu OpenFOAM Installation 4 May 26, 2014 10:17
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 18:51


All times are GMT -4. The time now is 20:01.