Skip to content

Instantly share code, notes, and snippets.

@mbrucher
mbrucher / test_thin_plates.py
Created July 17, 2015 14:40
Deformation fields with thin-plates
import unittest
import numpy
from numpy.testing import *
set_package_path()
from transformation import *
restore_path()
class TestDeformationCreation(NumpyTestCase):
def test_1DCreation(self):
@mbrucher
mbrucher / hpctoolkit2callgrind.py
Last active August 29, 2015 14:24
Script to convert from XML HPCToolkit format to callgrind
#!/usr/bin/env python
from xml.sax import ContentHandler, make_parser
from collections import defaultdict
class HPCToolKitHandler(ContentHandler):
def __init__(self, f):
self.f = f
self.metrics = {}
self.files = {}