diff bin/wavecurve @ 221:4a51d4eefa95

add wavecurve from semprini with new cmdline ui
author drewp@bigasterisk.com
date Sun, 17 Apr 2005 08:41:28 +0000
parents
children 8c9138ff91d5
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bin/wavecurve	Sun Apr 17 08:41:28 2005 +0000
@@ -0,0 +1,17 @@
+#!/usr/bin/env python
+import os, sys, optparse
+import run_local
+from light9.wavepoints import simp
+
+parser = optparse.OptionParser()
+parser.add_option("-t",type="float",default=.01,
+                  help="seconds per sample (default .01, .07 is smooth)")
+options,args = parser.parse_args()
+
+inpath,outpath = args
+
+points = simp(inpath, seconds_per_average=options.t)
+
+f = file(outpath, 'w')
+for time_val in points:
+    print >>f, "%s %s" % time_val