Mit der Image Analyst-Lizenz verfügbar.
Zusammenfassung
Uses a change analysis raster to create a raster object containing date-of-change information.
The change analysis raster is generated with the Analyze Changes Using CCDC tool or the Analyze Changes Using LandTrendr tool.
Diskussion
For more information on how this function works, see the Detect Change Using Change Analysis raster function.
The referenced raster dataset for the raster object is temporary. To make it permanent, you can call the raster object's save method.
Syntax
DetectChangeUsingChangeAnalysis (raster, {change_type}, {max_number_of_changes}, {segment_date}, {change_direction}, {filter_by_year}, {min_year}, {max_year}, {filter_by_duration}, {min_duration}, {min_duration}, {filter_by_magnitude}, {min_magnitude}, {max_magnitude})
Parameter | Erläuterung | Datentyp |
raster | The input change analysis raster generated with the Analyze Changes Using CCDC tool or the Analyze Changes Using LandTrendr tool. | Raster |
change_type | Specifies the type of change to be extracted from the change analysis raster.
(Der Standardwert ist TIME_OF_LATEST_CHANGE) | String |
max_number_of_changes | The maximum number of changes per pixel to be calculated. This number corresponds to the number of bands in the output raster. The default is 1, meaning only one change date will be calculated, and the output raster will contain only one band. This parameter is not available when the change_type parameter is set to NUM_OF_CHANGES. (Der Standardwert ist 1) | Integer |
segment_date | Specifies whether to extract the date at the beginning of a change segment, or the end. This parameter is available only when the input change analysis raster is the output from the Analyze Changes Using LandTrendr tool.
(Der Standardwert ist BEGINNING_OF_SEGMENT) | String |
change_direction | Specifies the direction of change to be included in the analysis. This parameter is available only when the input change analysis raster is the output from the Analyze Changes Using LandTrendr tool.
(Der Standardwert ist ALL) | String |
filter_by_year | Specifies whether to filter by a range of years.
(Der Standardwert ist False) | Boolean |
min_year | The earliest year to use to filter results. This parameter is required if the filter_by_year parameter is set to True. (Der Standardwert ist 1970) | Double |
max_year | The latest year to use to filter results. This parameter is required if the filter_by_year parameter is set to True. (Der Standardwert ist 2020) | Double |
filter_by_duration | Specifies whether to filter by the duration of a change event.
(Der Standardwert ist False) | Boolean |
min_duration | The minimum number of consecutive years to include in the results. This parameter is required if the filter_by_duration parameter is set to True. (Der Standardwert ist 0) | Double |
min_duration | The maximum number of consecutive years to include in the results. This parameter is required if the filter_by_duration parameter is set to True. (Der Standardwert ist 50) | Double |
filter_by_magnitude | Specifies whether to filter by the magnitude of change.
(Der Standardwert ist False) | Boolean |
min_magnitude | The minimum change magnitude to include in the results. This parameter is required if the filter_by_magnitude parameter is set to True. (Der Standardwert ist -50) | Double |
max_magnitude | The maximum change magnitude to include in the results. This parameter is required if the filter_by_magnitude parameter is set to True. (Der Standardwert ist 50) | Double |
Datentyp | Erläuterung |
Raster | The raster object containing detected change information. |
Codebeispiel
Extracts the dates of change for the three largest changes from the change analysis raster.
import arcpy
from arcpy.ia import *
arcpy.CheckOutExtension("ImageAnalyst")
change_analysis_raster = arcpy.Raster('Landsat_CCDC.crf', True)
# Detect the dates of the three largest changes in pixel values over time
largest_change = arcpy.ia.DetectChangeUsingChangeAnalysis(
change_analysis_raster, "TIME_OF_LARGEST_CHANGE", 3)