# This file contains metadata for your plugin.

# This file should be included when you package your plugin.# Mandatory items:

[general]
name=Supervised Classifier
qgisMinimumVersion=3.0
description=A plugin to classify a selected raster file with reference. The Supervised Classifier Plugin for QGIS is a powerful tool that facilitates the classification of satellite images using supervised learning algorithms.  Part of MAS Raster Processing tools.
version=1.0.6
author=Mirjan Ali Sha
email=mastools.help@gmail.com

about=Supervised Classifier: A plugin to classify selected raster file with reference or pre-trained models.
    This plugin provides an easy-to-use interface for loading satellite images and selecting from a variety of supervised classification methods, including "Minimum Distance", "Random Forest", "Gradient Boosting", "SVM", "KNN", "Maximum Likelihood", "LDA", "QDA".  
    Key Features: 
    - User-Friendly Interface with Batch Processing 
    - Multiple Classification Algorithms (Random Forest, Gradient Boosting, SVM, KNN, Minimum Distance, Maximum Likelihood, LDA, QDA) 
    - Accuracy Assessment with Confusion Matrix, Kappa, Precision/Recall/F1-Score
    - Export Training Samples as CSV
    - Pre-trained Model Support 
    - Classify multiple rasters using saved models 
    - Band Selection 
    - Choose specific bands for classification 
    - Multiple Label Field Support -
    Handle complex reference shapefiles 
    - Model Saving & Export 
    - Save trained models with detailed info files 
    - Label Mapping Export - Export classification labels as CSV/JSON 
    - Progress Tracking & Error Handling - Seamless QGIS Integration 

    This plugin is ideal for remote sensing professionals, GIS analysts, and researchers looking to perform efficient and accurate supervised classification of satellite imagery within the QGIS environment. 

    To use this Tool, follow the steps below: 
    1. Click on the tool or choose "Raster" menu --> "MAS** Raster Processing" menu item --> "Supervised Classifier" option. 
    2. Select 'Stack Image' or Image as Input and select the output folder name. 
    3. Select classification method. 
    4. Adjust all parameters according to your needs. Select the field of the Reference Shapefile that has the labels for the classification and check mark on "Want to save the trained model?"  
    If you want to save the trained model (except the "Minimum Distance" model). Select the "No of Iterations:" to train the model (except the "Minimum Distance" model). 
    5. Decide do you want to open the output or not. 
    6. Click on the "Classify" button.  

    Follow the steps below for Version >= 1.0.0: 
    **Training New Model Mode:** 
    1. Open the tool: Raster menu → "MAS Raster Processing" → "Supervised Classifier" 
    2. Keep "Do you want to use a pre-trained model?" unchecked 
    3. Select input rasters from the table or add new ones using "Add Raster from File" 
    4. Select reference shapefiles and choose label fields using the "Select Label Fields" button 
    5. Choose output folder (or check "Save output in same folder as input?") 
    6. Select classification method (Random Forest, SVM, KNN, or Minimum Distance) 
    7. Check "Wants to save trained model?" to save the model for future use 
    8. Set "No of Iterations" for training (except Minimum Distance) 
    9. Optionally check "Do you want to open output in QGIS Interface?" 
    10. Click the "Classify" button 
    11. View label mappings dialog and export if needed  

    **Pre-trained Model Mode:**  
    1. Open the tool and check "Do you want to use a pre-trained model?" 
    2. Select input rasters from the table 
    3. Add pre-trained model files (.pkl) using the "Add Model from File" button 
    4. If multiple models are selected, confirm the warning about the total output files 
    5. Choose output folder 
    6. Optionally check "Do you want to open output in QGIS Interface?" 
    7. Click the "Classify" button 
    8. Check model info files for label mapping details 

    **Note: After installation, make sure the following points; 
    1. Check the Installed plugins (under 'Manage and Install Plugins...' menu). 
    2. Check Mark 'MAS Raster Processing' toolbar (by right-clicking on the toolbar). 
    3. Issues (please take a look): 
    [ModuleNotFoundError: No module named 'sklearn' #1](https://github.com/Mirjan-Ali-Sha/supervised_classifier/issues/1)

    For more details, please visit 'homepage'.
    ** MAS refer to my name "Mirjan Ali Sha".

tracker=https://github.com/Mirjan-Ali-Sha/supervised_classifier/issues
repository=https://github.com/Mirjan-Ali-Sha/supervised_classifier
# End of mandatory metadata

# Recommended items:

hasProcessingProvider=no
changelog=
    1.0.6 (January 2025)
    - NEW: Gradient Boosting Classifier - powerful sequential ensemble method
    - NEW: Accuracy Assessment Dialog with Confusion Matrix, Kappa, Precision/Recall/F1
    - NEW: Feature Importance display for RF, Gradient Boosting, and LDA
    - NEW: Export training samples as CSV for external analysis
    - NEW: Import training samples from CSV (use pre-extracted training data)
    - NEW: Multi-raster sample collection - extract samples from overlapping/adjacent rasters
    - NEW: CRS Analysis Dialog - detailed table showing all input CRS with suggestions
    - NEW: CRS validation - warns if raster and reference have different projections
    - NEW: Training balance check - warns about class imbalance
    - UI: Added tooltips to all UI elements with algorithm descriptions
    - UI: New checkboxes for accuracy assessment, CSV export, and multi-raster options
    - IMPROVED: Better organized code with analysis_utils.py module
    
    1.0.3 (December 2025)
    - PERFORMANCE: Optimized raster reading (10x+ faster classification)
    - NEW: Maximum Likelihood classification using GaussianNB
    - NEW: LDA (Linear Discriminant Analysis) classifier
    - NEW: QDA (Quadratic Discriminant Analysis) classifier
    - IMPROVED: KNN with optimized parameters (n_neighbors=5, distance-weighted)
    - IMPROVED: Random Forest now uses parallel processing
    - UI: Reduced dialog size for compactness (700x600)
    - UI: Improved layer names in QGIS (uses filename instead of generic name)
    - UI: Shorter output filenames with method abbreviations (RF, SVM, MaxLik, etc.)
    - Added robust dependency installer with automatic Python detection
    - Hot-reload: Plugin works immediately after installing dependencies (no QGIS restart needed)
    - Fixed "Invalid Data Source" error when installing packages on Windows
    - Improved error handling and logging for dependency installation
    
    1.0.2 (December 2025)
    - Added robust dependency installer with automatic Python detection
    - Fixed "Invalid Data Source" error when installing packages on Windows
    - Improved error handling and logging for dependency installation
    
    1.0.1 (November 2025)
    - Bug fixes and stability improvements
    - Improved UI/UX
    - Supporting Multiple label columns
    - Support Batch Processing
    
    1.0.0 (October 2025)
    - Initial release with batch processing
    - Pre-trained model support
    - Multiple classification algorithms

# Tags are comma separated with spaces allowed
tags=remote sensing, raster, processing, image classification, supervised classification, supervised, classification, image classification, Random Forest, SVM, KNN, Minimum Distance, Maximum Likelihood, LDA, QDA

homepage=https://github.com/Mirjan-Ali-Sha/supervised_classifier/wiki
category=Raster
icon=icon.png
# experimental flag
experimental=False

# deprecated flag (applies to the whole plugin, not just a single version)
deprecated=False

# Since QGIS 3.8, a comma separated list of plugins to be installed
# (or upgraded) can be specified.
# Check the documentation for more information.
# plugin_dependencies=

# Category of the plugin: Raster, Vector, Database or Web
# category=

# If the plugin can run on QGIS Server.
server=False
