- URL:
- https://<rasteranalysistools-url>/DetectImageAnomalies
- Methods:
GET- Version Introduced:
- 12.1
Description
The Detect task processes a multiband or hyperspectral image and creates an anomaly score raster. An anomaly score raster is a single band raster, with values between 0 and 1.
Request parameters
| Parameter | Details |
|---|---|
(Required) | A multiband or hyperspectral image. The input raster can be the portal item ID, image service URL, cloud raster dataset, or shared raster dataset. Syntax: JSON object describing the input raster(s). Example |
(Required) | Output hosted image service properties. If the hosted image service is already created, the portal item ID or service URL can be given to the service tool. The output path of the raster dataset generated in the raster store will be used to update the existing service definition. The service tool can also generate new hosted image service with the given service properties. The output hosted image service is stored in a raster store and shared on either the Raster Analysis Image Server or Image Hosting Image Server depending on the Enterprise configuration. Syntax: JSON object describes the output raster. Example At least one type of input needs to be provided in the JSON object. If multiple inputs are given, the |
(Optional) | Specifies the anomaly calculation method that will be used. The Values: |
(Required if | The number of clusters that will be used. This parameter is not used for the other methods. Syntax: long Example |
(Optional) | A polygon feature layer that defines the region to be used to calculate background statistics when the Syntax: This parameter can be specified as a URL to a feature service layer Example |
(Optional) | Specifies whether statistics will be recomputed for the output score raster when the Values: |
| Contains additional settings that affect task execution. This task has the following settings:
|
Example
The following is a sample request for URL for Detect:
https://organization.example.com/server/rest/services/System/RasterAnalysisTools/GPServer/DetectImageAnomalies?inputRaster={"url": "<xxx/ImageServer>"}&outputName={"serviceProperties":{"name":"<output_name>"}}&method=RXD&backgroundRegion={"url": "<xxx/FeatureServer/0>"}&recomputeStats=true&context={}&f=jsonResponse
When you submit a request, the service assigns a unique job ID for the transaction.
Syntax:
{
"jobId": "<unique job identifier>",
"jobStatus": "<job status>"
}After the initial request is submitted you can use the jobId to periodically check the status of the job and messages as described in the topic Checking job status. Once the job has successfully completed, you use the jobId to retrieve the results. To track the status, you can make a request of the following form:
https://<analysis url>/DetectImageAnomalies/jobs/<jobId>Accessing results:
When the status of the job request is esri, you can access the results of the analysis by making a request of the following form.
Status check URL:
https://<analysis url>/DetectImageAnomalies/jobs/<jobId>Result retrieval URL once job succeeds:
https://<analysis url>/DetectImageAnomalies/jobs/<jobId>/results/outputRaster?token=<token>&f=json