CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   pyFoamPlotWatcher is not working (https://www.cfd-online.com/Forums/openfoam-solving/68079-pyfoamplotwatcher-not-working.html)

arvind_arya September 5, 2009 09:40

pyFoamPlotWatcher is not working
 
I want to watch residuals.....so i have installed PyFoam- 0.5.2.... but...... while executing pyFoamPlotWatcher ......it says

File "/usr/local/bin/pyFoamPlotWatcher.py", line 3, in <module>
from PyFoam.Applications.PlotWatcher import PlotWatcher
File "/usr/local/lib/python2.6/dist-packages/PyFoam/Applications/PlotWatcher.py", line 6, in <module>
from PyFoam.Execution.GnuplotRunner import GnuplotWatcher
File "/usr/local/lib/python2.6/dist-packages/PyFoam/Execution/GnuplotRunner.py", line 86
with="steps",
^
SyntaxError: invalid syntax

I am using UBUNTU-9.0.4 AND OF-1.6.
I know for this forum this is not a major problem......please spare some time to give ur suggestions
Thanks in Advance

gschaider September 7, 2009 13:35

Quote:

Originally Posted by arvind_arya (Post 228630)
I want to watch residuals.....so i have installed PyFoam- 0.5.2.... but...... while executing pyFoamPlotWatcher ......it says

File "/usr/local/bin/pyFoamPlotWatcher.py", line 3, in <module>
from PyFoam.Applications.PlotWatcher import PlotWatcher
File "/usr/local/lib/python2.6/dist-packages/PyFoam/Applications/PlotWatcher.py", line 6, in <module>
from PyFoam.Execution.GnuplotRunner import GnuplotWatcher
File "/usr/local/lib/python2.6/dist-packages/PyFoam/Execution/GnuplotRunner.py", line 86
with="steps",
^
SyntaxError: invalid syntax

I am using UBUNTU-9.0.4 AND OF-1.6.
I know for this forum this is not a major problem......please spare some time to give ur suggestions
Thanks in Advance

There has been a reply to this in http://www.cfd-online.com/Forums/ope...83-pyfoam.html

Please do not cross-post

Ramnik May 31, 2010 20:14

same error!!
 
Hey i am facing the same problem....did u find a solution to it??

gschaider June 1, 2010 07:46

Quote:

Originally Posted by Ramnik (Post 261075)
Hey i am facing the same problem....did u find a solution to it??

Have you read the answer to his posting? Obviously he cross-posted and got the answer elsewhere

JanL December 13, 2010 06:09

Hi,

I would like to print the plots of pyFoamPlotWatcher.py and tried the following commands.

Quote:

pyFoamPlotWatcher.py log --with-courant --hardcopy
pyFoamPlotWatcher.py log --with-courant --format-of-hardcopy=pdf
pyFoamPlotWatcher.py log --with-courant --write-files
pyFoamPlotWatcher is plotting the data (including courant number) in the X11 windows, but doesn't create any hardcopies (at least I can't find them)! Does anyone know what I'm doing wrong, or if there is another way to create pdf's (without creating screenshots)?
I'm using OF-1.7.1 on Mac OSX 10.6.5 and have the pyFoam(PlotWatcher) version 0.5.4.

gschaider December 13, 2010 14:43

Quote:

Originally Posted by JanL (Post 287203)
Hi,

I would like to print the plots of pyFoamPlotWatcher.py and tried the following commands.

pyFoamPlotWatcher is plotting the data (including courant number) in the X11 windows, but doesn't create any hardcopies (at least I can't find them)! Does anyone know what I'm doing wrong, or if there is another way to create pdf's (without creating screenshots)?
I'm using OF-1.7.1 on Mac OSX 10.6.5 and have the pyFoam(PlotWatcher) version 0.5.4.

The first variant (of course with a logfile, guess you omitted that) should write some PNGs into the current working-directory AFTER you finished the watch wit Ctrl-C. The second variant writes nothing (but if there was a --hardcopy it would force gnuplot to write PDFs). The third variant writes the plotted data as timelines to some textfiles (see the *.analyzed-directory)

It is not a Mac-problem per se (I develop that stuff most of the time on such a thing). Is there any additional output after stopping the watcher?

Bernhard

McCharles August 16, 2016 09:32

If you want the residualplot in pdf Format to be saved in the work directory, just use :
pyFoamPlotWatcher.py log --hardcopy --format-of-hardcopy=pdf


All times are GMT -4. The time now is 16:52.