Published March 15, 2022 | Version 1.0
Software Open

k-textures, a self-supervised hard clustering deep learning algorithm for satellite image segmentation

  • 1. UCLA/JPL-NASA

Description

In the dataset, you will find the codes of k-textures algorithm which provides self supervised segmentation of a 4-band image (RGB-NIR) for a k number of classes. An example of its application on high resolution Planet satellite imagery is given. Our algorithm shows that discrete search is feasible using convolutional neural networks (CNN) and gradient descent. The model detects k hard clustering classes represented in the model as k discrete binary masks and their associated k independently generated textures, that combined are a simulation of the original image. The similarity loss is the mean squared error between the features of the original and the simulated image, both extracted from the penultimate convolutional block of Keras 'imagenet' pretrained VGG-16 model and a custom feature extractor made with Planet data. The main advances of the k-textures model are: first, the k discrete binary masks are obtained inside the model using gradient descent. The model allows for the generation of discrete binary masks using a novel method using a hard sigmoid activation function. Second, it provides hard clustering classes -- each pixels has only one class.

Our approach is designed to ease the production of training samples for image segmentation model, for medium to high spatial resolution satellite imagery. 

-----------------------------------------------------------------------------------------------------------------------------

This model package contains : 

1 - the R codes for Windows of the k-textures model from the article « k-textures, a self supervised hard clustering deep learning algorithm for satellite images segmentation » 

2 - the R codes for Windows to prepare the inputs for the k-textures model from an original PlanetScope image quad with GDAL (note that all the data are already given in the model package, but this code enable to reproduce the data)

When using this dataset, please cite the original article : "k-textures, a self supervised hard clustering deep learning algorithm for satellite images segmentation"

------------------------------------------------------------------------------------------------------------------------------

To run the model, it is assumed that you have a computer with GPU sufficient to run deep learning models (CUDA compute capacity >3.0), and Rstudio with the package keras already working (https://keras.rstudio.com/). The model was run with the following libraries: Python 3.9.12, RStudio Version 1.3.959, R version 4.0.2 (2020-06-22), R keras package version 2.8, Tensorflow version 2.8, Nvidia GeForce RTX 2080 (driver 471.11, CUDA 11.4 and cuDNN version 8.2.4.15).

------------------------------------------------------------------------------------------------------------------------------

To use the model with 3 band images, you just need to set a fourth band with a constant value.

Files

k-textures_Planet_Zenodo.zip

Files (406.3 MB)

Name Size Download all
md5:f42e9d276d8d9f9ad7f0558b0284947a
406.3 MB Preview Download