MRG Allow directed and undirected graphs in GraphCRF.

Adds directed graphs. This is in anticipation of chain CRFs, which can then just be a special case.