View process-podcasts-Makefile
# process podcasts
MP3S = $(filter-out $(wildcard *.64kbit.mp3),$(wildcard *.mp3))
PROCESSED = $(patsubst %.mp3,%.64kbit.mp3,$(MP3S))
.PHONY: process
process: videos $(PROCESSED)
@echo Done.
.PHONY: videos
#!/bin/env python
"""get svn diff and compare added functions to removed functions,
command line args passed through to svn diff, e.g. use -r nnn:nnn to filter a specific revision."""
import sys, subprocess, re
from collections import defaultdict
svn_diff = subprocess.Popen(['svn', 'diff'] + sys.argv[1:], stdout=subprocess.PIPE).communicate()[0]
defn1 = "\W((?:def|class)\s+\w+)[:\(]" # python def and class
#!/usr/bin/env python
Create an archive which will be suitable for rsyncing to a remote backup.
- will not copy data unnecessarily for common operations such as
renaming a file or reorganising the directory structure.
(assumes large files are generally going to be immutable, e.g. audio/video)
- doesn't try to do anything fancy with permissions etc.
#!/usr/bin/env python
# add OSD from ArduPilotMega log file to a video
import sys
from path import path
from datetime import datetime, timedelta
from PIL import Image, ImageDraw
from math import sin, cos, radians
# STEP 1: use mplayer to extract jpgs and wav
#!/usr/bin/env python
# kd-tree index and nearest neighbour search
# includes doctests, run with: python -m doctest
class KDTree(object):
kd-tree spatial index and nearest neighbour search
#!/usr/bin/env python2.6
from __future__ import print_function
import sys
from scipy.stats.distributions import norm as scipy_norm
beta = 25/6
gamma = 25/300
epsilon = 0.08