Python Course
From CERES
A separate page for discussions
Introduction
Books:
- http://www.diveintopython.net/ - really good, but a little bit dated
- http://learnpythonthehardway.org/book/ - seems good, even if a little basic (but I have not read it)
IDE:
- IDLE: http://www.ai.uga.edu/mc/idle/index.html
- Wing IDE: http://www.wingware.com/
- Eric: http://eric-ide.python-projects.org/
- Eclipse & PyDev plugin: http://pydev.org/
- pyscripter: http://code.google.com/p/pyscripter/
- also, http://bit.ly/tgMCbD
Official:
- Download: http://www.python.org/ (remember to grab 2.x branch -- current version is 2.7.3)
- Documentation: http://docs.python.org/2.7/
- Tutorial: http://docs.python.org/2.7/tutorial/index.html
- Library Reference: http://docs.python.org/2.7/library/index.html
Things to start with
Essential libraries:
- numpy / scipy
- matplotlib
2013.01.23
Things I have talked about today (non-obvious and important stuff in bold):
- Hello, world!
- list / dictionary / string / number / tuple / set
- functions
- default arguments, keyword arguments, variable argument lists
- anonymous functions / lambda
- exceptions
- if / for / while / else / break / continue
- else also works for loops
- variables & assignment
- pass-by-reference semantics
- difference between = and ==
- generators / iterators
- list comprehension / generator comprehension / dictionary comprehension
- string formatting
- modules / import / import as / import from
- classes
- special methods: __init__ / __str__ / __eq__ / __call__ / ...
- descriptors
- advanced ideas
- decorators
- metaclasses
Things I did not have time to talk about but I wanted to... modules in standard library you should definitely know about:
- sqlite3
- collections (especially defaultdict)
- re
- datetime
- threading / multiprocessing / Queue
- random
- itertools / functools
- os / sys / shutil / os.path
- pickle
- md5
- subprocess
- socket
- urllib / httplib / email / cgi / urlparse / cookielib
- pdb (especially pm)
- win32api / win32gui
Additional
Advanced stuff:
Fun:
library Presentations
- NumPy and SciPy (presented by Wagner) File:Python course (scipy and numpy) (Wagner).zip
- Scikit (presented by Jens)
- Matplotlib (presented by Saeed) File:Matplotlib pres.zip