Making Computer Vision Systems that don’t kill your users.

Joshua Herman
3 min readAug 3, 2017

--

Computer Vision has progressed to the point that Computer Vision apps are plot devices in TV shows (Silicon Valley). Unfortunately there are few resources for people on how to use Machine Learning responsibly.

Lets say you just watched the episode where they mention the hot dog app and you decide to make an serious app that attempts to detect if the food in front of you has peanuts. You are also aware classification in Computer Vision has a low barrier of entry. So you complete the app, test it on a few hundred pictures,and are about to submit it to HN. What will occur?

At least one person will directly critique your app in a negative manner (but not the usual kind that is bikeshedding). They will tell you: this app can kill or harm people and your app is dangerous. This happened to an app called Champigouf which is a computer vision app to identify mushrooms. The reason why is because certain Mushrooms are poisonious and it is easy to make a mistake.

We will now explore a theorietical app that we will call Nutsornotnuts. The objective of the app is using a picture to tell if if a dish has nuts.

Example Input to our App Nutsornotnuts. By Takeaway — Own work, CC BY-SA 3.0, https://commons.wikimedia.org/w/index.php?curid=27428512

Figuring out if a dish has nuts or doesn’t is extremly hard problem. Humans can’t perform the task reliably. Machines (an ML model) will have higher throughput and they will be cheaper. But, the better question is should I be giving this advice if the stakes are so high?

The thing that makes the stakes high is that when your app mistakenly claim that a food has no nuts when it does your error is False Negative with an extremely high negative outcome.

Lets see this in a table:

Lets compare that to the Hot dog not hot dog app.

When the nuts or not nuts app has a false negative the user may ingest the food causing anything from Mild Discomfort to anaphlactic shock and death. Not only would this be obviously extremly horrifying and possibly criminal.

A better solution to this problem would be to have a simple guide on which foods have nuts. If a person can correctly identify what the food is such as being on a restaurant menu then you would provide an app to search an ingredients or recipe database. This avoids the issue with a False Negative due to the fact that if a user can’t correctly identify the food they probably won’t search for it (and you should instruct the user to do this).

--

--