Minimally Faithful Inversion of Graphical Models