Taking out duplicate gems.