# Segment-Based Clustering of Hyperspectral Images Using Tree-Based Data Partitioning Structures
The segmentation map is combined with the pixel-level classification results by using majority voting, such that, for each segment of the segmentation map, the majority class is found in the pixel-level classification map and all of the pixels within that segment are assigned to that majority class. A similar approach is proposed in [19], where k-means clustering is applied to the hyperspectral image in order to obtain an initial cluster map, which is then converted to a segmented map while using CCL. The segmented map is further refined by using a region merging method in which similar regions in the map are merged by using their shape and spectral properties according to a merging criterion. In the next stage, a projected clustering is performed over segments instead of pixels. Further, the clustering makes use of the local band selection approach for identifying a relevant subset of bands for each cluster. An approach that incorporates local band selection [7] starts by converting the k-means obtained cluster map from the first stage into a segmentation map while using CCL. This map is then converted to cluster map by considering each segment as a cluster. For performing clustering, a different two-step projected clustering is used. In the first step, clustersare merged, depending on their mutual nearest neighbour (MNN) information calculated using the spectral space. The next step identifies the \(k\) significant clusters while using an entropy-based criterion and produces the final cluster map by assigning all the remaining clusters to \(k\) significant clusters. These techniques commonly use a three-step scheme in order (i) HSI segmentation, (ii) region merging, and finally (iii) projected clustering for the HSI classification problem. It has been observed that segmentation using the k-means algorithm is the initial stage for the aforementioned frameworks. To the best of the authors' knowledge, no study has been conducted on other segmentation methods for HSI segment-based clustering. Hierarchical segmentation algorithms have proven to be valuable in exploiting the spatial content of HSI images by providing a hierarchy of segmentation stages at different scales [26]. HSI segmentation using the binary partition trees (BPT) proposed in [27] models the HSI data into regions that can be merged to form a binary tree representing the most dissimilar regions. The proposed framework is a four-stage scheme. The Watershed segmentation technique [28] is used in a pre-segmentation stage for obtaining initial over-segmented segments/regions. In this manner, creating large under-segmented regions is avoided, which can affect the performance and cause inaccurate region merging in the segmentation stage. The segmentation stage that is based on BPT representation [27] models each region by using a first-order parametric model [29]. The modeled regions are then merged in order to construct the BPT that is based on their spectral similarity by using the spectral angle mapper (SAM) [26]. In the subsequent stage, a number of the most dissimilar regions in BPT are selected, forming a meaningful HSI segmentation map. This produces a partitioning with the most distinguishable regions on the map. In a separate stage, PCA is applied to the original set of HSI pixels for feature extraction. As aforementioned, both hierarchical segmentation and dimensionality reduction methods have proven to be advantageous for extracting spatial and spectral information, respectively. In that sense, the contextual information from the segmentation stage and the extracted spectral features from PCA are combined as input of a tree-based partitioning k-means clustering method in order to improve the classification accuracy. The clustering is based on a pruning algorithm--the filtering algorithm [30]. This heuristic method optimizes the time complexity of the standard k-means algorithm from O(\(n^{2}\)) to O(\(n\)) [31].