python modular of FactorGraphModel

@ppletscher, @iglesias I added a python example. I think one ipython notebook will be enough, so I leave that for OCR demo. Before, I'll send another PR for few more unit-tests.