Derive Event Measures (Location Referencing)

サマリー

Populates and updates the DerivedRouteID field and measure values on point and line events with those fields configured and enabled.

使用法

  • An LRS dataset is required to run this tool. To create an LRS dataset, add the calibration point, centerline, and redline layers to a feature dataset; then run the Modify LRS tool with the geodatabase as the input.

  • This tool is designed to be executed as part of a larger workflow. The Apply Event Behaviors and Generate Routes tools should be run before executing Derive Event Measures. Running this tool without running the previous tools in the workflow may result in inaccurate data.

  • It is recommended that you run this tool against the file geodatabase at initial migration of the data. It will run faster this way because the operation must modify every single event record in the database. Once in production, the tool can be run on only a selection set of the routes that have been modified to significantly reduce execution time.

  • The input event feature layer must have DerivedRouteID and measure fields configured.

  • This tool can be run against one, multiple, or all events in a line network.

  • When conflict prevention is enabled, the following are supported:

    • The events whose derived event measures need to be updated will automatically acquire event locks, if available. If the locks cannot be acquired, the tool will fail and provide the text file of offending locks.

      Learn more about conflict prevention inPipeline Referencing

      Learn more about conflict prevention in Roads and Highways

    • While working in the default version, the acquired locks are released automatically when the tool completes.
    • While working in a child version, the acquired locks will remain in post status when the tool completes. The user must post or delete the version to release the locks.
    • While working in a child version, if the execution of the tool is canceled by interruption, the acquired locks will remain in releasable status.

パラメーター

ラベル説明データ タイプ
Input Route Features

The LRS Network containing the events with DerivedRouteID and measure fields configured.

Feature Layer
Update all event feature classes registered in the selected network
(オプション)

Determines whether all event feature classes in the network will be updated.

  • Checked—Updates all events in the network selected in Input Route Features. This is the default.
  • Unchecked—Does not update all events in the network selected in Input Route Features. Allows the user to select individual event layers in the event layers parameter below.
Boolean
Event Layers
(オプション)

The event layers that will have DerivedRouteID and measure fields updated.

Feature Layer

派生した出力

ラベル説明データ タイプ
Output Events

The updated events feature layer.

Feature Layer
Output Details File

The text file that details changes made to the events feature layer.

注意:

このツールの整合チェック結果は、ArcGIS Server ディレクトリに書き込まれます。 このファイルは、デフォルトでは 10 分以内に自動的にクリーン アップされますが、すべての整合チェックを処理し、ArcGIS Pro を実行しているワークステーションに書き込むには十分ではない場合があります。 大きいデータ ロードについては、ファイルの最大保存期間を少なくとも 1 時間に調整することをお勧めします。

Text File

arcpy.locref.DeriveEventMeasures(in_route_features, {update_all_events}, {event_layers})
名前説明データ タイプ
in_route_features

The LRS Network containing the events with DerivedRouteID and measure fields configured.

Feature Layer
update_all_events
(オプション)

Determines whether all event feature classes in the network will be updated.

  • UPDATE_ALLUpdates all events in the network selected in in_route_features. This is the default.
  • UPDATE_SOMEDoes not update all events in the network selected in the in_route_features. Allows the user to select individual event layers in the event_layers parameter below.
Boolean
event_layers
[event_layers,...]
(オプション)

The event layers that will have DerivedRouteID and measure fields updated.

Feature Layer

派生した出力

名前説明データ タイプ
out_events

The updated events feature layer.

Feature Layer
out_details_file

The text file that details changes made to the events feature layer.

注意:

このツールの整合チェック結果は、ArcGIS Server ディレクトリに書き込まれます。 このファイルは、デフォルトでは 10 分以内に自動的にクリーン アップされますが、すべての整合チェックを処理し、ArcGIS Pro を実行しているワークステーションに書き込むには十分ではない場合があります。 大きいデータ ロードについては、ファイルの最大保存期間を少なくとも 1 時間に調整することをお勧めします。

Text File

コードのサンプル

DeriveEventMeasures example 1 (Python window)

The following Python window script demonstrates how to use DeriveEventMeasures in immediate mode.

# Name: DeriveEventMeasures_ex1.py
# Description: Populate and update the Derived RouteID and measure values on point and line events with those fields configured and enabled.
# Requires: ArcGIS Location Referencing

# Check out license
arcpy.CheckOutExtension("LocationReferencing")

# Local variables
in_route_features = r'C:\Data\PipelineReferencing.gdb\LRS\LineNetwork'
update_all_events = "UPDATE_SOME"
event_layers = "Casing, Coating"

# Set current workspace
arcpy.env.workspace = "C:\Data\PipelineReferencing.gdb"

# Execute the tool
arcpy.DeriveEventMeasures_locref(in_route_features, update_all_events, event_layers)

# Check in license
arcpy.CheckInExtension('LocationReferencing')
DeriveEventMeasures example 2 (stand-alone script)

The following stand-alone Python script demonstrates how to use the DeriveEventMeasures tool.

# Name: DeriveEventMeasures_ex2.py
# Description: Populate and update the Derived routeID and measure values on point and line events with those fields configured and enabled.
# Requirements: ArcGIS Location Referencing

# Import arcpy module
import arcpy

# Check out license
arcpy.CheckOutExtension("LocationReferencing")

# Local variables
in_route_features = r'C:\Data\PipelineReferencing.gdb\LRS\LineNetwork'
update_all_events = "UPDATE_ALL"
event_layers = ""

# Execute the tool
arcpy.DeriveEventMeasures_locref(in_route_features, update_all_events, event_layers)

# Check in license
arcpy.CheckInExtension('LocationReferencing')
DeriveEventMeasures example 3 (stand-alone script)

The following stand-alone Python script demonstrates how to use the DeriveEventMeasures tool in a feature service.

# Name: DeriveEventMeasures_Pro_Ex3.py
# Description: Populate and update Derived RouteID and measure values on point and line events with those fields configured and enabled.
# Requires: ArcGIS Location Referencing

# Import arcpy module.
import arcpy

# Check out license
arcpy.CheckOutExtension("LocationReferencing")

## Input LRS Route Network is in feature service. Portal signin is required to access the feature service.
arcpy.SignInToPortal('https://yourdomain.com/portal', 'username', 'password')

## Map the input route network from the feature service. Here, 3 corresponds to the input route network.
in_lrs_network = r"https://yourdomain.com/server/rest/services/FeatureServiceName/FeatureServer/3"

# Set tool variables.
update_all_events = "UPDATE_ALL"
event_layers = ""

# Process : Derive Event Measures.
arcpy.DeriveEventMeasures_locref(in_lrs_network, update_all_events, event_layers)

# Check in license
arcpy.CheckInExtension('LocationReferencing')

環境

特殊なケース

ライセンス情報

  • Basic: 次のものが必要 ArcGIS Location Referencing
  • Standard: 次のものが必要 ArcGIS Location Referencing
  • Advanced: 次のものが必要 ArcGIS Location Referencing

関連トピック