3D β 2D β Feature Extraction β Classical ML β Deep Learning β 3D Learning
TreeSpicesClassification is a Multimedia Data Processing project that focuses on the classification of 3D tree leaf/branch models across several species using three major methodological families:
- Indirect Methods - Convert 3D to 2D, extract classical features
- Quasi-Direct Methods - Multi-view 2D deep learning
- Direct 3D Deep Learning Methods - Direct point cloud processing
The goal is to compare how different feature extraction, representation, and learning techniques perform on the same 3D dataset.
Key Details:
- The dataset contains 3D point clouds of 7 species of trees
- Processed models with 2D/3D feature extraction
- Trained classical ML and deep learning models
- Comprehensive evaluation and visualization of results
TreeClassification/
β
βββ Utils/
β βββ data_loader.py # Load & preprocess point cloud data
β βββ preprocessing.py # Data cleaning & normalization
β βββ projections.py # 3D β 2D projection converter
β βββ feature_extraction.py # Extract LBP, PFH, FPFH, CNN features
β βββ helpers.py # Utilities & visualization
β
βββ Datasets/
β βββ Train/ # 80% training split
β βββ Test/ # 20% testing split
β
βββ Notebooks/
β βββ LBP_Feature_Extraction.ipynb
β βββ SVM_Classification.ipynb
β βββ CNN_From_Scratch.ipynb
β βββ ResNet_FineTuning.ipynb
β βββ ResNet_FeatureExtraction_SVM.ipynb
β βββ ResNet_TransferLearning.ipynb
β βββ Fusion_CNN.ipynb
β βββ QuasiDirect_PFH_SVM.ipynb
β βββ Direct_PointNet.ipynb
β βββ Direct_DGCNN.ipynb
β
βββ Outputs/
β βββ MultiView_Data/
β β βββ (5 projections per 3D model)
β β
β βββ Features/
β β βββ 2D_LBP_Features.npy
β β βββ 2D_FPFH_Features.npy
β β βββ Features.csv
β β
β βββ Features3D/
β β βββ PFH_3D.npy
β β βββ FPFH_3D.npy
β β βββ Descriptors/
β β
β βββ Models/ # (for future model saving)
β
βββ README.md
The dataset contains 3D point cloud files for 7 different tree species.
All samples were preprocessed and split into:
- Train: 80%
- Test: 20%
Datasets/Train/ # Training data (80% split)
Datasets/Test/ # Testing data (20% split)
Additional intermediate datasets (2D projections, extracted features) are saved under Outputs/.
Below are the three large families of methods implemented in the notebooks.
These methods convert 3D point clouds into 2D images, then extract classical features.
Steps:
- Convert 3D point cloud β 2D projection images
- Extract 2D features:
- LBP (Local Binary Patterns)
- HOG (if used)
- Flatten & normalize features
- Train classical ML models:
- SVM (primary model used)
- KNN / Random Forest (optional)
Related Notebooks:
LBP_Feature_Extraction.ipynbSVM_Classification.ipynb
Outputs Saved:
Located in Outputs/Features/:
2D_LBP_Features.npy- Feature matrices (.npy / .csv)
Quasi-direct methods preserve partial 3D information through multi-view projection.
Steps:
- Generate 5 projections per 3D model (top, bottom, side, oblique, etc.)
- Train 2D CNN models:
- CNN from Scratch
- ResNet (Transfer Learning)
- ResNet (Fine-Tuning)
- Extract ResNet deep features and classify with SVM
- (Optional) Fusion of multi-view CNN predictions
Related Notebooks:
CNN_From_Scratch.ipynbResNet_FineTuning.ipynbResNet_FeatureExtraction_SVM.ipynbResNet_TransferLearning.ipynbFusion_CNN.ipynb
Outputs Saved:
Located in Outputs/MultiView_Data/:
- 5 projected images per 3D object
Located in Outputs/Features/:
- Feature matrices extracted using CNN / ResNet
These methods operate directly on 3D point cloud data without converting them to 2D.
State-of-the-Art Architectures:
- PointNet - Pioneering direct point cloud processing
- DGCNN (Dynamic Graph CNN) - Graph-based point cloud learning
Steps:
- Load point cloud file
- Normalize and sample points
- Train PointNet/DGCNN
- Evaluate on 20% test set
Related Notebooks:
Direct_PointNet.ipynbDirect_DGCNN.ipynb
Outputs Saved:
Located in Outputs/Features3D/:
- PFH / FPFH 3D descriptors
- 3D deep features
- Normalized point cloud samples
The Utils/ directory contains reusable functions:
| File | Purpose |
|---|---|
data_loader.py |
Load point cloud data, normalize, split |
preprocessing.py |
Denoising, normalization, format conversion |
projections.py |
Convert 3D β 2D (multi-view generator) |
feature_extraction.py |
Extract LBP, PFH, FPFH, CNN features |
helpers.py |
Plotting, metrics, model utilities |
Contains all 2D projections of the 3D dataset
- 5 images per 3D object
- Used by CNN/ResNet models
LBP, FPFH, CNN extracted features (.npy, .csv formats)
- Classical ML feature matrices
- Deep learning embeddings
3D features for direct learning methods
- PointNet embeddings
- PFH / FPFH descriptors
- Normalized point clouds
(Models not saved β folder available for future expansion)
Evaluation metrics applied across all methods:
- Accuracy - Overall correctness
- Precision / Recall / F1-score - Per-class performance
- Confusion Matrix - Error analysis
- Training Time - Computational efficiency
- Robustness - Noise, rotation, point density variations
| Method | Type | Description | Scope |
|---|---|---|---|
| Indirect | 2D + Classical ML | LBP + SVM | Fast, simple |
| Quasi-Direct | Multi-view CNN | ResNet, fine-tuning, fusion | Strong performance |
| Direct | 3D Deep Learning | PointNet, DGCNN | Highest geometric fidelity |
pip install -r requirements.txtOpen any notebook in the Notebooks/ folder to run experiments:
- Choose based on the method you want to explore
- Each notebook is self-contained with explanations
python Utils/projections.pyThis will generate 5 projections for each 3D model and save to Outputs/MultiView_Data/.
python Utils/feature_extraction.pyThis will extract LBP, FPFH, and other features, saving results to Outputs/Features/.
Choose the notebook depending on your method:
- Classical ML:
SVM_Classification.ipynb - 2D CNN:
CNN_From_Scratch.ipynb - ResNet Transfer Learning:
ResNet_TransferLearning.ipynb - 3D Direct - PointNet:
Direct_PointNet.ipynb - 3D Direct - DGCNN:
Direct_DGCNN.ipynb
Supervision: Said Ohamouddou
Repository: https://github.com/nvcy/TreeClassification
TreeSpicesClassification demonstrates how data representation dramatically influences classification performance.
By comparing Indirect, Quasi-Direct, and Direct approaches, this project provides a complete view of the challenges and trade-offs in processing 3D multimedia data:
- π Indirect methods offer simplicity and speed
- π¨ Quasi-direct methods balance 3D information with 2D CNN advantages
- π· Direct 3D methods leverage geometric fidelity for optimal performance
This systematic exploration enables researchers and practitioners to make informed decisions when choosing methodologies for 3D object classification tasks.
For questions or inquiries, please reach out via the GitHub repository.
Last Updated: November 26, 2025