You can use this model in the Classify Pixels Using Deep Learning tool available in the Image Analyst toolbox in ArcGIS Pro. Follow the steps below to use the model for classifying mangroves in images.
Supported imagery
This model can be used with Surface Reflectance (Collection 2 Level-2) imagery acquired by the Landsat 8 sensor in the form of a raster, mosaic dataset, or image service.
When using a raster product, ensure that you choose the Surface Reflectance product while adding the imagery to your map. When using a mosaic dataset, ensure that you choose the Landsat 8 raster type and Surface Reflectance processing template while creating the mosaic. This mosaic dataset can also be published as an image service and used as an input.
Ensure that the bit depth of the input is 16 Bit Unsigned, and that the processing template is set to None. You can automate creation, configuration, and population of your mosaic datasets using Mosaic Dataset Configuration Script (MDCS).
Classify mangroves
Complete the following steps to classify mangroves:
- Prepare data according to the following product type:
- Raster Product
- Browse to the folder housing the Landsat 8 Collection 2 data. Expand the folder and locate the raster product.
- Expand the Raster Product provided as an MTL.txt file and select the Surface Reflectance derived raster dataset.
- Mosaic Dataset
- Create a Mosaic Dataset using the Create Mosaic Dataset geoprocessing tool. Set the variables on the Parameters tab as follows:
- Output Location—Select a geodatabase.
- Mosaic Dataset Name—Set the mosaic dataset name.
- Coordinate System—Select a coordinate system for the output mosaic dataset.
- Product Definition—Select None.
- To add the raster to the mosaic dataset, open the Add Rasters To Mosaic Dataset geoprocessing tool. Set the variables on the Parameters tab as follows:
- Mosaic Dataset—Select the input mosaic dataset.
- Raster Type—Select Landsat 8 from the drop-down list.
- Processing Templates—Select Surface Reflectance from the drop-down list.
- Input Data—Select Folder from the drop-down list, browse and add the Landsat 8 data folder.
- Raster Dataset
- Traditionally Landsat 8 Collection 2 data is provided as a series of .tif dataset with a .txt metadata file required for use as a raster product. If this metadata distribution is not available, you can create a multiband image through either the Composite Bands geoprocessing tool or Composite Bands raster function. This can be used as input for inferencing.
- Download the Mangrove Classification (Landsat 8) model and add the imagery layer in ArcGIS Pro.
- Zoom to an area of interest.
- Browse to Tools on the Analysis tab.
- Click the Toolboxes tab in the Geoprocessing pane, select Image Analyst Tools, and browse to the Classify Pixels Using Deep Learning tool under Deep Learning.
- Set the variables on the Parameters tab as follows:
- Input Raster—Select the imagery.
- Output Classified Raster—Set the output raster that will contain the classification results.
- Model Definition—Select the pretrained or fine-tuned model .dlpk file.
- Arguments (optional)—Change the values of the arguments if
required.
- padding—Number of pixels at the border of image tiles from which predictions are blended for adjacent tiles. Increase its value to smooth the output while reducing edge artifacts. The maximum value of the padding can be half of the tile size value.
- batch_size—Number of image tiles processed in each step of the model inference. This depends on the memory of your graphics card.
- predict_background—If set to True, background class is also classified.
- test_time_augmentation—Performs test time augmentation while predicting. If True, predictions of flipped and rotated variants of the input image are merged into the final output.
- tile_size—The width and height of image tiles into which the imagery is split for prediction.
Note:
To access the model directly from ArcGIS Pro (supported in ArcGIS Pro 2.7 and later), click the browse button and search for the model.
- Set the variables on the Environments tab as follows:
- Processing Extent—Select Current Display Extent or any other option from the drop-down menu.
- Cell Size (required)—Set the value to 30.
The expected raster resolution is 30 meters.
- Processor Type—Select CPU or GPU.
It is recommended that you select GPU, if available, and set GPU ID to the GPU to be used.
- Click Run.
The output layer is added to the map.