Skip to content

Instantly share code, notes, and snippets.

View ccoughlin's full-sized avatar

Chris Coughlin ccoughlin

View GitHub Profile
@ranman
ranman / gist:1094400
Created July 20, 2011 05:30
constantly updating dict
from multiprocessing import Process, Lock, Manager
from time import sleep
def update_dict(cls, db, lock):
temp_db = {}
while True:
lock.acquire()
try:
temp_db['userRatings'] = db['userRatings'] + 1
temp_db['venueToVenue'] = db['venueToVenue'] +1
@huyng
huyng / matplotlibrc
Created February 8, 2011 15:50
my default matplotlib settings
### MATPLOTLIBRC FORMAT
# This is a sample matplotlib configuration file - you can find a copy
# of it on your system in
# site-packages/matplotlib/mpl-data/matplotlibrc. If you edit it
# there, please note that it will be overridden in your next install.
# If you want to keep a permanent local copy that will not be
# over-written, place it in HOME/.matplotlib/matplotlibrc (unix/linux
# like systems) and C:\Documents and Settings\yourname\.matplotlib
# (win32 systems).