[Swift-commit] r7807 - in demo/xsede.2014.0425: . part06m

wilde at ci.uchicago.edu wilde at ci.uchicago.edu
Sun Apr 27 16:22:48 CDT 2014


Author: wilde
Date: 2014-04-27 16:22:48 -0500 (Sun, 27 Apr 2014)
New Revision: 7807

Added:
   demo/xsede.2014.0425/part06m/
   demo/xsede.2014.0425/part06m/p4.swift
   demo/xsede.2014.0425/part06m/swift.properties
Log:
cloning part6 for demo with viz.

Added: demo/xsede.2014.0425/part06m/p4.swift
===================================================================
--- demo/xsede.2014.0425/part06m/p4.swift	                        (rev 0)
+++ demo/xsede.2014.0425/part06m/p4.swift	2014-04-27 21:22:48 UTC (rev 7807)
@@ -0,0 +1,43 @@
+type file;
+
+(int result) randomInt ()
+{
+  float range = 9999999.0;
+  float rand = java("java.lang.Math","random");
+  string s[] = strsplit(toString(range*rand),"\\.");
+  result = toInt(s[0]);
+}
+
+app (file out, file traj) simulation (string npart, string steps, string mass)
+{
+# mdviz  @out @traj 3 npart steps 50 ".0001" mass "0.1 1.0 0.2 0.05 50.0 0.1" 2.5 2.0 randomInt();
+  md     3 npart steps 10 ".0001" mass "0.1 1.0 0.2 0.05 50.0 0.1" 2.5 2.0 randomInt() @out @traj;
+}
+
+app (file o) analyze (file s[])
+{
+  mdstats filenames(s) stdout=filename(o);
+}
+
+app (file o) convert (file s[])
+{
+  convert filenames(s) filename(o);
+}
+
+int    nsim   = toInt(arg("nsim","10"));
+string npart  = arg("npart","50");
+string steps  = arg("steps","1000");
+string mass   = arg("mass",".005");
+
+file sim[] <simple_mapper; prefix="output/sim_", suffix=".out">;
+file trj[] <simple_mapper; prefix="output/sim_", suffix=".trj.tgz">;
+
+foreach i in [0:nsim-1] {
+  (sim[i],trj[i]) = simulation(npart,steps,mass);
+}
+
+file stats_out<"output/average.out">;
+stats_out = analyze(sim);
+
+#file viz_all<"output/all.gif">;
+#viz_all = convert(gifs);

Added: demo/xsede.2014.0425/part06m/swift.properties
===================================================================
--- demo/xsede.2014.0425/part06m/swift.properties	                        (rev 0)
+++ demo/xsede.2014.0425/part06m/swift.properties	2014-04-27 21:22:48 UTC (rev 7807)
@@ -0,0 +1,2 @@
+site=midway-westmere
+site.midway-westmere.slurm.exclusive=false




More information about the Swift-commit mailing list