LAS To Multipoint (3D Analyst)
Summary
Creates multipoint features using one or more lidar files.
Illustration
Usage
-
Supported LAS file versions are 1.0, 1.1, 1.2, and 1.3.
LAS points can be classified into a number of categories that describe the material encountered by the lidar return, such as ground, building, or water. The American Society for Photogrammetry and Remote Sensing (ASPRS) defined the following class codes for LAS file versions 1.1, 1.2, and 1.3:
Classification Value
Classification Type
0
Never Classified
1
Unassigned
2
Ground
3
Low Vegetation
4
Medium Vegetation
5
High Vegetation
6
Building
7
Noise
8
Model Key
9
Water
10
Reserved for ASPRS Definition
11
Reserved for ASPRS Definition
12
Overlap
13–31
Reserved for ASPRS Definition
Note:While the LAS 1.0 specifications provide class codes ranging from 0 to 255, it does not have a standardized classification scheme. Any class codes used in 1.0 files would typically be defined by the data vendor and provided through auxiliary information.
-
If you are not interested in importing points based on their return number, or if all returns specified in the file or files are set to 0 because the points have been filtered or classified, select ANY_RETURN.
-
When loading multiple LAS attributes into an Oracle database, you'll need to make sure all DBTUNE keywords for parameter attribute_binary are set to use binary large objects (BLOBs), not LONGRAW. This is because LAS attributes are loaded as BLOBs, and Oracle does not support multiple BLOBs in LONGRAW tables. See your Oracle database administrator for assistance.
Syntax
Parameter | Explanation | Data Type |
input [input,...] |
One or more files or folders with data in the LAS version 1.0, 1.1, and 1.2 format. The LAS format is the industry standard for lidar data. | Folder or File |
out_feature_class |
The output feature class. | Feature Class |
average_point_spacing |
The average 2D distance between points in the input file or files. This can be an approximation. If areas have been sampled at different densities, specify the smaller spacing. The value needs to be provided in the projection units of the output coordinate system. | Double |
class_code [class_code,...] (Optional) |
The classification codes to use as a query filter for LAS data points. Valid values range from 1 to 32. No filter is applied by default. | Long |
return [return,...] (Optional) |
The return values used as a query filter. Valid return values are 1–5, LAST_RETURNS, and ANY_RETURNS. The default is ANY_RETURNS. | String |
attribute [[keyword, name],...] (Optional) |
One or more LAS attributes to load and store and, optionally, the field names to use. The default is none. Supported attribute keywords are INTENSITY, RETURN_NUMBER, NUMBER_OF_RETURNS, SCAN_DIRECTION_FLAG, EDGE_OF_FLIGHTLINE, CLASSIFICATION, SCAN_ANGLE_RANK, FILE_MARKER, USER_BIT_FIELD, and GPS_TIME. | Value Table |
input_coordinate_system (Optional) |
The coordinate system of the input LAS file. This defaults to that specified in the LAS file. If for some reason it's not defined in the file but you know what it is, specify it here. | Coordinate System |
file_suffix (Optional) |
The suffix of the files to import from an input folder. This parameter is required when a folder is specified as input. | String |
z_factor (Optional) |
The factor by which elevation values will be multiplied. This is typically used to convert Z linear units that match those of the XY linear units. The default is 1, which leaves elevation values unchanged. | Double |
folder_recursion (Optional) |
Scans through subfolders when an input folder is selected containing data in a subfolders directory. The output feature class will be generated with a row for each file encountered in the directory structure.
| Boolean |
Code Sample
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.LASToMultipoint_3d("001.las", "Test.gdb/feature_dataset/sample_1", 1.5,
"2", "ANY_RETURNS", "INTENSITY", "Coordinate Systems"\
"/Projected Coordinate Systems/UTM/NAD 1983/NAD 1983 "\
"UTM Zone 17N.prj", "las", 1)
The following sample demonstrates the use of this tool in a stand-alone Python script:
'''****************************************************************************
Name: Define Data Boundary of LAS File
Description: This script demonstrates how to delineate data boundaries of
LAS files with irregularly clustered points. It is intended for
use as a script tool with one input LAS file.
****************************************************************************'''
# Import system modules
import arcpy
import exceptions, sys, traceback
# Set local variables
inLas = arcpy.GetParameterAsText(0) #input LAS file
ptSpacing = arcpy.GetParameterAsText(1) # LAS point spacing
classCode = arcpy.GetParameterAsText(2) # List of integers
returnValue = arcpy.GetParameterAsText(3) # List of strings
outTin = arcpy.GetParameterAsText(4) # TIN created to delineate data area
outBoundary = arcpy.GetParameterAsText(5) # Polygon boundary file
try:
arcpy.CheckOutExtension("3D")
# Execute LASToMultipoint
arcpy.AddMessage("Creating multipoint features from LAS...")
lasMP = arcpy.CreateUniqueName('lasMultipoint', 'in_memory')
arcpy.ddd.LASToMultipoint(inLas, LasMP, ptSpacing, class_code,
"ANY_RETURNS", "", sr, inFormat, zfactor)
# Execute CreateTin
arcpy.AddMessage("Creating TIN dataset...")
arcpy.ddd.CreateTin(outTin, sr, "{0} Shape.Z masspoints"\
.format(lasMP), "Delaunay")
# Execute CopyTin
arcpy.AddMessage("Copying TIN to delineate data boundary...")
arcpy.ddd.CopyTin(outTin, "{0}_copy".format(outTin))
# Execute DelineateTinDataArea
arcpy.AddMessage("Delineating TIN boundary...")
maxEdge = ptSpacing * 4
arcpy.ddd.DelineateTinDataArea(outTin, maxEdge, "PERIMETER_ONLY")
# Execute TinDomain
arcpy.AddMessage("Exporting data area to polygon boundary...")
arcpy.ddd.TinDomain(outTin, outBoundary, "POLYGON")
arcpy.AddMessage("Finished")
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)