improve project structure
[epclust.git] / code / stage1 / src / main.sh
diff --git a/code/stage1/src/main.sh b/code/stage1/src/main.sh
new file mode 100644 (file)
index 0000000..26cd32f
--- /dev/null
@@ -0,0 +1,30 @@
+#!/bin/bash
+#PBS -l walltime=00:05:00
+#PBS -l nodes=2:ppn=8,pmem=1gb
+#PBS -oe .output
+
+WORKDIR="/workdir2/auder/edfclust/code"
+cd $WORKDIR
+
+rm -f .output
+
+saveLibPath=$LD_LIBRARY_PATH
+
+#TODO: CDS as a module
+LD_LIBRARY_PATH=/workdir2/cds/lib:/opt/openmpi/lib:$LD_LIBRARY_PATH
+export LD_LIBRARY_PATH
+
+#TODO: externalize (de)serialization, do not make assumptions on "how is data stored" (...)
+
+# ppam args (in case of clustering) = 
+#   1: path to binary dataset
+#   2: series per processor
+#   3: number of clusters
+#   4: boolean to randomize series sampling
+#   5: type of distance (1 for L1, 2 for L2...)
+
+#TODO: Hybrid MPI+OpenMP
+mpirun -np 16 ppam cluster ../data/2009_first10000.bin 300 7 0 1
+
+LD_LIBRARY_PATH=$saveLibPath
+export LD_LIBRARY_PATH