Thursday, June 19, 2014

Meeting #3 - Recap

Charles Stanhope led an informative and engaging discussion of the IPython Notebook to an enthusiastic audience at the third EAST Knowledge meeting. Charles has been using the Notebook to good effect at work, and demonstrated several notebooks to the audience. Charles has helped make his demonstration notebooks available. The notebooks are available on the EAST Knowledge github page. You can also see static versions of the executed pages using the nbviewer service. The introduction notebook contains links to additional resources that may be useful if you wish to install IPython Notebook yourself.

With IPython Notebooks, individuals and groups can:
  • Rapidly prototype and explore algorithmic ideas
  • Easily share results
  • Replicate work
  • Freely collaborate
  • Leverage a large body of existing libraries
Alternatives to the notebook such as Mathematica or LabView are expensive, so businesses often elect to purchase licenses for only a few people — the Research and Development team, for example. When it's time to share the results with those who do not have access to the tools, the team has to prepare a report — perhaps a (necessarily static) pdf. The report is a poor substitute for an interactive demo. With a notebook, you can delve into the code and experiment with the algorithms yourself.

The IPython Notebook interface runs in your browser, and you don't need to know any Python to view or modify the contents. Charles set up a server running the IPython kernel on one laptop, and audience members connected through a router using their browsers. The setup demonstrated that IPython genuinely works cross-platform, and that users need not install anything (except a browser) on their local machines.

Notebooks consist of "cells" of different types:
Markdown - for expository content
Code- for actual computing
Headings- for providing linkable sections
Raw- for just raw text or for disabling code cells

Code cells produce output that appears inline with the document. Charles demonstrated a notebook he developed to explore the Karplus-Strong algorithm that Jim Rulla presented to the group in our second meeting. The algorithm synthesizes random input into sounds that sound remarkably like plucked strings. You can adjust the pitch, see the graph of the waveform, and play the sound in the notebook (even the static notebook has a sound you can play). Imagine how much more you'd learn — and how much more fun you'd have — by playing with the algorithm than by simply reading this description!

Other examples Charles developed include a csv (comma-separated-value) file reader with data plots and a Mandelbrot Set generator.

  • The IPython and Python online help are helpful.
    • Type "help()" in a code cell to bring up Python's interactive help.
    • Click the "Help" menu item for much useful information.
  • Press Enter to edit a cell, and ESC or + Enter to enter "command mode". These and other keyboard shortcuts are available under the Help menu item.
  • Use the Cell menu item to Run the code.
  • Pat Nystrom discovered that, if the kernel is running locally, disabling the "inlining" of matplotlib brings up plot windows with zoom buttons and scroll bars — a useful discovery, indeed!
We'd like to thank the Multnomah County Library in Gresham for providing space and equipment for EAST Knowledge to meet.


  1. - EAST Knowledge github page for notebooks
  2. - Static examples of executed notebooks

Tuesday, June 3, 2014

Meeting #3 Announcement - Introduction to IPython Notebook

Update: a meeting recap.

EAST Knowledge is pleased to announce it's third meeting. Charles Stanhope will be giving a talk on IPython Notebook. All are welcome!

What:Introduction to IPython Notebook
Who:Charles Stanhope
Where:The Computer Lab at the Gresham Library (map)
When:10:30am-Noon, Saturday, June 14th, 2014
Why:Sharing what we know

Come and learn about IPython Notebook interactive computing environment! An open source project used and developed by a community of scientists and engineers, IPython Notebook is a powerful tool that can save time and effort, and allows you to:
  • Rapidly prototype and explore algorithmic ideas
  • Easily share results
  • Replicate work
  • Freely collaborate
  • Leverage a large body of existing libraries
Charles will introduce and demonstrate IPython Notebook. He hopes to have a live system that can be used by the audience. All you will need is WiFi, a web browser, and some curiosity. So bring a laptop!