aboutsummaryrefslogtreecommitdiff
path: root/scripts/turbo-index-lsf
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2017-03-08 15:26:39 +0100
committerThomas White <taw@physics.org>2017-03-08 15:28:19 +0100
commitcebdf5179e35e8dc3c707cb849b1d9b540cac316 (patch)
treeb96346f4a7dccd67000e46fbd2ff74011729d38b /scripts/turbo-index-lsf
parent9463264b534ab9e99a3858d88cba983b91ed8836 (diff)
Add SLURM version of turbo-index script
Diffstat (limited to 'scripts/turbo-index-lsf')
-rw-r--r--scripts/turbo-index-lsf26
1 files changed, 26 insertions, 0 deletions
diff --git a/scripts/turbo-index-lsf b/scripts/turbo-index-lsf
new file mode 100644
index 00000000..00e4ec15
--- /dev/null
+++ b/scripts/turbo-index-lsf
@@ -0,0 +1,26 @@
+#!/bin/sh
+
+RUN=$1
+NOSAMPLE=`echo $RUN | sed -e 's/\-.*$//'`
+
+GEOM=my.geom # Name of your geometry file
+
+find /path/to/CXI/files/$RUN -name '*.cxi' > files-${RUN}.lst # Set location of files
+list_events -i files-${RUN}.lst -g $GEOM -o events-${RUN}.lst
+wc -l events-${RUN}.lst
+rm -f split-events-${RUN}.lst files-${RUN}.lst
+split -d -l 500 events-${RUN}.lst split-events-${RUN}.lst
+rm -f events-${RUN}.lst
+
+for FILE in split-events-${RUN}.lst*; do
+
+ STREAM=`echo $FILE | sed -e "s/split-events-${RUN}.lst/${RUN}.stream/"`
+ NAME=`echo $FILE | sed -e "s/split-events-${RUN}.lst/${NOSAMPLE}-/"`
+ echo "$NAME: $FILE ---> $STREAM"
+
+ # Set indexing parameters here
+ bsub -q psanaq -o $NAME.log -J $NAME -n 12 -R "span[hosts=1]" \
+ indexamajig \
+ -i $FILE -o $STREAM -j 32 -g $GEOM --peaks=cxi
+
+done