Last active
July 19, 2018 10:51
-
-
Save thelahunginjeet/9957401 to your computer and use it in GitHub Desktop.
example LSF array job showing how to use node-specific inputs and outputs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| #BSUB -L /bin/bash | |
| #BSUB -J paj[1-4] | |
| #BSUB -e paj.%I.err | |
| #BSUB -o paj.%I.out | |
| #BSUB -n 1 | |
| source ~/venv/bin/activate | |
| python parse_command_line.py --config=conf_${LSB_JOBINDEX}.cfg --output=results_${LSB_JOBINDEX}.out | |
| # comments: | |
| # -since this is a shell script, it must be made executable (chmod u+x) | |
| # -you have to submit with bsub < ./python_array_job.sh | |
| # -for an array job, -n specifies the number of processes PER SUBJOB (not the total) | |
| # -this script will run 4 copies, with different input and output files | |
| # -you have to use %I in the commands to bsub, and then the shell variable LSB_JOBINDEX | |
| # for the config/output files |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment