Unsupervised Classification
User Guide & Scientific Theory

Unsupervised Classification groups pixels automatically according to similarity in their spectral or raster values. It is useful when training samples are unavailable, when the analyst wants to explore natural spectral groupings, or when an initial land-cover segmentation is needed before manual interpretation.

K-Means ISODATA SOM GMM Fuzzy C-Means BIRCH Cloud Processing

1. Overview

The Unsupervised Classification feature in iTSensing Cloud provides six clustering methods: K-Means, ISODATA, Self-Organizing Map (SOM), Gaussian Mixture Model (GMM), Fuzzy C-Means, and BIRCH. All methods analyze the numeric pattern of selected raster bands and produce a thematic raster containing cluster IDs.

No training labelsWorks without labelled samples
Multiband rasterUses spectral or feature bands
2–255 classesConfigurable cluster count
1 class rasterFinal thematic output
Core idea: pixels with similar multi-band values are grouped together. The software does not initially know whether a group represents forest, water, urban area, bare soil, crop, cloud, or another surface type. Interpretation is performed after clustering.

2. When to Use Unsupervised Classification

Exploratory mapping

Useful when you want to discover natural spectral groups in a new image before defining final thematic classes.

No training data

Useful when field samples, labelled polygons, or reference classes are not yet available.

Initial land-cover segmentation

Clusters can later be interpreted, merged, or used to help prepare training samples for supervised classification.

Material or spectral grouping

Useful for multispectral, hyperspectral, geological, vegetation, water, or other continuous raster feature spaces.

Unsupervised Classification does not automatically produce scientifically named land-cover classes. A cluster map must still be interpreted and validated.

3. Typical Workflow

Analysis-ready Raster ↓ Select useful bands ↓ Optional predictor standardization ↓ Choose clustering method ↓ Set number of classes / method parameters ↓ Run classification ↓ Cluster raster ↓ Interpret clusters ↓ Merge / rename / validate thematic classes

3.1 Example

Sentinel-2 Surface Reflectance
B2 + B3 + B4 + B8 + B11 + B12
      ↓
K-Means
8 classes
      ↓
Cluster 1...8
      ↓
Visual interpretation
      ↓
Water / Dense Vegetation / Sparse Vegetation /
Bare Soil / Built-up / etc.

4. Input Data

4.1 Multiband raster

Each pixel is represented by a vector containing the selected band values:

x = [x1, x2, …, xB] B is the number of selected predictor bands.

For example:

Sentinel-2 pixel:
[B2, B3, B4, B8, B11, B12]

Hyperspectral pixel:
[MNF1, MNF2, MNF3, ..., MNF15]

Feature stack:
[Red, NIR, SWIR, NDVI, Texture, Elevation]

4.2 Band selection

Choose bands that are relevant to the target phenomenon. Leaving all bands selected is convenient, but unnecessary or noisy bands can reduce clustering quality.

4.3 Surface Reflectance is preferable for optical analysis

For multispectral land-cover analysis, Surface Reflectance generally provides more physically comparable spectral values than raw digital numbers. Atmospheric or radiometric preprocessing should be completed before classification when required by the source image.

5. Common Settings

SettingPurposeTypical Recommendation
Classification AlgorithmSelects the clustering method.Start with K-Means if unsure.
Predictor BandsDefines which raster bands/features are used.Select informative bands; leave empty to use all bands.
Number of ClassesRequested number of spectral groups.Usually larger than the final desired thematic classes.
Training Pixel SampleMaximum number of pixels used to learn cluster structure.Increase for heterogeneous large areas if needed.
Standardize Predictor BandsPuts variables onto comparable numeric scales.Keep enabled unless all predictors already have comparable scale.
Random StateControls repeatability of randomized steps.Keep unchanged when comparing parameter settings.

5.1 Standardization

z = (x − μ) / σ

Standardization centers each predictor around zero and scales it by its standard deviation. This prevents variables with large numeric ranges from dominating distance calculations.

Example: a reflectance band ranging from 0–1 and an elevation raster ranging from 0–3000 m should usually be standardized before distance-based clustering.

6. K-Means

K-Means is the simplest and often the fastest general-purpose method. It divides pixels into a fixed number of clusters by minimizing distance from pixels to their assigned cluster center.

6.1 Objective function

J = Σi=1…N ||xi − μc(i)||²

The algorithm repeatedly:

  1. assigns each sample to the nearest cluster center;
  2. updates each center from the mean of its assigned samples;
  3. continues until centers become stable or the iteration limit is reached.

6.2 Assignment

c(i) = arg mink ||xi − μk||²

6.3 Cluster center

μk = 1/|Ck| Σxᵢ∈Cₖxi

