SIGSEP

Signature separability


EnvironmentsPYTHON :: EASI :: MODELER
Quick linksDescription :: Parameters :: Parameter descriptions :: Details :: Examples :: Algorithm :: References :: Related

Back to top

Description


Prints a report of class signature separabilities among 2 to 256 classes. Separabilities can be calculated using either the Transformed Divergence or the Bhattacharyya (Jeffries-Matusita) Distance measure. The separability between two classes can be used to determine if the classes should be merged using SIGMERG.
Back to top

Parameters


sigsep(file, sepme, dsig, septhres, imstat, sigpair)

Name Type Caption Length Value range
FILE * str Input file name 1 -    
SEPME * str Separability measures 2 - 2 TD | BD
Default: BD
DSIG * List[int] Input class signature segments 2 - 256  
SEPTHRES List[float] Separability threshold 0 - 1  
IMSTAT List[float] Image statistics 0 - 3  
SIGPAIR List[int] Pair with lowest separability 0 - 2  

* Required parameter
Back to top

Parameter descriptions

FILE

Specifies the name of the PCIDSK image file that contains the signatures for which separabilities are to be calculated.

SEPME

Specifies the type of separability measure to use.

Available options are:

See the Details section for information about these measures.

DSIG

Specifies 2 to 256 signature segments for which separabilities are calculated.

Duplicate segments are NOT allowed. All segments must have been created using the same set of input channels.

SEPTHRES

Optionally specifies a separability threshold value for the report.

If this parameter is not specified (default), a matrix of separabilities for all class signature pairs is printed.

If this parameter is specified, separabilities for only those class signature pairs with separabilities less than the specified threshold are printed, one pair per line.

IMSTAT

Upon successful completion of SIGSEP, the IMSTAT parameter contains three values:

SIGPAIR

Upon successful completion of SIGSEP, this parameter contains the two segment numbers for the signature pair that has the lowest separability value. The values for this parameter can be input to SIGMERG, to merge the signature pair with the lowest separability.

Back to top

Details

SIGSEP calculates the separability between each pair of classes among 2 to 256 classes, and prints the results in a separability matrix. Class signature segments can be created using the CSG, KCLUS, or ISOCLUS functions. The purpose of SIGSEP is to determine whether some classes should be merged using SIGMERG. Pairs of classes with poor separability values should be merged before performing classification using MLC.

If a separability threshold (SEPTHRES) is specified, only those class signature pairs with a separability less than the defined threshold are printed. This is useful if a large number of signature segment are specified, and you want to list only those signatures which should be merged.

SIGSEP uses two class separability measures:

The Transformed Divergence (TD) measure is a popular empirical measure, which is computationally simpler than the Bhattacharyya Distance (BD) measure. The BD measure is more theoretically sound because it is directly related to the upper bound of the probabilities of classification errors.

Both TD and BD separability measures yield real values between 0 and 2, where 0 indicates complete overlap between the signatures of two classes, and 2 indicates a complete separation between the two classes. TD and BD measures are monotonically related to classification accuracies. The larger the separability values, the better the final classification results will be (using the MCL or MINDIS).

The following rules are suggested for each of the possible ranges of separability values 'x':

0.0 < x < 1.0   (very poor separability)
1.0 < x < 1.9   (poor separability)
1.9 < x < 2.0   (good separability)

Very poor separability (0.0 < x 1.0) indicates that the two signatures are statistically very close to each other. The user has two options. One signature can be arbitrarily discarded (which is suggested when the separability is closer to 0), or the two signatures can be merged using SIGMERG (which is suggested when the separability is closer to 1).

Poor separability (1.0 < x 1.9) indicates that the two signatures are separable, to some extent. It is desirable, however, to improve separability, if possible. Low signature separability is usually caused by improper combinations of image bands, and/or training sites that have large internal variability within each class.

You are encouraged to use this function to examine the quality of training sites (bitmaps) and class signatures, before running a classification routine. To improve class separabilities, consider the following options:
Back to top

