This project demonstrates a MATLAB implementation for fruit detection in 3D LiDAR point clouds using the Velodyne VLP-16 LiDAR sensor (Velodyne LIDAR Inc., San Jose, CA, USA). The dataset contains 3D point clouds of 11 Fuji apple trees and corresponding fruit position annotations. The implementation uses a Support Vector Machine (SVM) classifier for fruit detection.
Setup and Requirements
-
Clone the Code: To begin, clone the repository using the command:
git clone https://github.com/GRAP-UdL-AT/fruit_detection_in_LiDAR_pointClouds.git
-
Data Preparation: Create a folder named “data” in the directory where the code is saved. Inside this folder, store the ground truth data and point cloud data in subdirectories named “AllTrees_Groundtruth” and “AllTrees_pcloud”, respectively.
-
Prerequisites: Ensure you have the following installed in MATLAB:
- MATLAB R2018 (other versions not tested)
- Computer Vision System Toolbox
-
Statistics and Machine Learning Toolbox
-
Dataset: The LFuji-air dataset is stored in the /data folder. This dataset provides the necessary LiDAR data for training and evaluation.
-
Cross-validation: Perform cross-validation to evaluate the performance of the model in detecting fruit within the LiDAR point clouds.
Notes
- The implementation is optimized for MATLAB R2018 and tested specifically on this version.
- The project utilizes a dataset that includes both ground truth fruit positions and point cloud data for training the detection model.