Question: I have a script (that simulates a neuronal network in PyNEST) and I want to run several instances of it, changing only a few parameters each time. The simulation time is not a problem (about 5 secs length), but I want to run quite a few simulations.

What I do now, is use 'sys' and 'sys.argv[:]' to pass my parameters and I copy paste batches of those in 4 different terminals (Terminator).

```
python myScript.py arg1 arg2 arg3
python myScript.py arg4 arg5 arg6
...

```

What I want to know, is whether this way is efficient or if I am wasting a lot of CPU power for something that can be done in a much simpler manner.

Answer: 
Convert your script into a module with a main function, so that running

```
python myScript.py arg1 arg2 arg3

```

from the command line is equivalent to running

```
import myScript
myScript.main(arg1, arg2, arg3)

```

Once you've made `myScript` an importable module, then you can write another script
to call `myScript.main` with the desired arguments easily.
If the work performed is significant enough to justify the overhead necessary for setting up several processes, you can create a pool of worker processes with the [multiprocessing module](https://docs.python.org/2/library/multiprocessing.html).