[Yt-svn] yt-commit r526 - trunk/examples
mturk at wrangler.dreamhost.com
mturk at wrangler.dreamhost.com
Wed Jun 4 08:45:46 PDT 2008
Author: mturk
Date: Wed Jun 4 08:45:45 2008
New Revision: 526
URL: http://yt.spacepope.org/changeset/526
Log:
Deleted the old examples that did not work.
Added new, working directory-watcher examples.
Added:
trunk/examples/automated_plotconfig.xml
trunk/examples/fido_dirwatch.py
Removed:
trunk/examples/examples.py
trunk/examples/iterate_over_outputs.py
trunk/examples/mpl_make_movie.py
trunk/examples/raven_plots_config.py
trunk/examples/sample_raven_config.xml
Added: trunk/examples/automated_plotconfig.xml
==============================================================================
--- (empty file)
+++ trunk/examples/automated_plotconfig.xml Wed Jun 4 08:45:45 2008
@@ -0,0 +1,51 @@
+<!-- This is a SAMPLE file! Change it as you see fit -->
+<raven>
+ <proj mindx="100">
+ <field>Density</field>
+ <width unit="kpc">10</width>
+ <width unit="kpc">1</width>
+ <width unit="pc">100</width>
+ <width unit="pc">10</width>
+ <width unit="pc">1</width>
+ </proj>
+ <slice mindx="1">
+ <field>Temperature</field>
+ <field>NumberDensity</field>
+ <field>H2I_Fraction</field>
+ <width unit="kpc">10</width>
+ <width unit="kpc">1</width>
+ <width unit="pc">100</width>
+ <width unit="pc">10</width>
+ <width unit="pc">1</width>
+ </slice>
+ <phase mindx="1">
+ <field>NumberDensity</field>
+ <field>Temperature</field>
+ <field>CellMassMsun</field>
+ <width unit="kpc">10</width>
+ <width unit="kpc">1</width>
+ <width unit="pc">100</width>
+ <width unit="pc">10</width>
+ <width unit="pc">1</width>
+ </phase>
+ <phase mindx="1">
+ <field>NumberDensity</field>
+ <field>Temperature</field>
+ <field>CellMassMsun</field>
+ <width unit="kpc">10</width>
+ <width unit="kpc">1</width>
+ <width unit="pc">100</width>
+ <width unit="pc">10</width>
+ <width unit="pc">1</width>
+ </phase>
+ <phase mindx="1">
+ <field>NumberDensity</field>
+ <field>Temperature</field>
+ <field>H2I_Fraction</field>
+ <width unit="kpc">10</width>
+ <width unit="kpc">1</width>
+ <width unit="pc">100</width>
+ <width unit="pc">10</width>
+ <width unit="pc">1</width>
+ </phase>
+</raven>
Added: trunk/examples/fido_dirwatch.py
==============================================================================
--- (empty file)
+++ trunk/examples/fido_dirwatch.py Wed Jun 4 08:45:45 2008
@@ -0,0 +1,22 @@
+import yt.fido as fido
+import os, os.path
+
+image_skel = "ravenimages/%s/"
+image_prefix = "%(bn)s_%(width)05i_%(unit)s"
+
+def fido_plot_wrap():
+ import yt.raven as raven
+ import yt.lagos as lagos
+ def fido_plots(fn):
+ pf = lagos.EnzoStaticOutput(fn)
+ md = pf["MetaDataString"]
+ image_dir = image_skel % (md)
+ if not os.path.isdir(image_dir):
+ os.makedirs(image_dir)
+ prefix = os.path.join(image_dir, image_prefix)
+ raven.MakePlots(pf, "automated_plotconfig.xml", prefix, -1)
+ return
+ return fido_plots
+
+Giles = fido.Watcher(function_handler=fido_plot_wrap)
+Giles.run()
More information about the yt-svn
mailing list