Python in the Browser tutorial (PyOdide)

Loading

PyOdide, From Mozilla, is cPython compiled to WebAssembly and running in the browser. It includes over 37 of the best Data Science libraries.



We start by reviewing the different ways to run Python in the browser.

Then we focus on PyOdide.  PyOdide, from Mozilla,  is cPython compiled to WebAssembly and running in the browser.  It includes over 37 of the best Data Science libraries.  So it is perfect for Data Scientists who want to convert their Jupyter Notebook to a web application.   The killer app is a hospital applications where it is illegal to upload the person’s data to the server. Or anyplace where you need fast GUI response, or have overloaded compute servers.  Here is a simple PyOdide application.  It is a Python editor in the browser, where the syntax checking is done with the PyOdide compile method.

But this tutorial starts at the beginning.  I teach you how to use Python in the browser, how to operate on the DOM,  and how to communicate between Python and Javascript.

  Here are the Pyodide Training Materials.

No need to install anything.  We use the official Iodide/PyOdide server.

For those who already know some Python.  Javascript is helpful, but not required.  Some HTML is very helpful.

2 - 3  hours is a good length of time for the tutorial.