Live data from Hacker News

The Problem with Perceptual Hashes

rentafounder.com

11–20 of 440 posts

Re: The Problem with Perceptual Hashes

#11
post #7

Apple would not be so naive as to roll out a solution to child abuse images that has a high false positive rate. They do test things prior to release…

Test it… how exactly? This is detecting illegal material that they can’t use to test against.

Not knowing anything about it but I suppose various governmental agencies maintain corpora of nasty stuff and that you can say to them - hey we want to roll out anti-nasty stuff functionality in our service therefore we need access to corpora to test at which point there is probably a pretty involved process that requires governmental access also to make sure things work and are not misused otherwise -

how does anyone ever actually fight the nasty stuff? This problem structure of how do I catch examples of A if examples of A are illegal must apply in many places and ways.

Re: The Problem with Perceptual Hashes

#12

I do not know as much about perceptual hashing as I would like, but have considered it for a little project of my own. Still, I know it has been floating around in the wild. I recently came across it on Discord when I attempted to push an ancient image, from the 4chan of old, to a friend, which mysteriously wouldn't send. Saved it as a PNG, no dice. This got me interested. I stripped the EXIF data off of the original…

AFAIK Discord's NSFW filter is not a perceptual hash nor uses the NCMEC database (although that might indeed be in the pipeline elsewhere) but instead uses a ML classifier (I'm certain it doesn't use perceptual hashes as Discord doesn't have a catalogue of NSFW image hashes to compare against). I've guessed it's either open_nsfw[0] or Google's Cloud Vision since the rest of Discord's infrastructure uses Google Cloud VMs. There's a web demo available of this api[1], Discord probably pulls the safe search classifications for determining NSFW.

0: https://github.com/yahoo/open_nsfw

1: https://cloud.google.com/vision#section-2

Re: The Problem with Perceptual Hashes

#13

Why wouldn't the algo check that one image has a face while the other doesn't? That would remove this particular false positive, though I'm not sure what it might cause of new ones.

Because where do you draw the line with classifying arbitrary features in the images? The concept is it should work with an image of anything.

Re: The Problem with Perceptual Hashes

#14
post #3

I am fairly ignorant if this space. Do any of the standard methods use multiple hash functions vs just one?

I've built products that utilize different phash algorithms at once, and it's entirely possible, and quite common, to get false positives across hashing algorithms.

Re: The Problem with Perceptual Hashes

#15
post #5

I am not exactly buying the premise here, if you train a CNN on useful semantic categories then the representations they generate will be semantically meaningful (so the error shown in blog wouldn’t occur). I dislike the general idea of iCloud having back doors but I don’t think the criticism in this blog is entirely valid. Edit: it was pointed out apple doesn’t have semantically meaningful classifier so the blog pos…

I agree the article is a straw-man argument and is not addressing the system that Apple actually describes.

Re: The Problem with Perceptual Hashes

#17
It really all comes down to if Apple has and is willing to maintain the effort of human evaluations prior to taking action on the potentially false positives:

> According to Apple, a low number of positives (false or not) will not trigger an account to be flagged. But again, at these numbers, I believe you will still get too many situations where an account has multiple photos triggered as a false positive. (Apple says that probability is “1 in 1 trillion” but it is unclear how they arrived at such an estimate.) These cases will be manually reviewed.

At scale, even human classification which ought to be clear will fail, accidentally clicking 'not ok' when they saw something they thought was 'ok'. It will be interesting to see what happens then.

Re: The Problem with Perceptual Hashes

#18

I've also implemented perceptual hashing algorithms for use in the real world. Article is correct, there really is no way to eliminate false positives while still catching minor changes (say, resizing, cropping, or watermarking). I'm sure I'm not the only person with naked pictures of my wife. Do you really want a false positive to result in your intimate moments getting shared around some outsourced boiler room for…

> I'm sure I'm not the only person with naked pictures of my wife.

I'm not completely convinced that says what you want it to.

Re: The Problem with Perceptual Hashes

#20
Apple’s documents said they require multiple hits before anything happens, as the article notes. They can (and have) adjusted that number to any desired balance of false positive to negatives.

How can they say it’s 1 in a trillion? You test the algorithm on a bunch of random negatives, see how many positives you get, and do one division and one multiplication. This isn’t rocket science.

So, while there are many arguments against this program, this isn’t it. It’s also somewhat strange to believe the idea of collisions in hashes of far smaller size than the images they are run on somehow escaped Apple and/or really anyone mildly competent.

Post reply on HN