ArcGIS for Desktop

  • Documentation
  • Pricing
  • Support

  • My Profile
  • Help
  • Sign Out
ArcGIS for Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS for Desktop

A complete professional GIS

ArcGIS for Server

GIS in your enterprise

ArcGIS for Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Pricing
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

Help

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • More...

Set LAS Class Codes Using Features

  • Summary
  • Usage
  • Syntax
  • Code Sample
  • Environments
  • Licensing Information

Summary

Classifies data points in LAS files referenced by a LAS dataset using point, line, and polygon features.

Usage

  • The LAS format supports the classification of each point based on the specifications defined by the American Society for Photogrammetry and Remote Sensing (ASPRS). The ArcGIS platform applies the classification scheme specified for LAS file version 1.4:

    Classification Value Classification Type

    0

    Never Classified

    1

    Unassigned

    2

    Ground

    3

    Low Vegetation

    4

    Medium Vegetation

    5

    High Vegetation

    6

    Building

    7

    Low Noise

    8

    Model Key / Reserved

    9

    Water

    10

    Rail

    11

    Road Surface

    12

    Overlap / Reserved

    13

    Wire – Guard

    14

    Wire – Conductor

    15

    Transmission Tower

    16

    Wire – Connector

    17

    Bridge Deck

    18

    High Noise

    19 – 63

    Reserved for ASPRS Definition (LAS 1.1 to 1.3 support up to class code 31)

    32 – 255

    User Definable (Only supported in LAS 1.0 and certain versions of 1.4)

    Note:

    While the bulk of new class code assignments introduced with LAS 1.4 were previously designated as Reserved, class codes 8 and 12 were changed from Model Key and Overlap to Reserved.

  • The LAS dataset layer can also be used to control the enforcement of surface constraint features that may be referenced by the LAS dataset.

  • LAS data points that fall within the 2-dimensional area of the buffer specified for the input features will be classified.

  • Consider using the points obtained from Locate Outliersto classify LAS points as Noise.

Syntax

SetLasClassCodesUsingFeatures_3d (in_las_dataset, feature_class, {compute_stats})
ParameterExplanationData Type
in_las_dataset

The LAS dataset to process.

LAS Dataset Layer
feature_class
[[features, buffer_distance, new_class, synthetic, key_point, withheld],...]

Specify one or more feature classes that will be used to define class code values for the lidar files referenced by a LAS dataset. Each feature will have the following options that can be specified:

  • features—The feature layer or full path to the input feature class.
  • buffer_distance—The selection tolerance used in determining which lidar points will be modified by the input features.
  • new_class—The class code to be assigned to the lidar files that intersect with the features and the associated buffer distance.
  • synthetic—Specifies whether to flag or remove a Synthetic designation, which implies that the point was not created with lidar, but an alternate technique (for example, digitized from photogrammetric stereo model).
  • key_point—Specifies whether to flag or remove a Key Point designation for the data point. A model key point is typically treated as an anchor point that does not get removed by any thinning algorithm.
  • withheld—Specifies whether to flag or remove a Withheld designation for the data point, which is generally used to signify erroneous data.
Value Table
compute_stats
(Optional)

Specifies whether statistics should be computed for the LAS files referenced by the LAS dataset. The presence of statistics allows the LAS dataset layer's filtering and symbology options to only show LAS attribute values that exist in the LAS files.

  • COMPUTE_STATS —Statistics will be computed.
  • NO_COMPUTE_STATS —Statistics will not be computed. This is the default.
Boolean

Code Sample

SetLasClassCodesUsingFeatures example 1 (Python window)

The following sample demonstrates the use of this tool in the Python window.

import arcpy
from arcpy import env

arcpy.CheckOutExtension('3D')
env.workspace = 'C:/data'
arcpy.SetLasClassCodesUsingFeatures_3d("test.lasd", [["lake.shp 0 9"],
                                       ["outliers.shp", 5, "NO_CHANGE", 
                                        "NO_CHANGE", "NO_CHANGE", "SET"]], 
                                       "COMPUTE_STATS")
SetLasClassCodesUsingFeatures example 2 (stand-alone script)

The following sample demonstrates the use of this tool in a stand-alone Python script.

'''**********************************************************************
Name: Assign Withheld Classification Flag to Outlier Points in LAS Files
Description: Uses Locate Outliers to identify points in LAS files that
             should be assigned the 'withheld' classification flag.
             Designed for use as a script tool.
**********************************************************************'''
# Import system modules
import arcpy
import exceptions, sys, traceback

try:
    arcpy.CheckOutExtension('3D')
    # Set Local Variables
    lasD = arcpy.GetParameterAsText(0)
    outliers = 'in_memory/outliers'
    # Execute LocateOutliers
    arcpy.ddd.LocateOutliers(lasD, outliers, 'APPLY_HARD_LIMIT', -10, 
                             350, 'APPLY_COMPARISON_FILTER', 1.2, 120, 
                             0.8, 8000)
    # Execute SetLasClassCodeUsingFeatures
    arcpy.ddd.SetLasClassCodesUsingFeatures(lasd, [["outliers.shp", 5, 
                                                    "NO_CHANGE", "NO_CHANGE",
                                                    "NO_CHANGE", "SET"]])
    arcpy.CheckInExtension('3D')
except arcpy.ExecuteError:
    print arcpy.GetMessages()
except:
    # Get the traceback object
    tb = sys.exc_info()[2]
    tbinfo = traceback.format_tb(tb)[0]
    # Concatenate error information into message string
    pymsg = 'PYTHON ERRORS:\nTraceback info:\n{0}\nError Info:\n{1}'\
          .format(tbinfo, str(sys.exc_info()[1]))
    msgs = 'ArcPy ERRORS:\n {0}\n'.format(arcpy.GetMessages(2))
    # Return python error messages for script tool or Python Window
    arcpy.AddError(pymsg)
    arcpy.AddError(msgs)

Environments

  • Current Workspace
  • Extent
  • Geographic Transformations

Licensing Information

  • ArcGIS for Desktop Basic: Requires 3D Analyst
  • ArcGIS for Desktop Standard: Requires 3D Analyst
  • ArcGIS for Desktop Advanced: Requires 3D Analyst

Related Topics

  • An overview of the Data Management toolset
  • Fundamentals of Surfaces
  • Surface formats
  • Lidar point classification
  • Editing LAS point classification
  • Working with LAS classification in ArcGIS
Feedback on this topic?

ArcGIS for Desktop

  • Home
  • Documentation
  • Pricing
  • Support

ArcGIS Platform

  • ArcGIS Online
  • ArcGIS for Desktop
  • ArcGIS for Server
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Insiders Blog
  • User Conference
  • Developer Summit
Esri
© Copyright 2016 Environmental Systems Research Institute, Inc. | Privacy | Legal