Fix image data type issues in rank filter example