1. A method of processing a set of image data, having a first plurality of nodes comprising: generating, by a computer, a first measure of affinity for each of a plurality of pairs of neighboring nodes in the first plurality of nodes; downsampling the first set of image data to generate a second plurality of nodes such that the second plurality of nodes has a fewer number of nodes than the first plurality of nodes; generating a second measure of affinity for each of a plurality of pairs of neighboring nodes in the second plurality of nodes, wherein the first measure of affinity for each of a plurality of pairs of neighboring nodes in the first plurality of nodes is used to calculate the second measure of affinity; determining if the second plurality of nodes meets a shape assumption; and using graph cuts to process the second plurality of nodes to segment an object in the set of image data.