Part of the reason for Python’s popularity is the availability of many high-quality libraries that help with various software tasks. In this appendix are descriptions of a few of the most popular packages.
It is useful to keep in mind that many of these packages may work only with specific versions of Python (which you can always download for free from www.python.org). In particular, many packages do not yet support Python 3, so you may need to use Python 2.6 (or later) to run some of these. Fortunately, if you already know Python 3, it is not too hard to step back a version to use Python 2. Appendix B briefly discusses some of the major differences between Python 2 and Python 3.
PIL (www.pythonware.com/products/pil) is an image-processing library. It works with many different kinds of image formats, and provides a number of useful image-processing functions for tasks such as cropping, resizing, rotation, and filtering.
Tkinter comes with the Python library and is the standard means of accessing the popular Tk GUI tool kit. If you want to create a graphical user interface (GUI) in Python, this should be your first stop. See http://docs.python.org/dev/3.0/library/tkinter.html for more information.
Zope (www.zope.org) is a full-blown Web application server that you can use to host large and interactive Web sites. It is largely written in Python and uses Python as the main scripting language for creating new plug-ins. You can find lots of documentation for getting started on the Zope home page.
Django (www.djangoproject.com) is a framework for quickly creating interactive Web applications. Unlike Zope, it is not a complete Web server that works out of the box; rather, Django is a programming tool kit that makes it relatively easy to create new Web sites in a short time. In this way, it is similar to Ruby on Rails, but it uses Python instead of Ruby as the underlying programming language.
Pygame (www.pygame.org) is a popular Python package that lets you create and control two-dimensional animations, especially for games. It provides tools for graphical animation, sound, and input devices such as joysticks. There are also introductory tutorials and sample programs at the pygame Web site to help get you started.
SciPy (www.scipy.org) is a large and popular library of software tools for scientific computing (it even has its own associated conferences!). It provides mathematical software to do things such as solve optimization problems, perform numerical linear algebra calculations, process signals, and much more.
Twisted (http://twistedmatrix.com/trac) is a popular Python library for network programming. It supports numerous networking protocols, and includes things like Web servers, mail servers, and chat clients/servers.
The Python Package Index (http://pypi.python.org/pypi) is a frequently updated list of thousands of user-submitted Python packages. It’s a good place to look for special-purpose Python libraries, or just to browse to see what uses Python has been put to.
You can easily find thousands of other Python packages by searching the Web: For almost any programming task that someone has done before, you are likely to find a Python library!
3.12.161.6