Feed on
Posts
Comments

massachusetts words

Since I moved here I have had to relearn how to speak. This is largely because english takes on a new set of rules once you cross state borders and people feverishly defend their manner of pronunciation. I don’t mean the accent - everyone knows car=cah, park=paaaaak and stuff like that, I mean the names of places. God help you if you call Peabody “pea body”. Here is a short prononciation guide for the next time you’re in town.

Peabody: pee-buddy, a friend you urinate with
Reading: red-ing, If ING changed their color to red the logo would be a red ING
Medford: med-fud, I have no idea
Watertown: water-town, wtf? why isn’t it wudder-ton
Barnstable, barn-stubble, if you made a barn from ents this would be what you get if he didn’t shave for a few days.

Of course there are a million more but I’ll leave that as an exercise for the reader. Now get back to work.

pycallgraph

I saw pycallgraph on freshmeat today so spent a couple minutes playing with it. Initial impression is good and I’m looking forward to stretching its legs out soon. I through together a quick python script to see what pycallgraph is all about. Like most things in python is incredibily easy to use - with a couple lines of code you can add this into existing projects as well as new ones.

Here is the source for my test app:

#!/usr/bin/python
import pycallgraph

def aplusb(a,b):
    if a == 7:
        a = seven()
    return a   b

def aminusb(a,b):
    return a - b

def printTest(input):
    print 'Input is '   input

def seven():
    return 7

#################
pycallgraph.start_trace()

print 'starting script'
list = []
list.append( aplusb(7,4) )
print '7 - 4 = '   str( aminusb(seven(),4) )
printTest('this is a print test string')
print list

pycallgraph.make_dot_graph('test.png')

and we’re off

as a wise, talented, and enthusiastic basketball announcer once said, ‘…boom goes the dynamite’. the lumpypear crew announces their first blog, the lumpy blog.

be sure to keep checking back as we will post regularly. thanks for tuning in!

the lumpy team



« Newer Posts