Extracting foreground objects with the GrabCut algorithm