Skip to content

poevy/howls-cat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Howl's Cat

Challenge Description

In a quiet forest, a wandering house drifts between paths, bound by old and temperamental magic. It does not see the world as humans do; it gazes through its own peculiar perception, where truth bends and shapes shift unseen.

At its entrance waits Howl’s familiar—a black cat named Kuro, silent and watchful.

The spell that seals the door is a paradox:

  1. Kuro must remain Kuro.
  2. Yet the house must behold him as a banana (a most peculiar fancy of the house’s magic).

Only those who can weave a subtle enchantment—unchanging in form, yet altered in perception—may pass.

TLDR

apply perturbation to a given base image while staying within chebyshev distance limit, so player must use the base image. The perturbation should be crafted using the provided weights to subtly push the model’s confidence in the desired direction (banana, inspired from the cat banana meme wkwk apalah)

Solver

run this against the base cat.png and weights.npz, submit the generated solver.png to the web to get flag

import numpy as np
from PIL import Image

img = Image.open('cat.png').convert('L').resize((32,32))
base = np.asarray(img, dtype=np.float32) / 255.0

data = np.load('weights.npz')
v = data['v'].astype(np.float32)

eps = 16.0/255.0 - 1e-4
adv = base + eps * np.sign(v.reshape(32,32))
adv = np.clip(adv, 0, 1)

Image.fromarray((adv * 255).astype('uint8')).save('solver.png')

About

Adversarial attack challenge - adding subtle perturbations to image (difficulty: easy)

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors