|
[Sponsors] |
October 22, 2009, 06:52 |
|
#41 |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
||
November 30, 2009, 05:09 |
|
#42 | |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Hi all
I had the same problem with the blank gnuplot's: Quote:
http://software.opensuse.org/search (just search for numpy and scipy and install both). The plots then worked fine. Regards Bernard |
||
November 30, 2009, 05:14 |
|
#43 | |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Just another question - is there any way to zoom into certain areas of the plot?
If I right-click on the plot, I get a square that I can drag. I though this would produce a zoom of the area in the square, however I just get the following in the console: Quote:
|
||
November 30, 2009, 08:42 |
|
#44 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
|
||
November 30, 2009, 08:47 |
|
#45 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
|
||
December 1, 2009, 11:12 |
|
#46 | |
Senior Member
Rasmus Hemph
Join Date: Mar 2009
Location: Sweden
Posts: 108
Rep Power: 17 |
Quote:
//Rasmus |
||
December 1, 2009, 12:07 |
|
#47 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
Bernhard |
||
January 3, 2011, 04:32 |
sorting of parsed dictionary
|
#48 |
Senior Member
Fabian Braennstroem
Join Date: Mar 2009
Posts: 407
Rep Power: 19 |
Hello Bernhard,
I have trouble understanding the sorting of your parser using the below expression: f=ParsedParameterFile(fileDict) Keys=f["addLayersControls"]["nameConventions"].keys() for the fileDict: addLayersControls { nameConventions // alphabetic order { GRO { nSurfaceLayers 4; } ROT { nSurfaceLayers 6; } WW { nSurfaceLayers 12; } } } I would like to have the same order as it is listed in the dict; unfortunately I get this order: ['WW', 'GRO', 'ROT']. Do you have a hint or idea, how to get this!? Would be great! Regards! Fabian |
|
January 3, 2011, 06:47 |
|
#49 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
def keys(self): return self._order (self._order is used to output stuff int the order of the definition) but this fix will NOT change the order if you iterate over the dictionary itself (without .keys()) Bernhard |
||
January 3, 2011, 07:34 |
|
#50 | |||
Senior Member
Fabian Braennstroem
Join Date: Mar 2009
Posts: 407
Rep Power: 19 |
Hi Bernhard,
thanks for the quick response! Quote:
Quote:
Quote:
Fabian |
||||
January 4, 2011, 13:31 |
|
#51 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
Bernhard |
||
September 30, 2011, 09:01 |
|
#52 |
Member
Tibor Nyers
Join Date: Jul 2010
Location: Hungary
Posts: 91
Rep Power: 17 |
Hi,
I would like to create a simple script that renders out a paraview state file at some time. I tried to reverse engineer your paraview related pyFoam utiliities and couldn't quite understand how the desired time is set. My terminal command is: Code:
paraview --script=./postproc/paraview/paraPlot.py Code:
from paraview.simple import * # load the state servermanager.LoadState("./postproc/paraview/pw_pressure.pvsm") # make sure that the view in the state is the active one SetActiveView(GetRenderView()) GetActiveView() # no success, no output SetViewTime(800) # now render and save Render() WriteImage("./postproc/paraview/pw_pic.png") My other try: Code:
from paraview.simple import * # load the state servermanager.LoadState("./postproc/paraview/pw_pressure.pvsm") # make sure that the view in the state is the active one so we don't have to refer to it by name SetActiveView(GetRenderView()) view=GetActiveView() view.ViewTime=0 # now render and save view.Render() view.WriteImage("./postproc/paraview/pw_pic.png") In both cases the legends aren't scaled to data range. Is there a solution or one should modify the state file instead? What's the command for quiting paraview at the end of the script? Can someone advise some tutorials on python scripting paraview - stream tracer creation, slicing and contour plots, etc? This state file loading is not really impressive, contains a lot of boiler plate stuff, hard to edit and customize. It would be much better the other way around. Thank you! |
|
September 30, 2011, 09:28 |
|
#53 |
Senior Member
|
Hi,
I think you are better served with Python Scripting http://paraview.org/Wiki/ParaView/Python_Scripting or http://paraview.org/Wiki/Take_a_Scre..._of_a_VTP_File http://www.openfoamworkshop.org/6th_...rle_slides.pdf =>see slide Batch/reproducible workflow "topic macro" |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[ICEM] Problems with coedge curves and surfaces | tommymoose | ANSYS Meshing & Geometry | 6 | December 1, 2020 12:12 |
[mesh manipulation] Problems with rotational cyclic boundaries | TReviol | OpenFOAM Meshing & Mesh Conversion | 8 | July 11, 2014 04:45 |
Needed Benchmark Problems for FSI | Mechstud | Main CFD Forum | 4 | July 26, 2011 13:13 |
Two-phase air water flow problems by activating Wall Lubrication Force | challenger85 | CFX | 5 | November 5, 2009 06:44 |
Help required to solve Hydraulic related problems | aero | CFX | 0 | October 30, 2006 12:00 |