In the coffee industry, ensuring the quality of roasted coffee beans is crucial. Currently, this process is mostly done by hand, which can be slow, inconsistent, and labour-intensive. Manual inspection not only takes a lot of time but also varies from person to person, making it difficult to maintain consistent quality. This is particularly challenging given the Specialty Coffee Association (SCA) requirements, which set high standards for defect-free beans to achieve specialty status. Automating this quality control process can make it faster, more reliable, and consistent. This project tackles the problem by evaluating different image recognition algorithms to identify defects in roasted coffee beans.
For this project, a special dataset of coffee bean images was created. These images were carefully prepared to help the computer recognize defects more easily. Each image was resized to a standard size of 400x400 pixels, making sure important details like texture were preserved. The dataset included images with both natural backgrounds and pure white backgrounds to see how different settings might affect the results.
The performance of these models varied:
The pre-trained MobileNet model was particularly notable for its balance of speed and accuracy, making it ideal for real-time applications. It excelled at identifying normal beans with very few mistakes, though it had a slightly higher error rate for defective beans. The ResNet model, while equally accurate, was better suited for batch analysis due to its slower prediction time.