# Grid

Running on the grid is as easy as having a grid certificate and using two command line arguments.

When running locally, we define an input dataset list file and an output directory; for the grid we'll define an input dataset name and an output dataset name (we still define a local output as well).

If your input dataset is:

```
group.det-indet.361107.PowhegPythia8EvtGen_AZNLOCTEQ6L1_Zmumu.simul.TRTxAOD.e3601_s2876_r7886_trt099-02_EXT0
```

Then we can process that sample on the grid using the `--gridDS` argument and `--outDS` argument. Your `--outDS` should always start with `user.<your user name>`

```
$ runAnaProjectLooperAlg -c default.cfg --gridDS group.det-indet.361107.PowhegPythia8EvtGen_AZNLOCTEQ6L1_Zmumu.simul.TRTxAOD.e3601_s2876_r7886_trt099-02_EXT0 --outDS user.<your user name>.xyz -o grid_run
```

You should make your output dataset name descriptive!

Of course, in order to be able to submit to the grid you need a grid certificate and you must setup `panda` and run `voms-proxy-init`:

```
$ lsetup panda
$ voms-proxy-init -voms atlas --valid 96:00
```
