Skip to content

Commit

Permalink
Synopsis
Browse files Browse the repository at this point in the history
  • Loading branch information
davidavdav committed Mar 10, 2014
1 parent 4b909cc commit 5663d8b
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,33 @@ SGEArray.jl
===========

SGEArray implements a simple iterator in Julia to efficiently handle Sun Grid Engine task arrays

Synopsis
--------

Julia main:

```julia
using SGEArrays

listfile = ARGS[1]
files = readdlm(listfile)

for i in SGEArray(1:size(files))
file = files[i]
## process file numbered i
end
```

bash call, submit an SGE array job as an array of size 80

```bash
find data/input/ -type f > filelist
qsub -t1:80 -b y -cwd bin/julia-script filelist
```

The first job in the array processes files[1], files[81], etc, the second job processes files[2], files[82], etc.

If the julia script is called outside the context of an SGE array, the iterator simply iterates over all elements.


0 comments on commit 5663d8b

Please sign in to comment.