kostas

kostas

Make a RAM disk on Mac OS X 1.5 or later

Create the RAM disk: diskutil erasevolume HFS+ “ramdisk” `hdiutil attach -nomount ram://1165430` (the magic number 1165430 is explained here as the number of 512 byte sectors. The string “ramdisk” is just the name of the disk, which will appear under…

Calling a Python LP-solver from a PostgreSQL function

Prepare the database by installing PL/Python and a function: CREATE EXTENSION IF NOT EXISTS plpythonu; CREATE OR REPLACE FUNCTION hello_lp() RETURNS float[] AS $$ import subprocess output = subprocess.Popen ( [ “”, “” ], stdout = subprocess.PIPE, stderr = subprocess.STDOUT…

NSA back door

This is geek humor at it’s best, and is one of the funniest reactions to PRISM I have seen. Here is a screenshot from the github project flask-nsa The project description simply goes: “Give the NSA free backdoor access to…

Introducing the Web Co-Processor

Here is a project I’m working on called the Web Co-Processor (credit for name goes to Marcos Vaz Salles). There is a demo you can try if you clone the project. Read the following four bullets and you’ll understand what…

The new Google Maps: Explorers delight!

Being interested in maps in general, and specifically vector data, of course I had to take the new Google Maps for a spin. Vector data aside, what fascinated me most was the option to display photos of the current location…

Go, go, go

I’ve decided to learn Go. Not the board game, but the programming language. Why? I’ve been wanting to learn a systems programming language for a while, but have so far avoided picking up my brick of a C++ manual.