Git Product home page Git Product logo

voila's Introduction

voila

Documentation Binder Join the Gitter Chat

Rendering of live Jupyter notebooks with interactive widgets.

Run Fork on MyBinder

https://mybinder.org/v2/gh/ismms-himc/voila/stable?urlpath=voila%2Ftree%2Fnotebooks

Introduction

Voila serves live Jupyter notebook including Jupyter interactive widgets.

Unlike the usual HTML-converted notebooks, each user connecting to the Voila tornado application gets a dedicated Jupyter kernel which can execute the callbacks to changes in Jupyter interactive widgets.

  • By default, voila disallows execute requests from the front-end, preventing execution of arbitrary code.
  • By defaults, voila runs with the strip_source option, which strips out the input cells from the rendered notebook.

Installation

Voila can be installed with the conda package manager

conda install -c conda-forge voila

or from pypi

pip install voila

JupyterLab preview extension

Voila provides a JupyterLab extension that displays a Voila preview of your Notebook in a side-pane:

jupyter labextension install @jupyter-voila/jupyterlab-preview

Usage

As a standalone tornado application

To render the bqplot example notebook as a standalone app, run voila bqplot.ipynb. To serve a directory of jupyter notebooks, run voila with no argument.

For example, to render the example notebook bqplot.ipynb from this repository with voila, you can first update your current environment with the requirements of this notebook (in this case in a conda environment and render the notebook with

conda env update -f environment.yml
cd notebooks/
voila bqplot.ipynb

For more command line options (e.g., to specify an alternate port number), run voila --help.

As a server extension to notebook or jupyter_server

Voila can also be used as a notebook server extension, both with the notebook server or with jupyter_server.

To install the notebook server extension, run

jupyter serverextension enable voila --sys-prefix

When running the notebook server, the voila app is accessible from the base url suffixed with voila.

Examples

The following two examples show how a standalone Jupyter notebook can be turned into a separate app, from the command-line integration.

Rendering a notebook including interactive widgets and rich mime-type rendering voila basics

Rendering a notebook making use of a custom widget library (bqplot)

voila bqplot

Showing the source code for a voila notebook

The sources of the Jupyter notebook can be displayed in a voila app if option strip_sources is set to False.

voila sources

Voila dashboards with other language kernels

Voila is built upon Jupyter standard formats and protocols, and is agnostic to the programming language of the notebook. In this example, we present an example of a voila application powered by the C++ Jupyter kernel xeus-cling, and the xleaflet project.

voila cling

Development

See CONTRIBUTING.md to know how to contribute and setup a development environment.

Related projects

Voila depends on nbconvert and jupyter_server.

License

We use a shared copyright model that enables all contributors to maintain the copyright on their contributions.

This software is licensed under the BSD-3-Clause license. See the LICENSE file for details.

voila's People

Contributors

sylvaincorlay avatar maartenbreddels avatar jtpio avatar mkcor avatar timkpaine avatar martinrenou avatar choldgraf avatar ivanov avatar azjps avatar mariobuikhuizen avatar msuperina avatar alexisduque avatar danielaristidou avatar davidbrochart avatar jeffyjefflabs avatar leogout avatar lheagy avatar cornhundred avatar pllim avatar pbugnion avatar vidartf avatar cclauss avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.