Python Conference Report

Andrew M. Kuchling

Issue #73, May 2000

Some of the ongoing shifts in the Python community were apparent at the Eighth International Python Conference (IPC8), held in Washington, DC this past January.

Some of the ongoing shifts in the Python community were apparent at the Eighth International Python Conference (IPC8), held in Washington, DC this past January. [Note: the Spanish Inquisition was not in attendence.] For a start, the continued growth of the Python community was obvious. IPC7, the previous conference, attracted roughly a hundred attendees. IPC8 was more than twice as large, with around 250 attendees. Much of this growth came from the increasing popularity of the Zope application server, which had its own conference track for the first time. This track drew some 90 people who attended talks on Zope's architecture and features, designing applications for Zope, and saw demos of new products such as the Portal Toolkit.

Education

One interesting new theme emerged at this conference, the idea of using Python to teach programming.

Randy Pausch of Carnegie-Mellon University gave a keynote talk about the Alice virtual reality system (http://www.alice.org/), a stunning talk that held out some hope that maybe, just maybe, these computer things can be useful to people without requiring them to master Cartesian coordinates or to adjust their thinking to match the machine's. Alice is a 3D VR system used in a course at CMU, whose audience is non-technical users without a background in engineering or computer science. Accordingly, the system has been carefully tested for usability throughout its development. Python had to be modified slightly to improve its suitability for novices, but only two serious changes were made: floating point is automatically used for all numbers in Alice, and the language was made case-insensitive so that names such as “Value” and “value” refer to the same variable. The talk concluded with an impressive video of four different projects done using Alice, ranging from a “Calvin and Hobbes”-inspired sled ride to computer-generated characters who follow a human aerobics instructor.

Unfortunately, Alice is available only for Windows, although a Playstation port is being worked on, and the resulting structural changes should also provide for a MacOS port. In answer to an audience member's question about using Alice on the Macintosh, Pausch replied that you'd have to purchase VirtualPC for the Macintosh; Alice is efficient enough to run acceptably under emulation. Therefore, instead of waiting for a Linux port, you should probably just buy VMware and a copy of Windows. Alice is exciting enough to be worth it!

Guido van Rossum's nascent “Computer Programming for Everybody” project aims to use Python for teaching by creating a sophisticated programming environment that helps out novices, writing a CS curriculum and perhaps modifying the Python language to make it easier to learn. At the moment, Van Rossum is gearing up to start work on CP4E, thinking about incremental parsing and type inferencing—and deciding what to teach in one semester. Van Rossum would like a spell-checker-style mode of operation for the teaching environment, so that as soon as one types a line of code, it would be checked and any possible problems noted.

A birds-of-a-feather session on education had 40 attendees and led to the creation of an Education SIG that will continue to discuss and develop teaching aids for Python.

Scientific Programming

Over the last five years, an increasing number of people have begun using Python for numeric work. The canonical story told in scientific programming papers at Python conferences usually runs something like this: a group has an existing body of numeric routines, usually written in Fortran or C/C++. To speed up prototyping, the group decides to write a scripting language that gives them an interpreted environment to experiment in. However, along the way, someone discovers Python, and rather than re-invent the wheel and maintain their own interpreter, they realize it's much easier just to write a Python interface to the number-crunching code.

Python's suitability for numeric work stems from three main reasons. First are the excellent Numeric Python extensions that provide powerful, multidimensional matrix types.

The second reason is SWIG, which can parse a C header or Fortran file and automatically generate a Python wrapper for the C or Fortran functions. SWIG also supports Perl and Tcl (XXX and Guile?), but here the third factor comes into play. Python's syntax is simple and relatively familiar, unlike the shell-influenced structures of Tcl and Perl, or the parenthesis-heavy Scheme/Lisp syntax that people either love or loathe.

An excellent example would be the talk “Using Python to Modernize Astronomical Software” by Richard White and Perry Greenfield. The authors work for the Space Telescope Science Institute in Baltimore, which is responsible for processing data from the Hubble Space Telescope. They use an astronomical software environment called IRAF, consisting of around a million lines of code. IRAF provides a portable, though not feature-rich, environment for writing analysis software, but the command language isn't very flexible or easy to use. They started down the path of writing their own new language, then discovered Python and decided to use it as the new IRAF command language. Because IRAF works by running subprocesses for each job, Python needs only to be able to speak IRAF's interprocess protocol in order to fit into the system. The Python interface, called PyRAF, will soon be going into beta testing at a few sites, with final release in a few months. It can also parse and emulate the old command language to provide backward compatibility.

Commercialization

The increasing commercial importance of Python was also visible. Free software generally starts out being experimented with by a few adventurous users in their spare time, who then quietly begin using the software for real work. Early adopters often have to battle reluctant managers who are doubtful about trying an unfamiliar program, but when the software gains in popularity, the early adopters are well placed.

Judging by several announcements, Python is moving smoothly along this path. The Python Consortium, which provides a way for companies to fund Python's ongoing development, has grown to two full-member companies and seven associate members.

As another example, ActiveState will now be providing enterprise-class support for Python, as they currently do for Perl. They've definitely started off on the right foot, joining the Python Consortium and hiring Mark Hammond and David Ascher. Both have been part of the Python community for years; Mark Hammond is the primary author of the Python Windows port and co-author of the O'Reilly Python Programming on Win32, and David Ascher maintained Numeric Python for awhile and co-authored Learning Python. Since they've got two highly skilled developers, I expect to see interesting Python-related things coming out of ActiveState before too long.

Several well-known Python developers have formed their own companies. Fredrik Lundh's SecretLabs AB demonstrated PythonWorks, their commercial integrated development environment. Neuberger & Hughes presented WorldPilot, a web-based mail and calendar application built on top of Zope. Andy Robinson and Aaron Watters announced the formation of ReportLabs, which will provide consulting services based on PDFgen, their open-source Python library for creating PDF documents programmatically. All of these companies have contributed significant pieces of free software to the Python community.

Developer's Day

Happily, commercialization hasn't diluted the conference's strong technical slant. As a few weeks of reading comp.lang.python will tell you, Python programmers tend to be inveterate language hackers, curious to explore new programming language ideas and to apply them to Python. Two fascinating, though challenging, talks were presented that discussed potential new directions for Python. John Aycock's “Aggressive Type Inference” talk described a type inferencing system for Python, then tested its accuracy by running it on a number of sizable Python programs such as IDLE, Gadfly and Grail. This confirmed Aycock's hypothesis that most variables in Python programs can have a consistent type inferred for them. Programmers rarely use the same variable name for both a list and an integer, and such polymorphism is usually confined to a few sections of code.

Christian Tismer's “Stackless Python” presentation was even more exciting. The current Python interpreter does a C function recursion for every Python function call, which means you can recurse only so deeply before filling up the C stack. Tismer performed some major surgery on the Python interpreter's virtual machine, allowing implementation of various language features such as continuations, generators, co-routines and microthreads. Christian even suggested it would be possible to pickle an entire interpreter state, ship it to an interpreter on another machine, unpickle it and resume the thread of execution.

Another IPC tradition has been Developer's Day, where lively free-for-all sessions give participants a chance to discuss future development over a higher-bandwidth medium than a mailing list. This year, sessions covered such topics such as internationalization, documentation tools, XML software and compiler tools.

Next Year

The conferences have previously alternated between East Coast and West Coast cities, but the upcoming 9th conference will break that pattern by being in Washington DC again, in November 2000. That's quite soon, so start working on papers now!

Resources

Andrew Kuchling works as a web site developer for Magnet Interactive in Washington, D.C. One of his past projects was a sizable commercial site that was implemented using Python on top of an Illustra database. He can be reached via e-mail at akuchling@acm.org.