6.4 Main settings

  • Number of Classes
  • Mini-Batch Size
  • Maximum Iterations
  • Number of Initializations
Use K-Means when: you need a fast baseline, the approximate number of groups is known, and the spectral clusters are reasonably compact.

7. ISODATA

ISODATA extends centroid-based clustering by allowing clusters to be removed, merged, and split. The final number of clusters may therefore differ from the initial number.

7.1 Basic assignment

c(i) = arg mink ||xi − μk||²

7.2 Cluster merging

If two centers are very close:

d(μi, μj) < Tmerge

they can be combined into one cluster.

7.3 Cluster splitting

A cluster with high internal variability can be divided into two groups. A practical split criterion uses the largest standard deviation among predictor dimensions:

max(σ1, σ2, …, σB) > Tsplit

7.4 Key settings

  • Initial Number of Classes
  • Minimum Classes
  • Maximum Classes
  • Minimum Pixels per Cluster
  • Merge Distance Threshold
  • Split Standard Deviation Threshold
  • Maximum Iterations
  • Convergence Tolerance
Use ISODATA when: the natural number of spectral groups is uncertain and you want the clustering process to adapt automatically.

8. Self-Organizing Map (SOM)

A Self-Organizing Map is a neural clustering method that learns a low-dimensional grid of representative spectral vectors. It is useful for exploring complex spectral structures while preserving neighborhood relationships among learned patterns.

8.1 Best Matching Unit

BMU(x) = arg minj ||x − wj||²

8.2 Neighborhood function

hbj = exp[-dgrid(b,j)² / (2σ²)]

8.3 Weight update

wj(t+1) = wj(t) + α(t) hbj(t) [x − wj(t)]

During training, both learning rate α and neighborhood radius σ gradually decrease. The map first learns broad spectral organization, then fine local structure.

8.4 Main settings

  • SOM Grid Rows
  • SOM Grid Columns
  • Epochs
  • Initial Learning Rate
  • Initial Neighborhood Sigma
  • Mini-Batch Size
  • Requested Output Classes
Use SOM when: spectral relationships are complex and you want a topology-oriented representation before final grouping.

9. Gaussian Mixture Model (GMM)

GMM represents the data as a mixture of multiple multivariate Gaussian distributions. Unlike K-Means, clusters can have different spreads, orientations, and covariance structures.

9.1 Probability model

p(x) = Σk=1…K πk 𝒩(x | μk, Σk)

9.2 Multivariate Gaussian

𝒩(x|μ,Σ) = 1 / [(2π)B/2|Σ|1/2] · exp[-½(x−μ)TΣ−1(x−μ)]

9.3 Posterior probability

P(k|x) = πk𝒩(x|μkk) / Σjπj𝒩(x|μjj)

9.4 Covariance options

TypeMeaning
FullEach class may have its own complete covariance matrix.
TiedAll classes share one covariance matrix.
DiagonalOnly per-band variances are modeled.
SphericalEach cluster uses one variance value.
Use GMM when: class distributions overlap or are not approximately spherical in feature space.

10. Fuzzy C-Means

Fuzzy C-Means does not force a pixel to belong completely to only one cluster during model fitting. Instead, every sample receives a membership degree for each cluster.

10.1 Membership

uik = 1 / Σj=1…K (dik/dij)2/(m−1)

10.2 Cluster center

ck = Σiuikmxi / Σiuikm

10.3 Objective

Jm = ΣiΣk uikm ||xi − ck||²

10.4 Fuzziness parameter

The value m controls how soft the membership is. Values closer to 1 produce harder clusters; larger values produce more gradual membership. A common default is m = 2.

Use Fuzzy C-Means when: boundaries between materials or land-cover types are gradual, such as mixed vegetation, soil moisture transitions, shallow water, or mixed spectral pixels.

11. BIRCH

BIRCH — Balanced Iterative Reducing and Clustering using Hierarchies — is designed for efficient clustering of large datasets. Instead of repeatedly storing every observation, it creates compact clustering summaries in a tree structure.

11.1 Clustering Feature

CF = (N, LS, SS)
LS = Σxi
SS = Σxi²

11.2 Cluster centroid

μ = LS / N

11.3 Main settings

  • Threshold
  • Branching Factor
  • Number of Classes

A smaller threshold generally creates more compact subclusters. The branching factor controls how many clustering summaries can be stored in tree nodes before the hierarchy expands.

Use BIRCH when: you want efficient hierarchical clustering behavior for large feature samples.

12. Method Comparison

MethodMain ConceptFixed Number of Classes?Best Strength
K-MeansNearest centroidYesFast and simple baseline
ISODATAAdaptive centroid clusteringNo, within min/max limitsAutomatic split/merge
SOMTopology-preserving neural mapFinal grouping uses requested countComplex spectral organization
GMMGaussian probability distributionsYesElliptical/overlapping clusters
Fuzzy C-MeansSoft membership to every clusterYesMixed pixels / gradual boundaries
BIRCHHierarchical clustering featuresYesLarge datasets / efficient summarization

