Add GUI components to run-pipeline

* scripts/run-pipeline.py: Only output DocoptExit when we are in CLI.
(CLI_OPTS): Add a "-g" option.
(genInputTimestream): We put the initialization of input timestream in a new
method to avoid repeating code.
(PipelineRunner.runPipeline): We put the running of the pipeline in a separate
method to avoid repeating code. We enclose it in a class in order to be able to
stop it from the outside.
(maincli): New method that contains all the CLI execution.
(maingui): Likewise but for GUI.
(PipelineRunnerGUI): Class that contains the GUI execution.
(PipelineRunnerGUI.TextEditStream): New stream to pass to the GUI log. It allows
all the log messages to be output to the TextEdit.
(PipelineRunnerGUI.{TextEditSignal,ProgressSignal,ThreadStopped}): New QT
Signals to admin the execution. The first passes the log messages. The second
manages the progress bar and the third cleans up the progressbar. All are inner
classes.
(PipelineRunnerGUI.PipelineThread): New thread class that will actually execute
the pipeline. Its on a separate thread to add to GUI responsiveness.