IJ. Eye

Most zombies are following a simple minded program and aim to follow and catch and bite you. Some zombies, however, are guards or scouts controlled by the evil coordinators of the zombie apocalypse. These zombies have CCDs built into their eyes. You realize you need to trick these zombies by a record-replay attack: you record still pictures of empty streets and rooms and play these pictures back directly into the eyes of the zombies (using projectors and special optics). Your trick is easily revealed if the projected images are not perfectly aligned. Software correction is needed, since it's impossible to mechanically align zombies with projectors.    eyeball
http://www.photos-public-domain.com/2013/01/21/eyeball-toy/

Your task is to prove you can perform the above attack. We've built a test bench: a camera looking at a TFT screen. You need to provide a png that we will display on the TFT so that a rectangle of the resulting image produced by the camera looks very similar to the input image.

There are two ways submitting for this task: practice submission and a for-score submission.

I. Practice

Practice submissions are displayed, digitized and the result is sent back (no score is awarded). The resulting camera jpegs will be available at the "files for your team" site (http://server.ch24.org/files/).

J. For-score

A for-score submission displays, digitizes and evaluates the digitized image, but but does not return any image, only determines the score. This is a scaled problem - see the scoring section below.

Input

A png file (the target image)

Output

A 1280x1024 pixel png file to be displayed on the screen. In case of for-score submissions, the first (top-left) pixel specifies the rectangle on the camera jpeg that will be compared against the input file:

Invalid coordinates (when bottom-right of the rectangle is beyond the jpeg) will result in a failed submission.

Scoring

The evaluated score is the RMSE (root-mean-square error) of the selected rectangle of the camera image compared to the input image:

RMSE := round(sqrt(SUM((P-Q)*(P-Q))))
where the SUM is taken over each P, Q value of each corresponding pixel and color channel of the images.

The scaled real score is

SCORE := round(100 * (1 - sqrt(1 - RMSEmin/RMSE)))
where RMSEmin is the best submission so far.

Note that the same submission may give different RMSE values due to camera noise. To reduce this effect several camera images will be averaged before a submission is evaluated.

Examples

Offline examples are not available; please submit practice solutions and look at the resulting camera jpegs.