Popular recipes by Simon Burton http://code.activestate.com/recipes/users/1214028/2006-11-21T08:22:51-08:00ActiveState Code RecipesAccess Cairo surface from numpy and pygame (Python)
2006-11-21T08:22:51-08:00Simon Burtonhttp://code.activestate.com/recipes/users/1214028/http://code.activestate.com/recipes/498278-access-cairo-surface-from-numpy-and-pygame/
<p style="color: grey">
Python
recipe 498278
by <a href="/recipes/users/1214028/">Simon Burton</a>
(<a href="/recipes/tags/graphics/">graphics</a>).
</p>
<p>We alias the memory from a cairo surface so that we can manipulate the bits as a numpy array, or display/manipulate the image in pygame.</p>
Handling Deeply Nested/Recursive Data (Python)
2006-04-26T06:15:08-07:00Simon Burtonhttp://code.activestate.com/recipes/users/1214028/http://code.activestate.com/recipes/302535-handling-deeply-nestedrecursive-data/
<p style="color: grey">
Python
recipe 302535
by <a href="/recipes/users/1214028/">Simon Burton</a>
(<a href="/recipes/tags/algorithms/">algorithms</a>).
Revision 2.
</p>
<p>Common python services such as pickle, deepcopy and comparison tests either fail entirely or do not scale for highly recursive data structures. This recipe presents a reversible "flatten" transformation that allows for such operations.</p>
Live Object Browser (Python)
2004-08-18T16:22:16-07:00Simon Burtonhttp://code.activestate.com/recipes/users/1214028/http://code.activestate.com/recipes/300304-live-object-browser/
<p style="color: grey">
Python
recipe 300304
by <a href="/recipes/users/1214028/">Simon Burton</a>
(<a href="/recipes/tags/debugging/">debugging</a>).
</p>
<p>Given an object, this tool throws up a gtk tree widget that maps all the references found. It dynamically builds the tree, which means it can handle large amounts of data and circular references.</p>