Examples

Calculate the separabilities among the eight signature segments in the file irvine.pix.

from pci.sigsep import sigsep

file	=	"irvine.pix"	# input file with signature segments
sepme	=	"BD"	# Bhattacharyya Distance
dsig	=	list(range(17,25))	# input signature segments
septhres	=	[]	# print full separability matrix
imstat	=	[]
sigpair	=	[]

sigsep( file, sepme, dsig, septhres, imstat, sigpair )

SIGSEP produces the following report:


 Separability Measure:      Bhattacharyya Distance

 Signature Segments:   17, 18, 19, 20, 21, 22, 23, 24

 Signature Channels:    1,  2,  3,  4,  5

 Average Separability:     1.92329
 Minimum Separability:     1.56423
 Maximum Separability:     2.00000

 Signature Pair with Minimum Separability:  ( 19, 20)
 
 Separability Matrix: 

            17       18       19       20       21       22       23
    +---------------------------------------------------------------
  18|  1.98926
  19|  1.99157  1.99809
  20|  1.96260  1.99909  1.56423
  21|  1.99893  1.99997  1.94144  1.61048
  22|  1.99886  1.99995  1.82657  1.79037  1.99996
  23|  2.00000  2.00000  1.92785  1.88498  1.99993  1.99573
  24|  1.97660  1.99999  1.83575  1.65615  1.90780  1.99744  1.99866

Now, print only separabilities among the eight signature segments that are less than 1.9:

from pci.sigsep import sigsep

file	=	"irvine.pix"	# input file with signature segments
sepme	=	"BD"	# Bhattacharyya Distance
dsig	=	list(range(17,25))	# input signature segments
septhres	=	[1.9]	# print separabilities less than 1.9
imstat	=	[]
sigpair	=	[]

sigsep( file, sepme, dsig, septhres, imstat, sigpair )
        

SIGSEP produces the following report:

 Separability Measure:      Bhattacharyya Distance

 Signature Segments:   17, 18, 19, 20, 21, 22, 23, 24

 Signature Channels:    1,  2,  3,  4,  5

 Average Separability:     1.92329
 Minimum Separability:     1.56423
 Maximum Separability:     2.00000

 Signature Pair with Minimum Separability:  ( 19, 20)
 
 Separability Threshold:   1.90000
 
 Segments Separability   Segments Separability   Segments Separability
 
 ( 19, 20)  1.56423      ( 20, 21)  1.61048      ( 19, 22)  1.82657
 ( 20, 22)  1.79037      ( 20, 23)  1.88498      ( 19, 24)  1.83575
 ( 20, 24)  1.65615
 
 Number of segment pairs listed:     7

As shown above, the average separability is 1.92329, which indicates that the overall separability among the eight signatures is relatively good. Efforts should be made to improve the separability among signature pairs. After SIGSEP completes, the SIGPAIR parameter contains the segment numbers for the signature pair with the poorest separability; in this case, segments 19 and 20. Signature merging using SIGMERG should be considered.

If SIGSEP is run using only two signatures, the minimum, maximum, and average separabilities are the same.

Back to top

Algorithm

To determine the separability between a pair of class signatures, two criteria, Transformed Divergence (TD) and Bhattacharyya Distance (BD), are used. They are calculated from class means and covariance matrices as follows:

 TD Measure
 __________

  TD(i,j) = 2*[1-exp(-D(i,j)/8)]
where:
where:
 BD Measure
 __________

  BD(i,j) = 2*[1-exp(-a(i,j))]
where:
where:

SIGSEP calculates the separabilities of all the possible pairs among 'n' classes, where 'n' is the number of classes.

Back to top

References

Richards, J. A. (1986). Remote Sensing Digital Image Analysis. Springer-Verlag. New York. pp. 206-225.

Note: The formula to calculate the Bhattacharyya Distance measure given in the above book is incorrect. Check the reference in the book to find the correct formula.

© PCI Geomatics Enterprises, Inc.®, 2026. All rights reserved.