Many different approaches could be taken to determine the initial
regions. The one which we have taken is to split the volume up into
connected components, inside which the phase remains within given
bounds. That is, a phase partition is initially chosen -- say
. Then, for each partition, create a mask of voxels
where the wrapped phase is within the partition. Determine the
connected components of the mask and assign each a unique region number.
Repeat for all other partitions, assigning different region numbers.
This method ensures that the phase difference between two voxels within an region must be less than the size of an individual phase partition. Hence, the smaller the partition, the less likely it is that a connected component will contain a phase wrap.