Spices are natural ingredients that play an important role in everyday life, especially in traditional medicine. With a variety of shapes and colors, spices are often difficult to distinguish from one another. This research aims to classify spice types based on shape and color features using K-Nearest Neighbor (K-NN) and Fuzzy methods. This research will limit the recognition of spice types to 10 specific types of spices, namely ginger, turmeric, star anise, coriander, pepper, nutmeg, galangal, cinnamon, cloves, and candlenut. Spice type recognition will be done based on shape, color and texture features extracted using 300 training data images. The application of the K-NN method and Fuzzy logic allows flexible processing of color features (HSV). Fuzzy logic classifies spice color characteristics by generating a color score (color_score), which is then used to better interpret and distinguish spice colors for the classification process between test data and training data by the K-NN method. The test results show that from a total of 100 test data, the system successfully classifies spices with an accuracy rate of 77%.
                        
                        
                        
                        
                            
                                Copyrights © 2025