Inspiration

The idea was born out of an experience working in a paint inspection booth at Toyota. The process of inspecting painted vehicles coming out of the bake ovens for dirt deposits is manual and prone to human error. The idea was to automate the process to reduce the number of defects coming out of the paint inspection.

What it does

It's computer vision takes a PNG and creates a heatmap of abnormalities in the image. If the photo read has name IMAGENAME.png, the output has name abnscan_IMAGENAME.png.

How we built it

Overnight, using Java.

Challenges we ran into

Bugs. The heatmap uses differences in RGB values, which are normally stored in a 4-byte integer in ARGB format. Java doesn't support unsigned integers, so we could not create an opaque ARGB image with the colors we wanted. After a while looking through Java docs, we found that Color could return an int in RGB format, so we updated the format of our output image to match.

Also, we used linked lists to represent different colors, and the insert function needed strange functionality not built in LinkedList<>. insert() is not a complex function, but it was very hard to wrap our heads around.

Accomplishments that we're proud of

The pixel-comparison algorithm is relatively simple, but it works well and is extendable. (The actual comparison could be replaced by another algorithm -- for example, taking linear combinations of expected colors.)

Similarly, the scan is done independent of the heatmap. The main program could easily be modified to, say, return coordinates to abnormal points. These could be used to automate fixing the problem.

What we learned

I'm too tired for this shit.

What's next for PNG Abnormality Scanner

Scanning PNGs. Maybe it'll support other image formats someday.

Built With

Share this project:

Updates