13. Which Method Should I Choose?

Your GoalRecommended First Choice
Fast general land-cover explorationK-Means
Unknown natural number of clustersISODATA
Complex spectral topologySOM
Overlapping statistical distributionsGMM
Mixed pixels / soft transitionsFuzzy C-Means
Very large feature samplesBIRCH
There is no universally best algorithm. For most users, K-Means is the best starting point, followed by ISODATA or GMM when the scene structure requires more flexibility.

14. Understanding the Output

The result is a single thematic raster containing cluster IDs.

0 = NoData
1 = Cluster 1
2 = Cluster 2
3 = Cluster 3
...
K = Cluster K

14.1 Cluster numbers are arbitrary

Cluster 1 in one run does not necessarily represent the same land-cover type as Cluster 1 in another run. Always interpret the cluster using the image, spectral values, reference data, and spatial context.

14.2 Typical post-processing

  • change class colors;
  • inspect cluster area/statistics;
  • compare with RGB or false-color imagery;
  • merge spectrally similar clusters;
  • assign semantic names;
  • apply majority filtering if required;
  • validate against reference samples.

15. Remote Sensing Guidance

15.1 Optical imagery

Use analysis-ready reflectance products whenever possible. Clouds, cloud shadows, snow, haze, or sensor artifacts can become artificial clusters if not masked.

15.2 Multispectral imagery

Good predictor combinations often include visible, NIR, and SWIR bands. For Sentinel-2, a typical set may include B2, B3, B4, B8, B11, and B12.

15.3 Hyperspectral imagery

A hyperspectral image can contain hundreds of correlated bands. Dimensionality reduction such as MNF can be useful before clustering.

Hyperspectral Surface Reflectance ↓ Bad-band removal ↓ Spectral smoothing ↓ MNF ↓ K-Means / ISODATA / GMM / SOM ↓ Spectral cluster map

15.4 Additional raster features

Indices, texture, elevation, slope, or other predictors can be stacked with spectral bands before clustering if they are scientifically relevant.

16. Example Workflows

16.1 Agriculture

Sentinel-2 Surface Reflectance
      ↓
Cloud Mask
      ↓
B3, B4, B8, B11
      ↓
K-Means
10 classes
      ↓
Interpret crop, soil, water, vegetation vigor groups

16.2 Forest mapping

Reflectance + NDVI + SWIR
      ↓
ISODATA
Initial = 8
Minimum = 4
Maximum = 14
      ↓
Adaptive spectral groups
      ↓
Merge into forest / degraded forest /
open land / water / other

16.3 Coastal water

Visible + Red Edge + NIR water predictors
      ↓
Fuzzy C-Means
      ↓
Clusters representing gradual transitions
between clearer, turbid, sediment-rich, or mixed water

16.4 Hyperspectral minerals

Surface Reflectance
      ↓
Continuum / MNF preprocessing
      ↓
GMM
      ↓
Spectral groups
      ↓
Compare clusters with spectral library
or use them to define further analysis regions

17. Limitations

  • Clusters are spectral/statistical groups, not automatic semantic classes.
  • Results depend strongly on selected bands and preprocessing quality.
  • Different class counts can produce very different maps.
  • Random initialization may affect cluster numbering and boundaries.
  • Clouds and shadows can form unintended clusters.
  • Pixel-based clustering can create salt-and-pepper patterns.
  • Unsupervised results should not be treated as validated land-cover maps without interpretation and accuracy assessment.
  • Fuzzy or probabilistic algorithms may internally model ambiguity, while the displayed thematic result is still interpreted as a class map.

18. Best Practices

  1. Start from good preprocessing. Use calibrated/reflectance imagery and mask invalid pixels.
  2. Select useful bands. Avoid unnecessary noisy or redundant predictors.
  3. Keep standardization enabled when predictors have different numeric scales.
  4. Use more clusters than final thematic classes. For example, start with 8–15 spectral clusters for a final 4–7 class land-cover map.
  5. Compare several methods. K-Means is a useful baseline; ISODATA or GMM may better represent complex scenes.
  6. Interpret clusters with imagery. Use RGB, false color, indices, spectral profiles, or field knowledge.
  7. Merge clusters only after interpretation.
  8. Validate the final thematic map. If final classes matter scientifically, perform an accuracy assessment using independent reference samples.
Recommended starting configuration for many users: Surface Reflectance → selected visible/NIR/SWIR bands → Standardize = On → K-Means → 8–12 classes → interpret and merge.