SubnetworkAggregator

Title  Subnetwork Aggregator

Description

This tools generates aggregated geometry and asset summaries for the subnetworks in an utility network.  This can be used to generated subnetwork geometry for subnetworks who currently have error rows. The results will include the currently connected features up to the location where errors are present.

Usage

          
Generate output geometry and summary information for the subnetworks in an utility network.  This can be used to generate partial geometry on subnetworks with error features.

The output geodatabase has a series of tables for the aggregated features.  Each table will be stored in a feature dataset and prefixed with the Domain of the Utility Network.  The tables will include fields to store the summary information and details about the number of vertices and parts in the aggreagate.  If there is no geometry to aggregate, a row is still added with an empty geometry:

  • DOMAIN_Aggregated_Points - The aggregated points.
  • DOMAIN_Aggregated_Polygons - The aggregated Polygons.
  • DOMAIN_Aggregated_Polylines - The aggregated Polylines.
  • DOMAIN_Areas - A generated convex hull geometry for each subnetwork.
The output geodatabase will include the follow table if Calculate Asset Summary is checked:
  • AssetSummary - Asset Group/Type counts per subnetwork defined by the participation type in the subnetwork.

License

Standard

Syntax

SubnetworkAggregator (in_utility_network, output_folder, {calc_functions}, {subnetwork_table}, {expression}, {trace_override_tag}, {asset_summary})

Parameter Explanation Data Type
in_utility_network Dialog Reference

The input utility network.

GPUtilityNetworkLayer
output_folder Dialog Reference

The folder where the results will be saved.

DEFolder
calc_functions (Optional) Dialog Reference

Option to calculate and store subnetwork functions on the output.

GPBoolean
subnetwork_table (Optional) Dialog Reference

The subnetwork table or table view. The list of subnetworks to trace is determined by the unique set of values in the subnetworkname field. A subnetwork is traced with all controllers even if a subset of controllers is filtered via the expresssion. If omitted, all the subnetworks from the utility network are used. Use the Create Utility Network System Tables Views tool to create a view to the subnetwork table. The this parameter requires a table requires the following fields:

  • DOMAINNETWORKNAME: Text
  • TIERNAME: Text
  • SUBNETWORKNAME: Text

GPTableView
expression (Optional) Dialog Reference

The sql expression used to limit the subnetworks queried from the table specified in the Subnetwork Table parameter. The Subnetwork Table parameter needs to be populated to use this parameter.

GPSQLExpression
trace_override_tag (Optional) Dialog Reference

The name of a tag used in trace configurations to override the subnetwork trace parameters. This tag is used to find a trace config that matches the tier of the subnetwork. To limit the trace configuration shown, the trace configuration must of a tag of SubnetworkOverride. All tags from these configurations are shown. To load different trace configuration per tier, create a trace configuration for each tier and use the same tag to group them together.

GPString
asset_summary (Optional) Dialog Reference

Option to calculate and store asset counts per subnetwork. If checked, an AssetSummary table is created in the output geodatabase. The table has the following schema.

  • SubnetworkName - The name of the subnetwork
  • SourceName - The Source Name in the Utility Network
  • AssetGroup - The Asset Group Description
  • AssetType - The Asset Type Description
  • ParticipationType - How the Asset Group/Type participates in the subnetwork
    • Attached - is attached to the structure newtork
    • Connected - part of the subnetwork
    • Container - is a container
    • Content - is contained by a container
    • Structure - is a structure that has attachments
  • RecordCount - The number of times the Asset Group/Type appears

GPBoolean

Code Samples

SubnetworkAggregator example 1 (Python window)

Aggregate all subnetworks.

import arcpy

arcpy.udms.SubnetworkAggregator("Naperville Network", "D:/data")

SubnetworkAggregator example 2 (stand-alone script)

Aggregate all Medium Voltage subnetworks.

import os

import arcpy

un = "D:/data/network.gdb/UtilityNetwork/Network"
folder = "D:/data"
sql = "TierName = 'Medium Voltage'"

describe = arcpy.Describe(un)
if describe.path.lower().startswith("http"):
    subnetworks = f"{describe.path}/500002"
else:
    subnetworks = os.path.join(os.path.dirname(describe.path), f"UN_{describe.DSID}_Subnetworks")

result = arcpy.udms.SubnetworkAggregator(
    in_utility_network=un,
    output_folder=folder,
    calc_functions=False,
    subnetwork_table=subnetworks,
    expression=sql,
    asset_summary=True,
)
print(result[0])