Simulating the Golden Balls game show
In this eposide of Golden Balls, an inspired event takes place: I retold the event at DIKU APL lunch (nice to have a job where game theory is a valid conversation topic), and we had a conversation about it. At…
In this eposide of Golden Balls, an inspired event takes place: I retold the event at DIKU APL lunch (nice to have a job where game theory is a valid conversation topic), and we had a conversation about it. At…
I’ve always wanted to understand Turing Machines better. I believe that the best understanding comes from the intuition developed by solving puzzles. So here, I give myself some challenges. Solve simple problems by writing programs for a simple Turing Machine,…
I’m just getting into this topic, but it seems that Python Eggs are the way to go. Here’s a good tutorial: In the long term, I’d like to be able to do: pip install
Here are three thorough answers on Python topics from StackOverflow. Metaclasses Yield, iterables, iterators, generators Decorators
Apache Cassandra is a column-store with a p2p distribution architecture. Yesterday I did a presentation about Cassandra at Grontmij, Glostrup, Denmark. I made the slides in Google Docs, and they’re public: slides.
How complicated does a mathematical function, pseudorandom(x), have to be to create something that seems random, and how do you check whether it seems random? Looking at a long list of numbers is not a good way, because our ability…
If you run ‘ll -l’ sometimes a file has ‘@’ permission. This means that the file has extended attributes. TextMate may extended attributes to a file. Consider a fictional Python file called xxx.py edited with TextMate: View extended attributes: $…
given a (2D) array a, and a smaller (2D) array b, how can you add the smaller array to the bigger array at some offset in numpy? >>> a = zeros((4,4), dtype=int) >>> a array([[0, 0, 0, 0], [0, 0,…
Mostly so I myself can remember how to do it, here is how to create a random geotiff with GDAL in Python Note: the width and height are given in opposite order in the GDAL raster and numpy arrays! import…
This is a good post showing how “perrygeo” uses Cython to speed up a pure Python function. The comments also discuss alternatives and options: Using psyco instead of Cython Using optimization flags for gcc Using xxx instead of math.xxx