- URL:https://<rasteranalysistools-url>/DeriveContinuousFlow
- Version Introduced:11.0
Description
The DeriveContinuousFlow task generates a raster of accumulated flow into each cell from an input surface raster with no prior sink or depression filling required.
Example applications of DeriveContinuousFlow include the following:
- Determine flow accumulation from a surface raster without prior sink or depression filling required.
- Specify sink or depression cell locations through the inputDepressionsData parameter and determine flow accumulation at each cell of the surface raster, allowing water flow into depression locations but not outward.
Request parameters
Parameter | Details |
---|---|
inputSurfaceRaster (Required) | The input raster representing a surface. Syntax: This parameter can be specified as a portal item ID, a URL to a raster image service layer, a cloud raster dataset, or a shared raster dataset. Examples:
|
outputFlowAccumulationRasterName (Required) | The output flow accumulation image service name that will be created. You can specify the name, or you can create an empty service using Portal Admin Sharing API and use the return JSON object as input to this parameter. Syntax: A JSON object describes the name of the output or the output raster. Output name example:
Output raster examples:
|
inputDepressionsData | An optional dataset that defines real depressions. The depressions can be defined through a raster or a feature layer. If the input is a raster, the depression cells must take a valid value, including zero, and the areas that are not depressions must be NoData. Raster input example:
Feature input examples:
|
inputWeightRaster | An optional input raster dataset that defines the fraction of flow that contributes to flow accumulation at each cell. The weight is only applied to the accumulation of flow. If no accumulation weight raster is specified, a default weight of 1 will be applied to each cell. Example:
|
outputFlowDirectionRasterName | The output flow direction image service name that will be created. This parameter is optional and can be left blank. You can specify the name, or you can create an empty service using Portal Admin Sharing API and use the return JSON object as input to this parameter. Syntax: A JSON object describes the name of the output or the output raster. Output name example:
Output raster examples:
|
flowDirectionType | Specifies the flow direction type to use. Syntax: A string describing the flow direction type, which can be one of the following:
|
forceFlow | Specifies whether edge cells will always flow outward or follow normal flow rules. Syntax: A Boolean value as either false or true.
|
context | Contains additional settings that affect task processing. This task has the following settings:
|
f | The response format. The default response format is html. Values: html | json | pjson |
Flow direction type additional information
The following section contains details on the available flow direction methods in the flowDirectionType parameter.
The DeriveContinuousFlow task supports the D8 and multiple flow direction (MFD) modeling algorithms.
- When the D8 option is specified for flowDirectionType, flow can take a single direction, which is toward the steepest drop. The steepest drop is calculated by taking the difference in z-value divided by the path length between cell centers (1 for cardinal cells and the square root of 2 for diagonal cells) (Jenson and Domingue, 1988). The output raster takes only integer values from 1 to 255. The values from the center of each direction are specified in the following diagram: If a cell has the same change in z-value in multiple directions, the D8 flow direction is undefined. In this case, the value for such cell in the output flow direction raster will be the sum of the possible directions.
- When the MFD option is specified for flowDirectionType, flow is partitioned across all downslope neighbors. Flow partition across neighboring cells (as a fraction) is estimated as a function of maximum slope gradient, which considers local terrain conditions (Qin et al., 2007). The optional output flow direction raster takes only integer values showing the predominant flow direction (toward the cell that receives the largest fraction of flow according to the partition scheme) for ease of interpretation. However, the output flow accumulation raster reflects the flow partition scheme.
Response
When you submit a request, the task assigns a unique job ID for the transaction.
{
"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 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://<raster analysis tools url>/DeriveContinuousFlow/jobs/<jobId>
When the status of the job request is esriJobSucceeded, you can access the results of the analysis by making a request of the following form:
https://<raster analysis tools url>/DeriveContinuousFlow/jobs/<jobId>/results/<output parameter>
Example usage
Below is a sample request URL for DeriveContinuousFlow.
https://services.myserver.com/arcgis/rest/services/System/RasterAnalysisTools/GPServer/DeriveContinuousFlow/submitJob
JSON Response example
The response returns the outputFlowAccumulationRaster and outputFlowDirectionRaster output parameters, which have properties for parameter name, data type, and value. The content of value is the output raster dataset itemId and the image service URL.
{
"paramName": "outputFlowAccumulationRaster",
"dataType": "GPString",
"value": {
"itemId": "f121390b85ef419790479fc75b493efd",
"url": "https://<server name>/arcgis/rest/services/Hosted/<service name>/ImageServer"
}
}
References
Jenson, S. K., and Domingue, J. O. 1988. "Extracting Topographic Structure from Digital Elevation Data for Geographic Information System Analysis." Photogrammetric Engineering and Remote Sensing 54 (11): 1593–1600.
Qin, C., Zhu, A. X., Pei, T., Li, B., Zhou, C., & Yang, L. 2007. "An adaptive approach to selecting a flow partition exponent for a multiple flow direction algorithm." International Journal of Geographical Information Science 21(4): 443-458.