adding mmorph.py from pymorph for heatmap computation