Create Indoor Dataset (Indoors)

Available with the ArcGIS Indoors Pro or ArcGIS Indoors Maps extension.

Summary

Creates an indoor dataset containing the necessary feature classes to maintain floor plan data using a streamlined schema that conforms to the ArcGIS Indoors Information Model.

Usage

  • The indoor dataset created by this tool provides foundational support for floor-aware maps and apps and can be used for visualizing, analyzing, and editing indoor data.

    Note:

    If you require support for routing, space planning, and workspace reservations in addition to floor plan mapping, use the Create Indoors Database tool to apply the Indoors model to an existing workspace. The Indoors geodatabase created by the Create Indoors Database tool contains additional feature classes, fields, and tables that are used in Space Planner, Indoor Viewer, and the Indoors mobile apps.

  • The target geodatabase must already exist.

  • When using an enterprise geodatabase, the connection file must connect directly to the database, and the connection must be established as the database owner.

  • Use the Coordinate System parameter to set the spatial reference of the output indoor dataset. Both a horizontal and a vertical coordinate system are required.

    Note:

    Consider the following when choosing a coordinate system:

  • The following feature classes will be created in the output indoor dataset:

    • Sites
    • Facilities
    • Levels
    • Units
    • Details

  • The optional Create Attribute Rules parameter creates a collection of attribute rules to use in quality assurance workflows. The target geodatabase must be a file geodatabase or an enterprise geodatabase with branch versioning enabled. Traditional versioning is not supported.

    Note:

    Attribute rules will only be created if you are creating an Indoors dataset for the first time. If you have an existing Indoors dataset, you can import attribute rules from the Attribute Rules view.

    When you run the tool with the Create Attribute Rules parameter checked, the following occur:

    • A Global ID field will be created in the feature classes in the Indoors dataset.
    • Editor tracking fields will be created in the feature classes in the Indoors dataset and editor tracking will be enabled.
    • A Validation status field will be created in the feature classes in the Indoors dataset. This field is managed in the Error Inspector pane and is used to determine whether attribute rules have been run on a feature since its most recent update.
    • Four error datasets will be added to the geodatabase as stand-alone layers and correspond to point, polyline, polygon, and table errors. These datasets are managed in the Error Inspector pane.
    • A LEVEL_ID field will be created in the error datasets to support visualizing errors in a floor-aware map.
    • A series of validation and calculation rules will be applied to the Sites, Facilities, Levels, Units, and Details feature classes. Validation rules can be run at a time you specify to check for issues in the data. The included calculation rules are used to manage the Validation status field, which determines whether the validation checks will be run on a feature.
  • The output of this tool is used by the Import BIM To Indoor Dataset tool, which converts BIM data to GIS data, and the Import Floorplans To Indoors Geodatabase tool, which converts CAD data to GIS data.

Parameters

LabelExplanationData Type
Target Geodatabase

The target file or enterprise geodatabase that will contain the output indoor dataset.

Workspace
Indoor Dataset Name

The unique name of the output indoor dataset. The default is Indoor.

String
Coordinate System

The horizontal and vertical coordinate system of the output indoor dataset.

Spatial Reference
Create Attribute Rules
(Optional)

Specifies whether attribute rules and the associated fields and error datasets will be created in the Indoors database. These attribute rules include validation checks to use in quality control workflows for floor plan data. The target geodatabase must be a file geodatabase or an enterprise geodatabase configured for branch versioning.

  • Checked—Attribute rules will be created. This is the default.
  • Unchecked—Attribute rules will not be created.
Boolean

Derived Output

LabelExplanationData Type
Output Dataset

The indoor dataset that is generated in the target geodatabase.

Feature Dataset

arcpy.indoors.CreateIndoorDataset(target_gdb, indoor_dataset_name, spatial_reference, {create_attribute_rules})
NameExplanationData Type
target_gdb

The target file or enterprise geodatabase that will contain the output indoor dataset.

Workspace
indoor_dataset_name

The unique name of the output indoor dataset. The default is Indoor.

String
spatial_reference

The horizontal and vertical coordinate system of the output indoor dataset. You can specify the spatial reference in several ways, including the following:

  • Reference a feature class or feature dataset with the spatial reference you want to apply, such as C:/workspace/myproject.gdb/indoors/details.
  • Define a SpatialReference object. You can define the spatial reference object using either of the following:
    • Factory codes, for example: sr = arcpy.SpatialReference(3857, 115700)
    • Names, for example: sr = arcpy.SpatialReference("WGS 1984 Web Mercator (auxiliary sphere)", "WGS 1984")
  • Use the well-known text (WKT) string of a spatial reference. One way to determine the WKT for a spatial reference is to export the spatial reference as a string, for example, arcpy.SpatialReference(3857, 115700).exportToString().

Spatial Reference
create_attribute_rules
(Optional)

Specifies whether attribute rules and the associated fields and error datasets will be created in the Indoors database. These attribute rules include validation checks to use in quality control workflows for floor plan data. The target geodatabase must be a file geodatabase or an enterprise geodatabase configured for branch versioning.

  • CREATE_RULES Attribute rules and error layers will be created. This is the default.
  • NO_CREATE_RULES Attribute rules and error layers will not be created.
Boolean

Derived Output

NameExplanationData Type
output_dataset

The indoor dataset that is generated in the target geodatabase.

Feature Dataset

Code sample

CreateIndoorDataset example 1 (Python window)

The following Python window script demonstrates how to use the CreateIndoorDataset function in immediate mode.

import arcpy
arcpy.indoors.CreateIndoorDataset("C:/Indoors/myproject.gdb", 
                                  "Indoor", 
                                  "C:/workspace/myproject.gdb/featureclass",
                                  "NO_CREATE_RULES")
CreateIndoorDataset example 2 (stand-alone script)

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

import arcpy

# Set tool parameters
target_gdb = "C:/Indoors/ExampleCampus.gdb"
indoor_dataset_name = "Indoor"
spatial_reference = arcpy.SpatialReference("WGS 1984 Web Mercator (auxiliary sphere)", "WGS 1984")
create_attribute_rules = "CREATE_RULES"

# Run the tool
arcpy.indoors.CreateIndoorDataset(target_gdb, indoor_dataset_name, spatial_reference, create_attribute_rules)

Licensing information

  • Basic: Requires ArcGIS Indoors Pro or ArcGIS Indoors Maps
  • Standard: Requires ArcGIS Indoors Pro or ArcGIS Indoors Maps
  • Advanced: Requires ArcGIS Indoors Pro or ArcGIS Indoors Maps

Related topics