What energy functions can be minimized via graph cuts? | Synapse