Skip to content

Instantly share code, notes, and snippets.

@jstrube
Created September 10, 2016 00:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jstrube/b663a057b621ec68284471a486306985 to your computer and use it in GitHub Desktop.
Save jstrube/b663a057b621ec68284471a486306985 to your computer and use it in GitHub Desktop.
bsub script to process 5 files at a time on kekcc queues
#!/bin/bash
#BSUB -J singleParticles[1-130]
#BSUB -q s
### LCG Libraries
contents=($(ls /gpfs/group/ilc/suehara/reco/dbd/train-lcfiplus/bb91new/*.slcio))
filename="${contents[5*(${LSB_JOBINDEX} - 1)]} ${contents[5*(${LSB_JOBINDEX} - 1)+1]} ${contents[5*(${LSB_JOBINDEX} - 1)+2]} ${contents[5*(${LSB_JOBINDEX} - 1)+3]} ${contents[5*(${LSB_JOBINDEX} - 1)+4]} "
xmlfile=$(basename ${contents[${LSB_JOBINDEX} - 1]})
echo $xmlfile
echo ${LSB_JOBINDEX}
echo $filename
sed "s/ntuple.root/$(basename ${xmlfile/slcio/root})/" makentuple.xml > xml/${xmlfile/slcio/xml}
MARLIN_DLL=../LCFIPlus/lib/libLCFIPlus.so:${MARLIN_DLL} Marlin xml/${xmlfile/slcio/xml} --global.LCIOInputFiles=${filename}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment