PYCON UK

Add GUIs to your data pipelines with Jupyter widgets

Pascal Bugnion | Saturday 11:30 | Ferrier Hall

Data science algorithms are often non-deterministic, in contrast to traditional software. The correctness of an algorithm is much more subjective. Being able to easily visualise intermediate stages in a data processing pipeline is therefore tremendously important.

In this talk, we demonstrate how to use Jupyter widgets to set GUIs up as part of the data science process.

Data scientists want to build lightweight, ad-hoc user interfaces that allow for human interaction at any step in the pipeline. Traditional software wisdom around building user interfaces is ill-suited for these new GUIs: the requirements are typically not well articulated up front, the interfaces need to be developed by data scientists rather than by frontend engineers, and they need to mesh well with other components in the data processing pipeline.

Jupyter widgets allow for the creation of lightweight, interactive, graphical interfaces directly in Jupyter notebooks. This provides the following advantages:

  • Graphical interfaces lead to a much shorter feedback loop for the data scientist, allowing them to rapidly experiment with their model;
  • Data scientists can use Python (rather than, say, JavaScript) to create user interfaces;
  • The GUI is part of the pipeline, rather than a window onto it - any output generated by the UI can be used for the next step of the pipeline.

Link to video