ArcGIS Velocity

ArcGIS Velocity: Introducing stateful tools for real-time analytics

One of the most powerful uses of real-time analysis is the ability to be alerted when something changes. You may want a notification that a tracked delivery vehicle enters the perimeter around a shipping facility, or when an aircraft suddenly loses airspeed or altitude. With the December update to ArcGIS Velocity, real-time analytics now support stateful processing so that changes in the behavior of a particular asset or sensor can be detected.

Prior to this update, real-time analytics would process each incoming message or feature from a feed as a distinct and singular unit of information. The analytic did not retain knowledge of any previously processed feature, in other words, the feature’s ‘state.’ This ability to compare current observations to previous ones in real-time is referred to as stateful processing and is now enabled in four tools:

Time windows

In order to leverage feature state in real-time analytics, it’s important for you to understand time windows in stateful tools. Each tool that maintains a feature state consumes additional resources. To prevent them from over-utilizing memory, the feature state is periodically purged of older records. How often this occurs is specified using the Time Window parameter for each stateful tool. As the tool processes features for each track it will store the latest feature in the feature state. If another feature arrives before the time window expiration it will replace the current feature. If no feature arrives prior to the expiration of the time window the current feature will be purged from the feature state.

As a general rule, the Time Window should be set to at least as long as the longest expected duration between observations for each track. If the Time Window is too short, this would have the effect of purging records from the feature state before new observations arrive, meaning history information is removed and the next feature is treated as the first observation. In other words, assets would never ‘enter’ facilities because the analytic would have no knowledge that the previous observation of the truck was outside the facility.

Entering and exiting geofences

Of the four stateful tools, three are specifically enhanced to let you perform ‘enter’ and ‘exit’ geofencing: Filter by Geometry, Detect Incidents and Join Features. These tools can compare the current observation for a track to the previous observation for the same track relative to a set of geofences. If it determines the feature was previously outside all of the features in the geofence source and is now inside any of them, then an ’enter’ has occurred. Similarly, if it was previously inside any geofence and is now outside all then an ‘exit’ has occurred.

Keep in mind if the track moves from one geofence to another in consecutive observations, this is not considered to be a new exit/enter activity. An asset must be outside all geofences for the ‘exit’ condition to be satisfied.

Filter by Geometry

Filter by Geometry now applies stateful processing when the spatial relationship parameter is set to ‘enter’ or ‘exit’. When set to ‘enter’ if a track observation is determined to be outside all geofences and subsequently inside any feature in the geofence layer, it will pass through the filter. All other observations will be blocked. Likewise, if set to ‘exit’, features will pass only if the previous observation was inside any geofence and the current one is outside all geofences. For more information, see the documentation on Filter by Geometry.


Join Features

Like Filter by Geometry, Join Features has also been enhanced to enable you to look for ‘enter’ and ‘exit’ events in a track. Unlike the filter tool, it also enriches the observation with additional attributes from the joined features. For example, you might want to send a courtesy message to a client that their order is about to be delivered.

When the delivery vehicle enters a 15-minute drive time area around the delivery address, the Join Features tool can detect the ‘enter’ event and join attributes about the order to the vehicle feature in order to provide the necessary fields for the outgoing message’s address, subject and body. Join Features can act as a data filter or a data enricher by leveraging the option to return all target features or only those that satisfy a join. See our documentation on Join Features.

Calculate Motion Statistics

Calculate Motion Statistics uses a History Depth parameter to examine the n most recent observations of a track and calculate additional attributes about its motion. This allows you to know things like speed, acceleration, the distance traveled, the time elapsed since the last observation, or if the track is idling. It also gives you several minimum, maximum, average and cumulative values over the course of the n observations. Now enabled for real-time analytics, with Calculate Motion Statistics you can, for example, analyze speed information to be aware of incidents, even if your assets’ onboard sensors do not report speed.  For a complete list of the calculated motion attributes, see our documentation on Calculate Motion Statistics.

Detect Incidents

Detect Incidents watches for an open condition and, if found, emits an incident with an initial status of ‘Started’, and tracks the ongoing incident. When the open condition is no longer met, or a specified close condition is met, the incident is closed and a final feature is emitted with a status of ‘Ended’. Open and close conditions can be spatial, attribute or temporal or any combination of the three. Because it tracks and monitors the ongoing state of incidents, Detect Incidents is always stateful when used in a real-time analytic. See our documentation on Detect Incidents.


With the December update of ArcGIS Velocity, you can now apply stateful processing in your real-time analytics for more advanced detection of changes in asset behavior.  This supports use cases like alerting when delivery trucks arrive and depart your shipping centers, identifying when aircraft deviate from prescribed routes or enter areas where they should not go, and enriching field crew feeds with details about their movement such as what work sites they are visiting or if they are idling somewhere unexpectedly.

See our Resources page for more information about ArcGIS Velocity, including product videos, lessons, documentation and more.

About the author

Ken is a Product Engineer with the Real-Time GIS team at Esri.


Leave a Reply

Please Login to comment

Next Article

Online Services not affected by Microsoft Exchange Vulnerabilities

Read this article