Incremental work on chapter 2'
Removed big swath and replaced with new python based stuff.