- Preprocessing: Includes resize, convert to grayscale, and preparing images for feature extraction.
- Feature Extraction: Utilizes Haralick texture features with
d=(1,2,3)
andtheta=(0,45,90,135)
combination. - Classification: Implements KNN for classifying apple ripeness levels with different K values to each dataset combination.
- Dashboard: Interactive Streamlit dashboard for visualizing results and exploring data.
- Clone the repository:
git clone https://github.com/Bagusdevaa/Apple-Classfication-using-Harralick-and-KNN.git cd Apple-Classfication-using-Harralick-and-KNN
- Set up a Python virtual environment:
python -m venv skripsi skripsi\Scripts\activate
- Install dependencies:
pip install -r requirements.txt
- Navigate to the
src/dashboard
directory. - Run the Streamlit app:
streamlit run app.py
- Open the provided URL in your browser to access the dashboard.
- Explore the Jupyter notebooks in the
notebooks/
directory for preprocessing, feature extraction, and classification.
The dataset is organized into folders based on ripeness levels (20%, 40%, 60%, 80%, 100%). Each folder contains images of apples at the corresponding ripeness level.
- The dashboard provides visualizations of classification results, including accuracy, precision, recall, f1-score, confusion matrices, and Nearest Neighbors Visualizatoin.
- The best KNN hyperparameters and K value of KNN are determined through experimentation and displayed in the dashboard.
This project is for educational purposes and is not licensed for commercial use.