Partial Optimality by Pruning for MAP-Inference with General Graphical Models