separate between data handling and gui with thread

Signed-off-by: Nicholas Tan Jerome <nicholas.jerome@kit.edu>