Classify Movement Events (Intelligence)

Summary

Identifies turn events, acceleration events, and speed from an input point track dataset.

Usage

  • For the tool to execute, the Input Features parameter value must be in a projected coordinate system and it must be time enabled.

    The tool will identify the following events:

    • Right or left turn
    • Right or left u-turn
    • Acceleration
    • Deceleration
    • Start
    • Stop
    • Speed in miles per hour
    • Speed in kilometers per hour
    • Distance difference between the current point and the previous point in the track
    • Time difference between the current point and the previous point in the track
    • Name of the region of interest where the current point is located if the Regions Of Interest feature class is provided

  • Turns are calculated using the Curvature and Number Of Points parameters. Each point is evaluated as a series of triangles calculated using the current point and the point in front of and behind the current point at the specified Number Of Points parameter value. The Menger curve is then calculated, allowing for turns to be detected.

  • The default values for the Curvature and Number Of Points parameters are optimized for typical automobile tracks assuming an approximate one second sampling rate. Vehicles that move faster than automobiles or data that is sampled in an interval not at once per second may necessitate a change to the Curvature or Number Of Points parameters. For example, a person using a personal GPS device that samples once every five seconds can decrease the Number Of Points value. Data that represents aircraft that is sampled once every second can adjust the Curvature parameter value down to 1.5 or lower to account for the greater amount of time and space that is required for an aircraft to make a turn.

  • Speed is calculated using the distance between points divided by the amount of time needed to travel that distance. Stops are identified when a vehicle has a velocity of zero. Starts are determined from when points accelerate from a stopped position.

  • The output feature class will contain the following fields:

    • track_id—The unique identifier associating the point to a track. This field is derived from the ID Field parameter.
    • time—The time associated with the point track feature. This field is derived from the time field specified in the layer properties.
    • POINT_X—The x-coordinate associated with the current feature.
    • POINT_Y—The y-coordinate associated with the current feature.
    • distance_diff—The distance between the previous feature in the track and the current feature. The distance is calculated in the units of the input's coordinate system.
    • time_diff—The difference in seconds between the previous feature in the track and the current feature.
    • speed—The speed in the linear units of the input coordinate system per second.
    • speed_MPH—The speed in miles per hour of the track from the previous feature in the track to the current feature.
    • speed_KMPH—The speed in kilometers per hour of the track from the previous feature in the track to current feature.
    • acc_event—Acceleration events. Specific acceleration events include the following:
      • Start of acceleration—The point where the track begins to speed up.
      • Start of brake—The point where the track begins to slow down.
      • Acceleration—The point track has increasing speed between the previous point and current point. This must come after Start of acceleration.
      • Braking—The point track has decreasing speed between the previous point and the current point. This must come after End of brake.
      • End of acceleration—The point where an acceleration event stops. This is typically followed by either Travelling or a brake event.
      • End of brake—The point where a brake event stops. This is typically followed by Stopped or an acceleration event.
      • Stopped—The point track is not moving. Speed must be equal to 0 mph or 0 kph.
      • Travelling—The point track is moving at a speed that does not fall into any of the previous categories.
    • turn_event—A turn event. Specific turn events include Left turn, Right turn, Left U-turn, Right U-turn, and Travelling.

    If the optional Regions Of Interest parameter value has an associated feature class, a roi_id field will be populated. This field will include the region of interest that the point intersects.

Syntax

arcpy.intelligence.ClassifyMovementEvents(in_features, id_field, out_featureclass, {curvature}, {number_of_points}, {regions_of_interest}, {roi_id_field})
ParameterExplanationData Type
in_features

A time-enabled point feature layer with a field annotating the track with which each point is associated. The geometry, object identifier, track name, and time will be transferred to the output feature class. The input must be in a projected coordinate system.

Feature Layer
id_field

A field from the input features that will be used to obtain the unique identifiers per point track. The field will be copied to the output feature class.

Field
out_featureclass

The output feature class that will contain the calculated movement events.

Feature Class
curvature
(Optional)

The minimum value that is necessary for an event to be classified as a turn event. After the curvature is calculated, any calculated curvature greater than this value will cause the turn_event field to be populated with the relevant turn event, while values less than this will cause the turn_event field to be classified as Travelling.

To determine whether an event meets the criteria for a turn event, a Menger curve is calculated based on three points. The distance between these points is specified in the Number Of Points parameter. The default Curvature parameter value of 2 is suitable for automobiles and pedestrians. For higher speed vehicles such as aircraft, you may need to use a smaller value or increase the Number Of Points parameter value.

Double
number_of_points
(Optional)

The number of points to evaluate before and after a given to point when calculating the Menger curve. When using data with a high sampling rate (subsecond), you may need to increase the Number Of Points parameter value to account for the decreased movement that is possible in that brief time period. The default value of 5 is suitable for automobiles and pedestrians assuming a one second sampling on the input data.

Long
regions_of_interest
(Optional)

The regions of interest. This optional input feature layer must be a polygon feature class. If this is provided, a roi field will be added to the Output Feature Class parameter.

Feature Layer
roi_id_field
(Optional)

A field from the Regions Of Interest parameter that contain the unique identifiers for each region of interest.

Field

Code sample

ClassifyMovementEvents example (stand-alone script)

The following stand-alone Python script demonstrates how to use the ClassifyMovementEvents function.

# Name: ClassifyMovementEvents.py
# Description: Identify movement events in a point track dataset. 

# Import system modules 
import arcpy 

arcpy.env.workspace = "C:/data/Tracks.gdb"

# Set local variables 
source_features = "Known_Tracks"
output_movement_events = "MovementEvents"
id_field = "device_id"
regions_of_interest = "Named_Areas_Of_Interest"
roi_name = "counties"

# Execute tool
arcpy.ClassifyMovementEvents_intelligence(source_features,
                                   							output_point_features,
                                   							id_field,
                                   							regions_of_interest,
																																										roi_name)

Licensing information

  • Basic: No
  • Standard: No
  • Advanced: Yes

Related topics