Part 3 of the SQLAlchemy Series
Part 2 of the SQLAlchemy series
The title says it all... (Part 1 of the SQLAlchemy series)
Nice looking and feeling gvim settings for python development...
Handy recursive/labelled listing of TODO items in a source code directory...
Django's "batteries included" philosophy means that it provides a lot of nice features out of the box to make web development easier. One the most integrated features is django's ORM which provides database abstraction, allowing object oriented programming to map to relational database persistency. However, this abstraction layer brings with it some disadvantages, with a major one being performance penalties in certain scenarios.
One scenario that is strongly penalised is the bulk saving of many objects. Every time you invoke myobject.save(), a new connection is created to the database.
django_bulk_save is a helper module that provides more efficient bulk saving functionality by providing N-at-a-time commits, and has improved batch operation times from 3 minutes down to 3 seconds in some cases for me.
This python script is the result of a university course exercise in PostgreSQL database optimisation. Given a list of SQL queries, It will run VACUUM ANALYZE once, and then EXPLAIN on each query, parse the output for low and high estimated cost values from the explain output, display these costs in a table next to their corresponding query, and finally aggregate these costs into a final total cost range.
It dramatically speeds up the process of tweaking performance on PostgreSQL databases. I hope it is as useful others as it was for me. I'm releasing it here for download under the zlib license.
See full entry for more info and example usage
A thesis paper written in my final university year. The topic itself is very 'meta', and a challenge to explain succinctly to newcomers. In technical terms it's about exploring ways for expert systems to explain their assessment of learner models to their owners.
...In layman's terms:
- Computerized systems that teach and train people can often examine and assess how a user is progressing and provide feedback to that user (e.g. a touch-typing program telling user Alice that she needs to work on her home row keys).
- But the user often wants to know how and why the computer thinks this (Alice asks why the program thinks she needs improvement on her home row).
- Then the system may provide an explanation service to explain it's reasoning (the program tells Alice that it's because she makes a lot of mistakes on her home row, backing up the claim with evidence such a statistical report of mistakes made on the home row keys as compared to other keys).
The topic of the thesis is focused on this 3rd step: explanation systems (and the design/development and testing of one).
see full entry for more info
I just finished reading The Pragmatic Programmer (by the guys that brought you the DRY principle), and it's a really valuable book to read: it confirmed stuff that I've mostly already been doing, but explains it in a really clear and reinforcing way (with some really nice analogies). I only wish I had read it earlier.
So I made some notes from the book and I recommend the book to anyone that writes code.
At a place I previously worked, I got a cool little task of making an RTS-styled user interface (HUD) mockup. This was a welcome break from programming and gave me the opportunity to refresh my rusty photoshop skills.
Made this a while ago to help explain differentiation (calculus) to my sister. Covers the derivation of basic differentation identites.
Pygpw is a python module that uses a trigraph probability matrix (extracted from an english dictionary) to pseudo-randomly generate pronouncable words.
Inspired by existing C++ and Java implementations , pygpw offers added functionality, such as multiple pronouncability methods and leetification, as well as a flexible command line interface.
Here is some sample usage:
# make 3 pronouncable words
$ pygpw 3
andishia
tumircop
zonester
# make 3 pronouncable 1337 words of length 12 and explain the leetification
$ pygpw 3 -L12 --leetify --multichar --explain
r&P/-\T!/|\5 (repatims)
nUM5h`/phI(K (numshyphick)
t4|e|2PoR$EL (talerporsel)
See full entry for more awesome password generation...
This is a short Game mechanics analysis I wrote in 2009 for a University course on Video Games and Simulation. It would be much longer and more detailed if it wasn't for a word limit :)
Abstract:
"In this game analysis of Team Fortress 2, we first discuss how dramatic game dynamics are created by the game, followed by analysing the same game in terms of the networks created and community aspects and how all of this is managed and evolved over time by Valve, the developer. This analysis assumes knowledge of background context on dramatic game dynamics [1] and game community management [2] alongside general video game concepts (see glossary)."
Having just developed and deployed this modest site, I now have the arduous task of filling it with content. This website has many purposes, and I'm trying to avoid a word that starts with 'b' and ends with 'log'.
Instead of describing the purpose(s) here, I will uphold the DRY principle and instead put that information here.
The title of this entry reminds me of something mildly amusing and worth reading.