Archive for the 'code' Category


How SQLite Is Tested

How SQLite Is Tested. Nice well written article. Section 9 is especially interesting: Our experience, then, is that static analysis is counter-productive to quality. In other words, focusing on static analysis (being concerned with compiler warnings) actually reduces the quality of the code. Nevertheless, we developers have capitulated to pressure from users and actively work [...]

Python’s multiprocessing module is the new hottness

The new multiprocessing module in Python 2.6 and 3.0 looks pretty cool. It gets around the whole, um, design for low performance where the dreaded Global Interpreter Lock (GIL) makes multithreading difficult, by making it easy to spawn python subprocesses, communicate with them, and share data. They even have a form of security on the [...]

InfiniteSortedObjectSequence – for large data sets in Python

What do you do when you have a data set too large to fit into RAM? You could just use disk directly, so instead of a dict you use a shelve or bsddb, however the problem with that is that you then have a performance hit as all operations are disk based. You could have [...]

MapReduce in 10 or so lines of Python

I’ve realized that I understand things best when I implement them myself, and I was recently reading Trevor Strohman’s dissertation, intriguied by TupleFlow, a kind of more elaborate and improved MapReduce, and was about to write my own toy impl of TupleFlow when I decided to simplify and just for fun write MapReduce in Python. [...]

Short JSP example for java code that generates an PNG or JPEG image on the fly

I find it easier to crank out code with JSP that to do things the more proper way w/ Servlets. At times I want to generate images (PNG/JPEG) on the fly and if you’ve never done it before it’s hard to get it right initially. What follows is a small JSP code fragment that dynamically [...]

More on redirecting from Textpattern to WordPress

I hacked up the Textpattern top level index.php so that it tries to redirect to WordPress. Of course I found a bug in the import script: it silently fails on articles that have single quotes in their title. Anyway, my code tries to be fail-safe — in this case it falls thru to the defalt [...]

-->
  • Activity

  • Archives

  • Categories