Fast Keypoint Recognition Using Random Ferns