An IOAI solution repository

IOAI 2025 Day 2 - Restroom (Problem 1)

09 Aug 2025

# Abridged task description

The full task description is available here

You are given a bunch of cropped photos of restroom Male/Female signs. You need to match each cropped photo to the uncropped photo of the restroom sign that was

  1. Taken from the same restroom, and,
  2. Is of the opposite gender

# Unofficial writeup

# 100 points

Credit: Singapore

In order to find the photos from the same restrooms, you can take a colour histogram of all the cropped and uncropped photos, and match each cropped histogram to its two closest uncropped histograms. This is because photos taken from the same restrooms would appear to have very similar colour palettes. This would reduce your match to two possible options (the uncropped Male and Female signs).

Then you can fine-tune a pretrained ResNet50 to detect whether a restroom sign is Male or Female, in order to find the sign of the opposite gender.

References: This message by Kieran